From 850de6e67ecb008c1070819057c810501d188b89 Mon Sep 17 00:00:00 2001 From: Ryan Huffman Date: Thu, 5 Feb 2015 11:19:01 -0800 Subject: [PATCH] Add User Data to entity properties panel --- examples/html/entityProperties.html | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/examples/html/entityProperties.html b/examples/html/entityProperties.html index a671325e39..cee7f578e5 100644 --- a/examples/html/entityProperties.html +++ b/examples/html/entityProperties.html @@ -119,6 +119,7 @@ var elCollisionsWillMove = document.getElementById("property-collisions-will-move"); var elLifetime = document.getElementById("property-lifetime"); var elScriptURL = document.getElementById("property-script-url"); + var elUserData = document.getElementById("property-user-data"); var elBoxSections = document.querySelectorAll(".box-section"); var elBoxColorRed = document.getElementById("property-box-red"); @@ -224,6 +225,7 @@ elCollisionsWillMove.checked = properties.collisionsWillMove; elLifetime.value = properties.lifetime; elScriptURL.value = properties.script; + elUserData.value = properties.userData; if (properties.type != "Box") { for (var i = 0; i < elBoxSections.length; i++) { @@ -361,6 +363,7 @@ elCollisionsWillMove.addEventListener('change', createEmitCheckedPropertyUpdateFunction('collisionsWillMove')); elLifetime.addEventListener('change', createEmitNumberPropertyUpdateFunction('lifetime')); elScriptURL.addEventListener('change', createEmitTextPropertyUpdateFunction('script')); + elUserData.addEventListener('change', createEmitTextPropertyUpdateFunction('userData')); var boxColorChangeFunction = createEmitColorPropertyUpdateFunction( 'color', elBoxColorRed, elBoxColorGreen, elBoxColorBlue); @@ -593,6 +596,13 @@ +
+
User Data
+
+ +
+
+
Color