Index: EcnlProtoTool/trunk/webapp/webmrbc.sln
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc.sln	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc.sln	(revision 425)
@@ -1,6 +1,6 @@
 ﻿
 Microsoft Visual Studio Solution File, Format Version 12.00
-# Visual Studio 14
-VisualStudioVersion = 14.0.25420.1
+# Visual Studio Version 16
+VisualStudioVersion = 16.0.29102.190
 MinimumVisualStudioVersion = 10.0.40219.1
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "webmrbc", "webmrbc\webmrbc.csproj", "{7E71D3E4-F61A-4423-994A-EB307D7618E0}"
@@ -20,3 +20,6 @@
 		HideSolutionNode = FALSE
 	EndGlobalSection
+	GlobalSection(ExtensibilityGlobals) = postSolution
+		SolutionGuid = {537ABA34-4886-472B-81D4-8ECE70055369}
+	EndGlobalSection
 EndGlobal
Index: EcnlProtoTool/trunk/webapp/webmrbc/App.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/App.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/App.cs	(revision 425)
@@ -174,5 +174,5 @@
 					}
 					if ((item.classGroupCode == 0xE) && (cls.classCode == 0xF0)) {
-						cls.properties = (JsonPropertyInfo[])profProps.Concat(properties);
+						cls.properties = profProps.Concat(properties).ToArray();
 						NodeProfileClass = cls;
 					}
@@ -344,11 +344,11 @@
 	public class Collections
 	{
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		internal static ENodeWorkspace LocalNode;
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		internal static Collection<IClassWorkspace> ClassWorkspaces;
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		internal static EcnlTaskWorkspace EcnlTaskWorkspace;
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		internal static MainLoopWorkspace MainLoopWorkspace;
 	}
@@ -356,9 +356,9 @@
 	public class Views
 	{
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		internal static MainMenuView MainMenuView;
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		internal static ClassSelectorView ClassSelectorView;
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		internal static EObjectModalView EObjectModalView;
 	}
@@ -408,7 +408,7 @@
 					byte b = bytes[i + index];
 					if (b < 0x20)
-						sb += "\x1B[1;3;31m" + String.FromCharCode(b + 0x40) + "\x1B[0m";
+						sb += "\x1B[1;3;31m" + StringPrototype.FromCharCode(b + 0x40) + "\x1B[0m";
 					else
-						sb += String.FromCharCode(b);
+						sb += StringPrototype.FromCharCode(b);
 				}
 			}
Index: EcnlProtoTool/trunk/webapp/webmrbc/Arduino/KernelBlock.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Arduino/KernelBlock.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Arduino/KernelBlock.cs	(revision 425)
@@ -38,5 +38,5 @@
 using System.Collections.Generic;
 using System.Linq;
-using Bridge.Text.RegularExpressions;
+using Bridge.Html5;
 
 namespace WebMrbc
@@ -451,5 +451,5 @@
 		public string validator(string text)
 		{
-			text = text.Replace(new Regex("[^0-9a-fA-F]+", "g"), "");
+			text = text.Replace(new RegExp("[^0-9a-fA-F]+", "g"), "");
 			return text;
 		}
Index: EcnlProtoTool/trunk/webapp/webmrbc/Block.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Block.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Block.cs	(revision 425)
@@ -46,35 +46,35 @@
 		public string type;
 
-		[External, FieldProperty]
+		[External, Field]
 		public string id { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public Connection outputConnection { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public Connection nextConnection { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public Connection previousConnection { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public Input[] inputList { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public bool inputsInline { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public bool disabled { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public string tooltip { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public bool contextMenu { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public string contextMenuMsg_ { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public Union<string, Comment> comment { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public bool RTL { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public Block[] prevBlocks_ { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public Workspace workspace { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public Mutator mutator { get; set; }
-		[External, FieldProperty]
+		[External, Field]
 		public bool isInFlyout { get; }
 
Index: EcnlProtoTool/trunk/webapp/webmrbc/Blockly.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Blockly.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Blockly.cs	(revision 425)
@@ -32,13 +32,13 @@
 	public partial class Blockly
 	{
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static Xml Xml;
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static Events Events;
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static Procedures Procedures;
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static Variables Variables;
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static Names Names;
 
@@ -46,5 +46,5 @@
 		/// Number of pixels the mouse must move before a drag starts.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int DRAG_RADIUS = 5;
 
@@ -52,5 +52,5 @@
 		/// Maximum misalignment between connections for them to snap together.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int SNAP_RADIUS = 20;
 
@@ -58,5 +58,5 @@
 		/// Delay in ms between trigger and bumping unconnected block out of alignment.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int BUMP_DELAY = 250;
 
@@ -64,5 +64,5 @@
 		/// Number of characters to truncate a collapsed block to.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int COLLAPSE_CHARS = 30;
 
@@ -70,5 +70,5 @@
 		/// Length in ms for a touch to become a long press.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int LONGPRESS = 750;
 
@@ -77,5 +77,5 @@
 		/// miliseconds.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int SOUND_LIMIT = 100;
 
@@ -84,5 +84,5 @@
 		/// Must be in the range of 0 (inclusive) to 1 (exclusive).
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static double HSV_SATURATION = 0.45;
 
@@ -91,5 +91,5 @@
 		/// Must be in the range of 0 (inclusive) to 1 (exclusive).
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static double HSV_VALUE = 0.65;
 
@@ -97,5 +97,5 @@
 		/// Sprited icons and images.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static object SPRITE = new {
 			width = 96,
@@ -107,5 +107,5 @@
 		/// Required name space for SVG elements.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static readonly string SVG_NS = "http://www.w3.org/2000/svg";
 
@@ -113,5 +113,5 @@
 		/// Required name space for HTML elements.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static readonly string HTML_NS = "http://www.w3.org/1999/xhtml";
 
@@ -119,5 +119,5 @@
 		/// ENUM for a right-facing value input.  E.g. 'set item to' or 'return'.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int INPUT_VALUE = 1;
 
@@ -125,5 +125,5 @@
 		/// ENUM for a left-facing value output.  E.g. 'random fraction'.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int OUTPUT_VALUE = 2;
 
@@ -131,5 +131,5 @@
 		/// ENUM for a down-facing block stack.  E.g. 'if-do' or 'else'.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int NEXT_STATEMENT = 3;
 
@@ -137,5 +137,5 @@
 		/// ENUM for an up-facing block stack.  E.g. 'break out of loop'.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int PREVIOUS_STATEMENT = 4;
 
@@ -143,5 +143,5 @@
 		/// ENUM for an dummy input.  Used to add field(s) with no input.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int DUMMY_INPUT = 5;
 
@@ -149,5 +149,5 @@
 		/// ENUM for left alignment.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int ALIGN_LEFT = -1;
 
@@ -155,5 +155,5 @@
 		/// ENUM for centre alignment.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int ALIGN_CENTRE = 0;
 
@@ -161,5 +161,5 @@
 		/// ENUM for right alignment.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int ALIGN_RIGHT = 1;
 
@@ -167,5 +167,5 @@
 		/// ENUM for no drag operation.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int DRAG_NONE = 0;
 
@@ -173,5 +173,5 @@
 		/// ENUM for inside the sticky DRAG_RADIUS.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int DRAG_STICKY = 1;
 
@@ -180,5 +180,5 @@
 		/// clicks and drags.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int DRAG_BEGIN = 1;
 
@@ -186,5 +186,5 @@
 		/// ENUM for freely draggable (outside the DRAG_RADIUS, if one applies).
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int DRAG_FREE = 2;
 
@@ -192,5 +192,5 @@
 		/// Lookup table for determining the opposite type of a connection.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int[] OPPOSITE_TYPE = {
 			0,
@@ -204,5 +204,5 @@
 		/// ENUM for toolbox and flyout at top of screen.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int TOOLBOX_AT_TOP = 0;
 
@@ -210,5 +210,5 @@
 		/// ENUM for toolbox and flyout at bottom of screen.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int TOOLBOX_AT_BOTTOM = 1;
 
@@ -216,5 +216,5 @@
 		/// ENUM for toolbox and flyout at left of screen.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int TOOLBOX_AT_LEFT = 2;
 
@@ -222,5 +222,5 @@
 		/// ENUM for toolbox and flyout at right of screen.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static int TOOLBOX_AT_RIGHT = 3;
 
@@ -236,5 +236,5 @@
 		public static Block selected;
 
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public static Blocks Blocks;
 
@@ -1485,5 +1485,5 @@
 	public class BlockSvg : Block
 	{
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public int TAB_HEIGHT = 20;
 
@@ -1739,5 +1739,5 @@
 		/// Non-breaking space.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public const string NBSP = "\u00A0";
 
@@ -1745,5 +1745,5 @@
 		/// Editable fields are saved by the XML renderer, non-editable fields are not.
 		/// </summary>
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		public bool EDITABLE = true;
 
Index: EcnlProtoTool/trunk/webapp/webmrbc/Blocks/Loops.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Blocks/Loops.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Blocks/Loops.cs	(revision 425)
@@ -345,5 +345,5 @@
 			var block = (Block)this;
 			do {
-				if (this.LOOP_TYPES.IndexOf(block.type) != -1) {
+				if (Array.IndexOf(this.LOOP_TYPES, block.type) != -1) {
 					legal = true;
 					break;
Index: EcnlProtoTool/trunk/webapp/webmrbc/Blocks/Procedures.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Blocks/Procedures.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Blocks/Procedures.cs	(revision 425)
@@ -28,5 +28,4 @@
 using Bridge;
 using Bridge.Html5;
-using Bridge.Text.RegularExpressions;
 
 namespace WebMrbc
@@ -504,5 +503,5 @@
 		public string validator_(string newVar)
 		{
-			newVar = newVar.Replace(new Regex("[\\s\\xa0]+", "g"), " ").Replace(new Regex("^ | $", "g"), "");
+			newVar = newVar.Replace(new RegExp("[\\s\\xa0]+", "g"), " ").Replace(new RegExp("^ | $", "g"), "");
 			return newVar;
 		}
@@ -630,5 +629,5 @@
 					this.quarkConnections_[this.quarkIds_[i]] = connection;
 					if (mutatorOpen && connection != null &&
-						paramIds.IndexOf(this.quarkIds_[i]) == -1) {
+						Array.IndexOf(paramIds, this.quarkIds_[i]) == -1) {
 						// This connection should no longer be attached to this block.
 						connection.disconnect();
@@ -638,5 +637,5 @@
 			}
 			// Rebuild the block's arguments.
-			this.arguments_ = (string[])(new string[0]).Concat(paramNames);
+			this.arguments_ = (new string[0]).Concat(paramNames).ToArray();
 			this.updateShape_();
 			this.quarkIds_ = paramIds;
@@ -781,5 +780,5 @@
 			}
 			if (e.type == Events.CREATE &&
-				((Create)e).ids.IndexOf(this.id) != -1) {
+				Array.IndexOf(((Create)e).ids, this.id) != -1) {
 				// Look for the case where a procedure call was created (usually through
 				// paste) and there is no matching definition.  In this case, create
@@ -988,5 +987,5 @@
 			var block = (Block)this;
 			do {
-				if (this.FUNCTION_TYPES.IndexOf(block.type) != -1) {
+				if (Array.IndexOf(this.FUNCTION_TYPES, block.type) != -1) {
 					legal = true;
 					break;
Index: EcnlProtoTool/trunk/webapp/webmrbc/Collection.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Collection.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Collection.cs	(revision 425)
@@ -39,7 +39,6 @@
 using System.Collections.Generic;
 using Bridge;
-using Bridge.Linq;
-using Bridge.Text.RegularExpressions;
 using System.Collections;
+using Bridge.Html5;
 
 namespace WebMrbc
@@ -76,5 +75,5 @@
 		internal void Remove(T item)
 		{
-			var i = List.IndexOf(item);
+			var i = Array.IndexOf(List, item);
 			if (i >= 0)
 				List.Splice(i, 1);
@@ -95,5 +94,5 @@
 		{
 			List.Splice(0, List.Length);
-			List = (T[])List.Concat(n);
+			List = List.Concat(n).ToArray();
 
 			if (OnReset != null)
@@ -115,5 +114,5 @@
 
 			var max = 0;
-			var n = new Regex("^" + identifier + "([0-9]+)$");
+			var n = new RegExp("^" + identifier + "([0-9]+)$");
 			foreach (var c in List) {
 				var m = c.Identifier.Match(n);
Index: EcnlProtoTool/trunk/webapp/webmrbc/EObjectModalView.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/EObjectModalView.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/EObjectModalView.cs	(revision 425)
@@ -298,4 +298,5 @@
 		}
 
+		[Convention(Notation.CamelCase)]
 		public void OnChangeIdentifier(Element ele)
 		{
@@ -304,4 +305,5 @@
 		}
 
+		[Convention(Notation.CamelCase)]
 		public void OnSelectAttribute(Element sender, string attribute)
 		{
@@ -310,4 +312,5 @@
 		}
 
+		[Convention(Notation.CamelCase)]
 		public void OnSelectClassGroupCode(jQueryMouseEvent e)
 		{
@@ -318,4 +321,5 @@
 		}
 
+		[Convention(Notation.CamelCase)]
 		public void OnSelectClassCode(jQueryMouseEvent e)
 		{
@@ -323,4 +327,5 @@
 		}
 
+		[Convention(Notation.CamelCase)]
 		public void OnChangeInstanceCode(Element sender)
 		{
@@ -328,4 +333,5 @@
 		}
 
+		[Convention(Notation.CamelCase)]
 		public void OnOk(Element ele)
 		{
@@ -384,4 +390,5 @@
 		}
 
+		[Convention(Notation.CamelCase)]
 		public void OnCancel(Element ele)
 		{
Index: EcnlProtoTool/trunk/webapp/webmrbc/Ecnl/CodeGenerator.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Ecnl/CodeGenerator.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Ecnl/CodeGenerator.cs	(revision 425)
@@ -40,5 +40,5 @@
 using System.Text;
 using Bridge;
-using Bridge.Text.RegularExpressions;
+using Bridge.Html5;
 
 namespace WebMrbc
@@ -61,5 +61,5 @@
 				result = result.Substring(0, result.Length - 4);
 
-			if (!new Regex("^[A-Z][A-Za-z0-9_]+$").Test(result)) {
+			if (!new RegExp("^[A-Z][A-Za-z0-9_]+$").Test(result)) {
 				result = String.Format("Cls{0:X2}{1:X2}", cls.classGroup.classGroupCode, cls.classCode);
 			}
@@ -74,9 +74,9 @@
 			string result = fi.identifier;
 
-			if (!new Regex("^[A-Za-z_][A-Za-z0-9_]+$").Test(result)) {
+			if (!new RegExp("^[A-Za-z_][A-Za-z0-9_]+$").Test(result)) {
 				result = String.Format("property{0:X2}", pi.propertyCode);
 			}
 			else {
-				var reg = new Regex("[A-Z][a-z]+", "g");
+				var reg = new RegExp("[A-Z][a-z]+", "g");
 				string[] m;
 				if ((m = reg.Exec(result)) != null) {
Index: EcnlProtoTool/trunk/webapp/webmrbc/Ecnl/EObjectBlock.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Ecnl/EObjectBlock.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Ecnl/EObjectBlock.cs	(revision 425)
@@ -40,5 +40,4 @@
 using System.Text;
 using Bridge;
-using Bridge.Linq;
 using Bridge.Html5;
 
Index: EcnlProtoTool/trunk/webapp/webmrbc/Ecnl/ValueRange.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Ecnl/ValueRange.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Ecnl/ValueRange.cs	(revision 425)
@@ -40,5 +40,5 @@
 using System.Collections.Generic;
 using Bridge;
-using Bridge.Text.RegularExpressions;
+using Bridge.Html5;
 
 namespace WebMrbc
@@ -412,16 +412,16 @@
 			int pos = 0;
 			while (pos < input.Length) {
-				Regex ms;
+				RegExp ms;
 				string[] m;
-				if ((m = (ms = new Regex(TokenInfo.HexValue)).Exec(input.Substring(pos))) != null) {
+				if ((m = (ms = new RegExp(TokenInfo.HexValue)).Exec(input.Substring(pos))) != null) {
 					tokens.Push(new TokenInfo(m[0], TokenType.HexValue));
 					pos += m[0].Length;
 				}
-				else if ((m = (ms = new Regex(TokenInfo.Numeric)).Exec(input.Substring(pos))) != null) {
+				else if ((m = (ms = new RegExp(TokenInfo.Numeric)).Exec(input.Substring(pos))) != null) {
 					tokens.Push(new TokenInfo(m[0], TokenType.Numeric));
 					pos += m[0].Length;
 				}
 				else {
-					if ((m = (ms = new Regex(TokenInfo.Separetor)).Exec(input.Substring(pos))) == null) {
+					if ((m = (ms = new RegExp(TokenInfo.Separetor)).Exec(input.Substring(pos))) == null) {
 						tokens.Push(new TokenInfo(input.Substring(pos), TokenType.String));
 						break;
@@ -747,7 +747,7 @@
 
 			if (emti.primitive) {
-				string[] lines = valrng.Split(new Regex("\r\n"));
+				string[] lines = valrng.Split(new RegExp("\r\n"));
 				foreach (string line in lines) {
-					if (new Regex("^<(.+)>$").Test(line))
+					if (new RegExp("^<(.+)>$").Test(line))
 						continue;
 
@@ -773,6 +773,6 @@
 					}
 
-					valueRange._Values = (Option[])valueRange._Values.Concat(values);
-					valueRange._Ranges = (Range[])valueRange._Ranges.Concat(ranges);
+					valueRange._Values = valueRange._Values.Concat(values).ToArray();
+					valueRange._Ranges = valueRange._Ranges.Concat(ranges).ToArray();
 					if (bitField != null)
 						valueRange._BitFields.Push(bitField);
Index: EcnlProtoTool/trunk/webapp/webmrbc/Generator.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Generator.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Generator.cs	(revision 425)
@@ -30,5 +30,5 @@
 using System.Runtime.InteropServices;
 using Bridge;
-using Bridge.Text.RegularExpressions;
+using Bridge.Html5;
 
 namespace WebMrbc
@@ -47,5 +47,5 @@
 			this.name_ = name;
 			this.FUNCTION_NAME_PLACEHOLDER_REGEXP_ =
-				new Regex(this.FUNCTION_NAME_PLACEHOLDER_, "g");
+				new RegExp(this.FUNCTION_NAME_PLACEHOLDER_, "g");
 		}
 
@@ -120,5 +120,5 @@
 						line = this.scrubNakedValue(line);
 					}
-					nodes = (node[])nodes.Concat(line);
+					nodes = nodes.Concat(line).ToArray();
 				}
 			}
@@ -137,5 +137,5 @@
 		public string prefixLines(string text, string prefix)
 		{
-			return prefix + text.Replace(new Regex("(?!\n$)\n"), "\n" + prefix);
+			return prefix + text.Replace(new RegExp("(?!\n$)\n"), "\n" + prefix);
 		}
 
@@ -271,5 +271,5 @@
 		/// </summary>
 		public string FUNCTION_NAME_PLACEHOLDER_ = "{leCUI8hutHZI4480Dc}";
-		public Regex FUNCTION_NAME_PLACEHOLDER_REGEXP_;
+		public RegExp FUNCTION_NAME_PLACEHOLDER_REGEXP_;
 	}
 }
Index: EcnlProtoTool/trunk/webapp/webmrbc/MainMenuView.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/MainMenuView.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/MainMenuView.cs	(revision 425)
@@ -43,5 +43,4 @@
 using Bridge.Html5;
 using Bridge.jQuery2;
-using Bridge.Text.RegularExpressions;
 
 namespace WebMrbc
@@ -120,5 +119,5 @@
 
 			if (String.IsNullOrEmpty(outfile) && (i + 1 < rubyfiles.Length))
-				outfile = rubyfiles[i + 1].Replace(new Regex(".rb$", "g"), ext.StartsWith(".") ? ext : ("." + ext));
+				outfile = rubyfiles[i + 1].Replace(new RegExp(".rb$", "g"), ext.StartsWith(".") ? ext : ("." + ext));
 			rubyfiles[i] = outfile;
 		}
Index: EcnlProtoTool/trunk/webapp/webmrbc/MrbAstNodes.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/MrbAstNodes.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/MrbAstNodes.cs	(revision 425)
@@ -563,5 +563,5 @@
 			: base(p, node_type.NODE_SCOPE)
 		{
-			_local_variables = (mrb_sym[])_local_variables.Concat(p.locals_node());
+			_local_variables = _local_variables.Concat(p.locals_node()).ToArray();
 			_body = body;
 		}
@@ -615,5 +615,5 @@
 			: base(p, node_type.NODE_BEGIN)
 		{
-			_progs = (node[])_progs.Concat(progs);
+			_progs = _progs.Concat(progs).ToArray();
 		}
 
@@ -1465,5 +1465,5 @@
 		{
 			_arg = a;
-			_when = (when_t[])_when.Concat(b);
+			_when = _when.Concat(b).ToArray();
 		}
 
@@ -1658,5 +1658,5 @@
 			_method = b;
 			if (args != null)
-				_args = (node[])_args.Concat(args);
+				_args = _args.Concat(args).ToArray();
 			_block = block;
 		}
@@ -1913,5 +1913,5 @@
 			_method = b;
 			if (args != null)
-				_args = (node[])_args.Concat(args);
+				_args = _args.Concat(args).ToArray();
 			_block = block;
 		}
@@ -2029,5 +2029,5 @@
 			: base(p, node_type.NODE_SUPER)
 		{
-			_args = (node[])_args.Concat(args);
+			_args = _args.Concat(args).ToArray();
 		}
 
@@ -2663,5 +2663,5 @@
 			: base(p, node_type.NODE_ARRAY)
 		{
-			_array = (node[])_array.Concat(a);
+			_array = _array.Concat(a).ToArray();
 			_item_per_line = item_per_line;
 		}
@@ -2794,5 +2794,5 @@
 			: base(p, node_type.NODE_HASH)
 		{
-			_kvs = (kv_t[])_kvs.Concat(items);
+			_kvs = _kvs.Concat(items).ToArray();
 		}
 
@@ -3347,5 +3347,5 @@
 		{
 			_name = m;
-			_local_variables = (mrb_sym[])_local_variables.Concat(p.locals_node());
+			_local_variables = _local_variables.Concat(p.locals_node()).ToArray();
 			if (a != null) {
 				node n = a;
@@ -3388,5 +3388,5 @@
 		{
 			_name = m;
-			_mandatory_args = (arg_node[])_mandatory_args.Concat(a);
+			_mandatory_args = _mandatory_args.Concat(a).ToArray();
 			_body = b;
 		}
@@ -3677,5 +3677,5 @@
 			: base(p, node_type.NODE_BLOCK)
 		{
-			_local_variables = (mrb_sym[])_local_variables.Concat(p.locals_node());
+			_local_variables = _local_variables.Concat(p.locals_node()).ToArray();
 			if (args != null) {
 				node n = args;
@@ -3718,5 +3718,5 @@
 			: base(p, node_type.NODE_BLOCK)
 		{
-			_mandatory_args = (node[])_mandatory_args.Concat(args);
+			_mandatory_args = _mandatory_args.Concat(args).ToArray();
 			_body = body;
 			if (_body is ensure_node) {
@@ -3815,5 +3815,5 @@
 			: base(p, node_type.NODE_LAMBDA)
 		{
-			_local_variables = (mrb_sym[])_local_variables.Concat(p.locals_node());
+			_local_variables = _local_variables.Concat(p.locals_node()).ToArray();
 			if (a != null) {
 				node n = a;
Index: EcnlProtoTool/trunk/webapp/webmrbc/MrbScanner.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/MrbScanner.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/MrbScanner.cs	(revision 425)
@@ -342,8 +342,8 @@
 			if (utf32 >= 0x10000) {
 				var ch = utf32 - 0x10000;
-				str += String.FromCharCode(0xD800 | (ch >> 10), 0xDC00 | (ch & 0x3FF));
+				str += StringPrototype.FromCharCode(0xD800 | (ch >> 10), 0xDC00 | (ch & 0x3FF));
 			}
 			else {
-				str += String.FromCharCode(utf32);
+				str += StringPrototype.FromCharCode(utf32);
 			}
 			return str;
@@ -506,5 +506,5 @@
 		private mrb_sym get_sym(string str)
 		{
-			int i = syms.IndexOf(str);
+			int i = Array.IndexOf(syms, str);
 			if (i < 0) {
 				i = syms.Length;
Index: EcnlProtoTool/trunk/webapp/webmrbc/Mruby.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Mruby.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Mruby.cs	(revision 425)
@@ -40,5 +40,4 @@
 using Bridge;
 using Bridge.Html5;
-using Bridge.Text.RegularExpressions;
 
 namespace WebMrbc
@@ -141,5 +140,5 @@
 			var progressElement = (HTMLProgressElement)Document.GetElementById("progress");
 			var spinnerElement = (HTMLDivElement)Document.GetElementById("spinner");
-			var m = text.Match(new Regex(@"([^(]+)\((\d+(\.\d+)?)\/(\d+)\)"));
+			var m = text.Match(new RegExp(@"([^(]+)\((\d+(\.\d+)?)\/(\d+)\)"));
 			var now = DateTime.Now.Ticks;
 			if (m != null && now - DateTime.Now.Ticks < 30) return; // if this is a progress update, skip it if too soon
@@ -170,5 +169,5 @@
 		}
 
-		[External, Name(false)]
+		[External, Convention(Notation.PascalCase)]
 		internal string UTF8ArrayToString(Uint8Array buf, int index)
 		{
@@ -194,5 +193,5 @@
 		}
 
-		[Name(false)]
+		[Convention(Notation.PascalCase)]
 		internal Uint8Array UTF8StringToArray(string str)
 		{
Index: EcnlProtoTool/trunk/webapp/webmrbc/Names.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Names.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Names.cs	(revision 425)
@@ -25,5 +25,5 @@
 using System.Runtime.InteropServices;
 using Bridge;
-using Bridge.Text.RegularExpressions;
+using Bridge.Html5;
 
 namespace WebMrbc
@@ -91,5 +91,5 @@
 			}
 			var safeName = this.getDistinctName(name, type);
-			this.db_[normalized] = safeName.Substr(prefix.Length);
+			this.db_[normalized] = safeName.Substring(prefix.Length);
 			return safeName;
 		}
@@ -137,5 +137,5 @@
 				// Unfortunately names in non-latin characters will look like
 				// _E9_9F_B3_E4_B9_90 which is pretty meaningless.
-				name = Script.EncodeURI(name.Replace(new Regex(" "), "_").Replace(new Regex(@"[^\w]"), "_"));
+				name = Script.EncodeURI(name.Replace(new RegExp(" "), "_").Replace(new RegExp(@"[^\w]"), "_"));
 				// Most languages don't allow names with leading numbers.
 				if ("0123456789".IndexOf(name[0]) != -1) {
Index: EcnlProtoTool/trunk/webapp/webmrbc/Procedures.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Procedures.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Procedures.cs	(revision 425)
@@ -28,5 +28,4 @@
 using Bridge;
 using Bridge.Html5;
-using Bridge.Text.RegularExpressions;
 using WebMrbc;
 
@@ -103,5 +102,5 @@
 			while (!isLegalName_(name, block.workspace, block)) {
 				// Collision with another procedure.
-				var r = new Regex(@"^(.*?)(\d+)$").Exec(name);
+				var r = new RegExp(@"^(.*?)(\d+)$").Exec(name);
 				if (r == null) {
 					name += "2";
@@ -152,5 +151,5 @@
 		{
 			// Strip leading and trailing whitespace.  Beyond this, all names are legal.
-			name = name.Replace(new Regex(@"^[\s\xa0] +|[\s\xa0] +$"), "");
+			name = name.Replace(new RegExp(@"^[\s\xa0] +|[\s\xa0] +$"), "");
 
 			// Ensure two identically-named procedures don't exist.
Index: EcnlProtoTool/trunk/webapp/webmrbc/Ruby.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Ruby.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Ruby.cs	(revision 425)
@@ -6,5 +6,4 @@
 using System.Linq;
 using Bridge;
-using Bridge.Text.RegularExpressions;
 using System.Collections.Generic;
 using System.Runtime.InteropServices;
@@ -115,5 +114,5 @@
 			if (nextCode == null)
 				return code;
-			return (node[])code.Concat(nextCode);
+			return code.Concat(nextCode).ToArray();
 		}
 
@@ -126,5 +125,5 @@
 		private mrb_sym get_sym(string str)
 		{
-			int i = syms.IndexOf(str);
+			int i = Array.IndexOf(syms, str);
 			if (i < 0) {
 				i = syms.Length;
@@ -149,5 +148,5 @@
 		mrb_sym get_var_name(string str)
 		{
-			int i = syms.IndexOf(str);
+			int i = Array.IndexOf(syms, str);
 
 			// ローカル変数なら登録されているはずなので、
Index: EcnlProtoTool/trunk/webapp/webmrbc/Variables.cs
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/Variables.cs	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/Variables.cs	(revision 425)
@@ -28,5 +28,4 @@
 using Bridge;
 using Bridge.Html5;
-using Bridge.Text.RegularExpressions;
 using WebMrbc;
 
@@ -299,5 +298,5 @@
 				// Beyond this, all names are legal.
 				if (newVar != null) {
-					newVar = newVar.Replace(new Regex(@"[\s\xa0] +"), " ").Replace(new Regex("^ | $"), "");
+					newVar = newVar.Replace(new RegExp(@"[\s\xa0] +"), " ").Replace(new RegExp("^ | $"), "");
 					if (newVar == Msg.RENAME_VARIABLE ||
 						newVar == Msg.NEW_VARIABLE) {
Index: EcnlProtoTool/trunk/webapp/webmrbc/packages.config
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/packages.config	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/packages.config	(revision 425)
@@ -1,10 +1,10 @@
 ﻿<?xml version="1.0" encoding="utf-8"?>
 <packages>
-  <package id="Bridge" version="15.7.0" targetFramework="net45" />
-  <package id="Bridge.Bootstrap" version="3.9.4" targetFramework="net45" />
-  <package id="Bridge.Core" version="15.7.0" targetFramework="net45" />
-  <package id="Bridge.Html5" version="15.7.0" targetFramework="net45" />
-  <package id="Bridge.jQuery" version="2.9.3" targetFramework="net45" />
-  <package id="Bridge.Min" version="15.7.0" targetFramework="net45" />
-  <package id="Bridge.WebGL" version="1.8.3" targetFramework="net45" />
+  <package id="Bridge" version="17.10.1" targetFramework="net45" />
+  <package id="Bridge.Bootstrap" version="3.24.0" targetFramework="net45" />
+  <package id="Bridge.Core" version="17.10.1" targetFramework="net45" />
+  <package id="Bridge.Html5" version="17.10.0" targetFramework="net45" />
+  <package id="Bridge.jQuery" version="2.24.0" targetFramework="net45" />
+  <package id="Bridge.Min" version="17.10.1" targetFramework="net45" />
+  <package id="Bridge.WebGL" version="1.23.0" targetFramework="net45" />
 </packages>
Index: EcnlProtoTool/trunk/webapp/webmrbc/webmrbc.csproj
===================================================================
--- EcnlProtoTool/trunk/webapp/webmrbc/webmrbc.csproj	(revision 424)
+++ EcnlProtoTool/trunk/webapp/webmrbc/webmrbc.csproj	(revision 425)
@@ -23,4 +23,5 @@
     <NuGetPackageImportStamp>
     </NuGetPackageImportStamp>
+    <Use64BitIISExpress />
   </PropertyGroup>
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
@@ -43,26 +44,4 @@
     <NoStdLib>true</NoStdLib>
   </PropertyGroup>
-  <ItemGroup>
-    <Reference Include="Bridge, Version=15.7.0.0, Culture=neutral, processorArchitecture=MSIL">
-      <HintPath>..\packages\Bridge.Core.15.7.0\lib\net40\Bridge.dll</HintPath>
-      <Private>True</Private>
-    </Reference>
-    <Reference Include="Bridge.Bootstrap3, Version=3.9.0.0, Culture=neutral, processorArchitecture=MSIL">
-      <HintPath>..\packages\Bridge.Bootstrap.3.9.4\lib\net40\Bridge.Bootstrap3.dll</HintPath>
-      <Private>True</Private>
-    </Reference>
-    <Reference Include="Bridge.Html5, Version=15.7.0.0, Culture=neutral, processorArchitecture=MSIL">
-      <HintPath>..\packages\Bridge.Html5.15.7.0\lib\net40\Bridge.Html5.dll</HintPath>
-      <Private>True</Private>
-    </Reference>
-    <Reference Include="Bridge.jQuery2, Version=2.9.0.0, Culture=neutral, processorArchitecture=MSIL">
-      <HintPath>..\packages\Bridge.jQuery.2.9.3\lib\net40\Bridge.jQuery2.dll</HintPath>
-      <Private>True</Private>
-    </Reference>
-    <Reference Include="Bridge.WebGL, Version=1.8.0.0, Culture=neutral, processorArchitecture=MSIL">
-      <HintPath>..\packages\Bridge.WebGL.1.8.3\lib\net40\Bridge.WebGL.dll</HintPath>
-      <Private>True</Private>
-    </Reference>
-  </ItemGroup>
   <ItemGroup>
     <Content Include="ace\ace.js" />
@@ -89,5 +68,4 @@
     <Content Include="xterm\src\xterm.css" />
     <Content Include="xterm\src\xterm.js" />
-    <Content Include="packages.config" />
     <Content Include="Bridge\bridge.json" />
     <Content Include="bootstrap\fonts\glyphicons-halflings-regular.eot" />
@@ -97,4 +75,6 @@
     <Content Include="echonet_objects.json" />
     <Content Include="information.json" />
+    <Content Include="bridge.json" />
+    <None Include="packages.config" />
     <None Include="Web.Debug.config">
       <DependentUpon>Web.config</DependentUpon>
@@ -171,4 +151,21 @@
     <Compile Include="XTerm.cs" />
   </ItemGroup>
+  <ItemGroup>
+    <Reference Include="Bridge, Version=17.10.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\Bridge.Core.17.10.1\lib\net40\Bridge.dll</HintPath>
+    </Reference>
+    <Reference Include="Bridge.Bootstrap3, Version=3.24.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\Bridge.Bootstrap.3.24.0\lib\net40\Bridge.Bootstrap3.dll</HintPath>
+    </Reference>
+    <Reference Include="Bridge.Html5, Version=17.10.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\Bridge.Html5.17.10.0\lib\net40\Bridge.Html5.dll</HintPath>
+    </Reference>
+    <Reference Include="Bridge.jQuery2, Version=2.24.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\Bridge.jQuery.2.24.0\lib\net40\Bridge.jQuery2.dll</HintPath>
+    </Reference>
+    <Reference Include="Bridge.WebGL, Version=1.23.0.0, Culture=neutral, processorArchitecture=MSIL">
+      <HintPath>..\packages\Bridge.WebGL.1.23.0\lib\net40\Bridge.WebGL.dll</HintPath>
+    </Reference>
+  </ItemGroup>
   <PropertyGroup>
     <VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
@@ -196,15 +193,15 @@
     </VisualStudio>
   </ProjectExtensions>
-  <Import Project="..\packages\Bridge.Min.15.7.0\build\Bridge.Min.targets" Condition="Exists('..\packages\Bridge.Min.15.7.0\build\Bridge.Min.targets')" />
+  <PropertyGroup>
+    <PostBuildEvent>cd $(ProjectDir)
+call copy.bat</PostBuildEvent>
+  </PropertyGroup>
+  <Import Project="..\packages\Bridge.Min.17.10.1\build\Bridge.Min.targets" Condition="Exists('..\packages\Bridge.Min.17.10.1\build\Bridge.Min.targets')" />
   <Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
     <PropertyGroup>
       <ErrorText>このプロジェクトは、このコンピューター上にない NuGet パッケージを参照しています。それらのパッケージをダウンロードするには、[NuGet パッケージの復元] を使用します。詳細については、http://go.microsoft.com/fwlink/?LinkID=322105 を参照してください。見つからないファイルは {0} です。</ErrorText>
     </PropertyGroup>
-    <Error Condition="!Exists('..\packages\Bridge.Min.15.7.0\build\Bridge.Min.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Bridge.Min.15.7.0\build\Bridge.Min.targets'))" />
+    <Error Condition="!Exists('..\packages\Bridge.Min.17.10.1\build\Bridge.Min.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\Bridge.Min.17.10.1\build\Bridge.Min.targets'))" />
   </Target>
-  <PropertyGroup>
-    <PostBuildEvent>cd $(ProjectDir)
-call copy.bat</PostBuildEvent>
-  </PropertyGroup>
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
        Other similar extension points exist, see Microsoft.Common.targets.
