Sfoglia il codice sorgente

Merge pull request #641 from seanpaultaylor/next

Next
Sean Paul Taylor 13 anni fa
parent
commit
72a7b4c7fc

+ 36 - 10
gameplay/src/Control.cpp

@@ -244,6 +244,27 @@ bool Control::getAutoHeight() const
     return _autoHeight;
 }
 
+void Control::setVisible(bool visible)
+{
+    if (visible && !_visible)
+    {
+        setEnabled(true);
+        _visible = true;
+        _dirty = true;
+    }
+    else if (!visible && _visible)
+    {
+        setEnabled(false);
+        _visible = false;
+        _dirty = true;
+    }
+}
+
+bool Control::isVisible() const
+{
+    return _visible;
+}
+
 void Control::setOpacity(float opacity, unsigned char states)
 {
     overrideStyle();
@@ -597,19 +618,21 @@ Control::State Control::getState() const
     return _state;
 }
 
-void Control::disable()
+void Control::setEnabled(bool enabled)
 {
-    _state = DISABLED;
-    _dirty = true;
+	if (enabled && _state == Control::DISABLED)
+	{
+		_state = Control::NORMAL;
+		_dirty = true;
+	}
+	else if (!enabled && _state != Control::DISABLED)
+	{
+		_state = Control::DISABLED;
+		_dirty = true;
+	}
 }
 
-void Control::enable()
-{
-    _state = NORMAL;
-    _dirty = true;
-}
-
-bool Control::isEnabled()
+bool Control::isEnabled() const
 {
     return _state != DISABLED;
 }
@@ -1019,6 +1042,9 @@ void Control::drawText(const Rectangle& position)
 
 void Control::draw(SpriteBatch* spriteBatch, const Rectangle& clip, bool needsClear, bool cleared, float targetHeight)
 {
+    if (!_visible)
+        return;
+
     if (needsClear)
     {
         GL_ASSERT( glEnable(GL_SCISSOR_TEST) );

+ 28 - 10
gameplay/src/Control.h

@@ -590,6 +590,22 @@ public:
      */
     bool getTextRightToLeft(State state = NORMAL) const;
 
+    /**
+     * Sets the visibility of a control.
+     *
+     * This is a quick way to hide a control without having to remove it from a form.
+     *
+     * @param visible true if the control is visible and enabled; false if not-visible and disabled.
+     */
+    void setVisible(bool visible);
+
+    /**
+     * Get the visibility of a control.
+     *
+     * @return true if the control is visible; false if not visible.
+     */
+    bool isVisible() const;
+
     /**
      * Set the opacity of this control.
      *
@@ -636,22 +652,19 @@ public:
      */
     State getState() const;
 
-    /**
-     * Disable this control.
-     */
-    void disable();
-
-    /**
-     * Enable this control.
-     */
-    void enable();
+	/**
+	 * Enables/Disables a control. 
+	 *
+	 * @param enabled true if the control is enabled; false if disabled.
+	 */
+	void setEnabled(bool enabled);
 
     /**
      * Get whether this control is currently enabled.
      *
      * @return Whether this control is currently enabled.
      */
-    bool isEnabled();
+    bool isEnabled() const;
 
     /**
      * Set whether this control consumes input events,
@@ -993,6 +1006,11 @@ protected:
      */
     Theme::Style* _style;
 
+    /**
+     * The control is not visible and _state become DISABLED if false.
+     */
+    bool _visible;
+
     /**
      * The current opacity of the control.
      */

+ 110 - 66
gameplay/src/lua/lua_Button.cpp

@@ -32,8 +32,6 @@ void luaRegister_Button()
         {"createAnimationFromBy", lua_Button_createAnimationFromBy},
         {"createAnimationFromTo", lua_Button_createAnimationFromTo},
         {"destroyAnimation", lua_Button_destroyAnimation},
-        {"disable", lua_Button_disable},
-        {"enable", lua_Button_enable},
         {"getAlignment", lua_Button_getAlignment},
         {"getAnimation", lua_Button_getAnimation},
         {"getAnimationPropertyComponentCount", lua_Button_getAnimationPropertyComponentCount},
@@ -74,6 +72,7 @@ void luaRegister_Button()
         {"getZIndex", lua_Button_getZIndex},
         {"isContainer", lua_Button_isContainer},
         {"isEnabled", lua_Button_isEnabled},
+        {"isVisible", lua_Button_isVisible},
         {"release", lua_Button_release},
         {"removeListener", lua_Button_removeListener},
         {"removeScriptCallback", lua_Button_removeScriptCallback},
@@ -86,6 +85,7 @@ void luaRegister_Button()
         {"setConsumeInputEvents", lua_Button_setConsumeInputEvents},
         {"setCursorColor", lua_Button_setCursorColor},
         {"setCursorRegion", lua_Button_setCursorRegion},
+        {"setEnabled", lua_Button_setEnabled},
         {"setFocusIndex", lua_Button_setFocusIndex},
         {"setFont", lua_Button_setFont},
         {"setFontSize", lua_Button_setFontSize},
@@ -105,6 +105,7 @@ void luaRegister_Button()
         {"setTextAlignment", lua_Button_setTextAlignment},
         {"setTextColor", lua_Button_setTextColor},
         {"setTextRightToLeft", lua_Button_setTextRightToLeft},
+        {"setVisible", lua_Button_setVisible},
         {"setWidth", lua_Button_setWidth},
         {"setZIndex", lua_Button_setZIndex},
         {NULL, NULL}
@@ -678,70 +679,6 @@ int lua_Button_destroyAnimation(lua_State* state)
     return 0;
 }
 
-int lua_Button_disable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Button* instance = getInstance(state);
-                instance->disable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Button_disable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
-int lua_Button_enable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Button* instance = getInstance(state);
-                instance->enable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Button_enable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
 int lua_Button_getAlignment(lua_State* state)
 {
     // Get the number of parameters.
@@ -2619,6 +2556,41 @@ int lua_Button_isEnabled(lua_State* state)
     return 0;
 }
 
+int lua_Button_isVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 1:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA))
+            {
+                Button* instance = getInstance(state);
+                bool result = instance->isVisible();
+
+                // Push the return value onto the stack.
+                lua_pushboolean(state, result);
+
+                return 1;
+            }
+
+            lua_pushstring(state, "lua_Button_isVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 1).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Button_release(lua_State* state)
 {
     // Get the number of parameters.
@@ -3171,6 +3143,42 @@ int lua_Button_setCursorRegion(lua_State* state)
     return 0;
 }
 
+int lua_Button_setEnabled(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Button* instance = getInstance(state);
+                instance->setEnabled(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Button_setEnabled - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Button_setFocusIndex(lua_State* state)
 {
     // Get the number of parameters.
@@ -4201,6 +4209,42 @@ int lua_Button_setTextRightToLeft(lua_State* state)
     return 0;
 }
 
+int lua_Button_setVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Button* instance = getInstance(state);
+                instance->setVisible(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Button_setVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Button_setWidth(lua_State* state)
 {
     // Get the number of parameters.

+ 3 - 2
gameplay/src/lua/lua_Button.h

@@ -13,8 +13,6 @@ int lua_Button_createAnimation(lua_State* state);
 int lua_Button_createAnimationFromBy(lua_State* state);
 int lua_Button_createAnimationFromTo(lua_State* state);
 int lua_Button_destroyAnimation(lua_State* state);
-int lua_Button_disable(lua_State* state);
-int lua_Button_enable(lua_State* state);
 int lua_Button_getAlignment(lua_State* state);
 int lua_Button_getAnimation(lua_State* state);
 int lua_Button_getAnimationPropertyComponentCount(lua_State* state);
@@ -55,6 +53,7 @@ int lua_Button_getY(lua_State* state);
 int lua_Button_getZIndex(lua_State* state);
 int lua_Button_isContainer(lua_State* state);
 int lua_Button_isEnabled(lua_State* state);
+int lua_Button_isVisible(lua_State* state);
 int lua_Button_release(lua_State* state);
 int lua_Button_removeListener(lua_State* state);
 int lua_Button_removeScriptCallback(lua_State* state);
@@ -67,6 +66,7 @@ int lua_Button_setBounds(lua_State* state);
 int lua_Button_setConsumeInputEvents(lua_State* state);
 int lua_Button_setCursorColor(lua_State* state);
 int lua_Button_setCursorRegion(lua_State* state);
+int lua_Button_setEnabled(lua_State* state);
 int lua_Button_setFocusIndex(lua_State* state);
 int lua_Button_setFont(lua_State* state);
 int lua_Button_setFontSize(lua_State* state);
@@ -86,6 +86,7 @@ int lua_Button_setText(lua_State* state);
 int lua_Button_setTextAlignment(lua_State* state);
 int lua_Button_setTextColor(lua_State* state);
 int lua_Button_setTextRightToLeft(lua_State* state);
+int lua_Button_setVisible(lua_State* state);
 int lua_Button_setWidth(lua_State* state);
 int lua_Button_setZIndex(lua_State* state);
 int lua_Button_static_ANIMATE_OPACITY(lua_State* state);

+ 110 - 66
gameplay/src/lua/lua_CheckBox.cpp

@@ -33,8 +33,6 @@ void luaRegister_CheckBox()
         {"createAnimationFromBy", lua_CheckBox_createAnimationFromBy},
         {"createAnimationFromTo", lua_CheckBox_createAnimationFromTo},
         {"destroyAnimation", lua_CheckBox_destroyAnimation},
-        {"disable", lua_CheckBox_disable},
-        {"enable", lua_CheckBox_enable},
         {"getAlignment", lua_CheckBox_getAlignment},
         {"getAnimation", lua_CheckBox_getAnimation},
         {"getAnimationPropertyComponentCount", lua_CheckBox_getAnimationPropertyComponentCount},
@@ -78,6 +76,7 @@ void luaRegister_CheckBox()
         {"isChecked", lua_CheckBox_isChecked},
         {"isContainer", lua_CheckBox_isContainer},
         {"isEnabled", lua_CheckBox_isEnabled},
+        {"isVisible", lua_CheckBox_isVisible},
         {"release", lua_CheckBox_release},
         {"removeListener", lua_CheckBox_removeListener},
         {"removeScriptCallback", lua_CheckBox_removeScriptCallback},
@@ -91,6 +90,7 @@ void luaRegister_CheckBox()
         {"setConsumeInputEvents", lua_CheckBox_setConsumeInputEvents},
         {"setCursorColor", lua_CheckBox_setCursorColor},
         {"setCursorRegion", lua_CheckBox_setCursorRegion},
+        {"setEnabled", lua_CheckBox_setEnabled},
         {"setFocusIndex", lua_CheckBox_setFocusIndex},
         {"setFont", lua_CheckBox_setFont},
         {"setFontSize", lua_CheckBox_setFontSize},
@@ -111,6 +111,7 @@ void luaRegister_CheckBox()
         {"setTextAlignment", lua_CheckBox_setTextAlignment},
         {"setTextColor", lua_CheckBox_setTextColor},
         {"setTextRightToLeft", lua_CheckBox_setTextRightToLeft},
+        {"setVisible", lua_CheckBox_setVisible},
         {"setWidth", lua_CheckBox_setWidth},
         {"setZIndex", lua_CheckBox_setZIndex},
         {NULL, NULL}
@@ -684,70 +685,6 @@ int lua_CheckBox_destroyAnimation(lua_State* state)
     return 0;
 }
 
-int lua_CheckBox_disable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                CheckBox* instance = getInstance(state);
-                instance->disable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_CheckBox_disable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
-int lua_CheckBox_enable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                CheckBox* instance = getInstance(state);
-                instance->enable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_CheckBox_enable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
 int lua_CheckBox_getAlignment(lua_State* state)
 {
     // Get the number of parameters.
@@ -2739,6 +2676,41 @@ int lua_CheckBox_isEnabled(lua_State* state)
     return 0;
 }
 
+int lua_CheckBox_isVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 1:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA))
+            {
+                CheckBox* instance = getInstance(state);
+                bool result = instance->isVisible();
+
+                // Push the return value onto the stack.
+                lua_pushboolean(state, result);
+
+                return 1;
+            }
+
+            lua_pushstring(state, "lua_CheckBox_isVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 1).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_CheckBox_release(lua_State* state)
 {
     // Get the number of parameters.
@@ -3327,6 +3299,42 @@ int lua_CheckBox_setCursorRegion(lua_State* state)
     return 0;
 }
 
+int lua_CheckBox_setEnabled(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                CheckBox* instance = getInstance(state);
+                instance->setEnabled(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_CheckBox_setEnabled - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_CheckBox_setFocusIndex(lua_State* state)
 {
     // Get the number of parameters.
@@ -4397,6 +4405,42 @@ int lua_CheckBox_setTextRightToLeft(lua_State* state)
     return 0;
 }
 
+int lua_CheckBox_setVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                CheckBox* instance = getInstance(state);
+                instance->setVisible(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_CheckBox_setVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_CheckBox_setWidth(lua_State* state)
 {
     // Get the number of parameters.

+ 3 - 2
gameplay/src/lua/lua_CheckBox.h

@@ -13,8 +13,6 @@ int lua_CheckBox_createAnimation(lua_State* state);
 int lua_CheckBox_createAnimationFromBy(lua_State* state);
 int lua_CheckBox_createAnimationFromTo(lua_State* state);
 int lua_CheckBox_destroyAnimation(lua_State* state);
-int lua_CheckBox_disable(lua_State* state);
-int lua_CheckBox_enable(lua_State* state);
 int lua_CheckBox_getAlignment(lua_State* state);
 int lua_CheckBox_getAnimation(lua_State* state);
 int lua_CheckBox_getAnimationPropertyComponentCount(lua_State* state);
@@ -58,6 +56,7 @@ int lua_CheckBox_getZIndex(lua_State* state);
 int lua_CheckBox_isChecked(lua_State* state);
 int lua_CheckBox_isContainer(lua_State* state);
 int lua_CheckBox_isEnabled(lua_State* state);
+int lua_CheckBox_isVisible(lua_State* state);
 int lua_CheckBox_release(lua_State* state);
 int lua_CheckBox_removeListener(lua_State* state);
 int lua_CheckBox_removeScriptCallback(lua_State* state);
@@ -71,6 +70,7 @@ int lua_CheckBox_setChecked(lua_State* state);
 int lua_CheckBox_setConsumeInputEvents(lua_State* state);
 int lua_CheckBox_setCursorColor(lua_State* state);
 int lua_CheckBox_setCursorRegion(lua_State* state);
+int lua_CheckBox_setEnabled(lua_State* state);
 int lua_CheckBox_setFocusIndex(lua_State* state);
 int lua_CheckBox_setFont(lua_State* state);
 int lua_CheckBox_setFontSize(lua_State* state);
@@ -91,6 +91,7 @@ int lua_CheckBox_setText(lua_State* state);
 int lua_CheckBox_setTextAlignment(lua_State* state);
 int lua_CheckBox_setTextColor(lua_State* state);
 int lua_CheckBox_setTextRightToLeft(lua_State* state);
+int lua_CheckBox_setVisible(lua_State* state);
 int lua_CheckBox_setWidth(lua_State* state);
 int lua_CheckBox_setZIndex(lua_State* state);
 int lua_CheckBox_static_ANIMATE_OPACITY(lua_State* state);

+ 110 - 66
gameplay/src/lua/lua_Container.cpp

@@ -45,8 +45,6 @@ void luaRegister_Container()
         {"createAnimationFromBy", lua_Container_createAnimationFromBy},
         {"createAnimationFromTo", lua_Container_createAnimationFromTo},
         {"destroyAnimation", lua_Container_destroyAnimation},
-        {"disable", lua_Container_disable},
-        {"enable", lua_Container_enable},
         {"getAlignment", lua_Container_getAlignment},
         {"getAnimation", lua_Container_getAnimation},
         {"getAnimationPropertyComponentCount", lua_Container_getAnimationPropertyComponentCount},
@@ -93,6 +91,7 @@ void luaRegister_Container()
         {"isEnabled", lua_Container_isEnabled},
         {"isScrollBarsAutoHide", lua_Container_isScrollBarsAutoHide},
         {"isScrolling", lua_Container_isScrolling},
+        {"isVisible", lua_Container_isVisible},
         {"release", lua_Container_release},
         {"removeControl", lua_Container_removeControl},
         {"removeListener", lua_Container_removeListener},
@@ -106,6 +105,7 @@ void luaRegister_Container()
         {"setConsumeInputEvents", lua_Container_setConsumeInputEvents},
         {"setCursorColor", lua_Container_setCursorColor},
         {"setCursorRegion", lua_Container_setCursorRegion},
+        {"setEnabled", lua_Container_setEnabled},
         {"setFocusIndex", lua_Container_setFocusIndex},
         {"setFont", lua_Container_setFont},
         {"setFontSize", lua_Container_setFontSize},
@@ -126,6 +126,7 @@ void luaRegister_Container()
         {"setTextAlignment", lua_Container_setTextAlignment},
         {"setTextColor", lua_Container_setTextColor},
         {"setTextRightToLeft", lua_Container_setTextRightToLeft},
+        {"setVisible", lua_Container_setVisible},
         {"setWidth", lua_Container_setWidth},
         {"setZIndex", lua_Container_setZIndex},
         {NULL, NULL}
@@ -745,70 +746,6 @@ int lua_Container_destroyAnimation(lua_State* state)
     return 0;
 }
 
-int lua_Container_disable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Container* instance = getInstance(state);
-                instance->disable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Container_disable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
-int lua_Container_enable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Container* instance = getInstance(state);
-                instance->enable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Container_enable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
 int lua_Container_getAlignment(lua_State* state)
 {
     // Get the number of parameters.
@@ -2959,6 +2896,41 @@ int lua_Container_isScrolling(lua_State* state)
     return 0;
 }
 
+int lua_Container_isVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 1:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA))
+            {
+                Container* instance = getInstance(state);
+                bool result = instance->isVisible();
+
+                // Push the return value onto the stack.
+                lua_pushboolean(state, result);
+
+                return 1;
+            }
+
+            lua_pushstring(state, "lua_Container_isVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 1).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Container_release(lua_State* state)
 {
     // Get the number of parameters.
@@ -3583,6 +3555,42 @@ int lua_Container_setCursorRegion(lua_State* state)
     return 0;
 }
 
+int lua_Container_setEnabled(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Container* instance = getInstance(state);
+                instance->setEnabled(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Container_setEnabled - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Container_setFocusIndex(lua_State* state)
 {
     // Get the number of parameters.
@@ -4649,6 +4657,42 @@ int lua_Container_setTextRightToLeft(lua_State* state)
     return 0;
 }
 
+int lua_Container_setVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Container* instance = getInstance(state);
+                instance->setVisible(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Container_setVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Container_setWidth(lua_State* state)
 {
     // Get the number of parameters.

+ 3 - 2
gameplay/src/lua/lua_Container.h

@@ -14,8 +14,6 @@ int lua_Container_createAnimation(lua_State* state);
 int lua_Container_createAnimationFromBy(lua_State* state);
 int lua_Container_createAnimationFromTo(lua_State* state);
 int lua_Container_destroyAnimation(lua_State* state);
-int lua_Container_disable(lua_State* state);
-int lua_Container_enable(lua_State* state);
 int lua_Container_getAlignment(lua_State* state);
 int lua_Container_getAnimation(lua_State* state);
 int lua_Container_getAnimationPropertyComponentCount(lua_State* state);
@@ -62,6 +60,7 @@ int lua_Container_isContainer(lua_State* state);
 int lua_Container_isEnabled(lua_State* state);
 int lua_Container_isScrollBarsAutoHide(lua_State* state);
 int lua_Container_isScrolling(lua_State* state);
+int lua_Container_isVisible(lua_State* state);
 int lua_Container_release(lua_State* state);
 int lua_Container_removeControl(lua_State* state);
 int lua_Container_removeListener(lua_State* state);
@@ -75,6 +74,7 @@ int lua_Container_setBounds(lua_State* state);
 int lua_Container_setConsumeInputEvents(lua_State* state);
 int lua_Container_setCursorColor(lua_State* state);
 int lua_Container_setCursorRegion(lua_State* state);
+int lua_Container_setEnabled(lua_State* state);
 int lua_Container_setFocusIndex(lua_State* state);
 int lua_Container_setFont(lua_State* state);
 int lua_Container_setFontSize(lua_State* state);
@@ -95,6 +95,7 @@ int lua_Container_setStyle(lua_State* state);
 int lua_Container_setTextAlignment(lua_State* state);
 int lua_Container_setTextColor(lua_State* state);
 int lua_Container_setTextRightToLeft(lua_State* state);
+int lua_Container_setVisible(lua_State* state);
 int lua_Container_setWidth(lua_State* state);
 int lua_Container_setZIndex(lua_State* state);
 int lua_Container_static_ANIMATE_OPACITY(lua_State* state);

+ 110 - 66
gameplay/src/lua/lua_Control.cpp

@@ -30,8 +30,6 @@ void luaRegister_Control()
         {"createAnimationFromBy", lua_Control_createAnimationFromBy},
         {"createAnimationFromTo", lua_Control_createAnimationFromTo},
         {"destroyAnimation", lua_Control_destroyAnimation},
-        {"disable", lua_Control_disable},
-        {"enable", lua_Control_enable},
         {"getAlignment", lua_Control_getAlignment},
         {"getAnimation", lua_Control_getAnimation},
         {"getAnimationPropertyComponentCount", lua_Control_getAnimationPropertyComponentCount},
@@ -72,6 +70,7 @@ void luaRegister_Control()
         {"getZIndex", lua_Control_getZIndex},
         {"isContainer", lua_Control_isContainer},
         {"isEnabled", lua_Control_isEnabled},
+        {"isVisible", lua_Control_isVisible},
         {"release", lua_Control_release},
         {"removeListener", lua_Control_removeListener},
         {"removeScriptCallback", lua_Control_removeScriptCallback},
@@ -84,6 +83,7 @@ void luaRegister_Control()
         {"setConsumeInputEvents", lua_Control_setConsumeInputEvents},
         {"setCursorColor", lua_Control_setCursorColor},
         {"setCursorRegion", lua_Control_setCursorRegion},
+        {"setEnabled", lua_Control_setEnabled},
         {"setFocusIndex", lua_Control_setFocusIndex},
         {"setFont", lua_Control_setFont},
         {"setFontSize", lua_Control_setFontSize},
@@ -102,6 +102,7 @@ void luaRegister_Control()
         {"setTextAlignment", lua_Control_setTextAlignment},
         {"setTextColor", lua_Control_setTextColor},
         {"setTextRightToLeft", lua_Control_setTextRightToLeft},
+        {"setVisible", lua_Control_setVisible},
         {"setWidth", lua_Control_setWidth},
         {"setZIndex", lua_Control_setZIndex},
         {NULL, NULL}
@@ -674,70 +675,6 @@ int lua_Control_destroyAnimation(lua_State* state)
     return 0;
 }
 
-int lua_Control_disable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Control* instance = getInstance(state);
-                instance->disable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Control_disable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
-int lua_Control_enable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Control* instance = getInstance(state);
-                instance->enable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Control_enable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
 int lua_Control_getAlignment(lua_State* state)
 {
     // Get the number of parameters.
@@ -2615,6 +2552,41 @@ int lua_Control_isEnabled(lua_State* state)
     return 0;
 }
 
+int lua_Control_isVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 1:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA))
+            {
+                Control* instance = getInstance(state);
+                bool result = instance->isVisible();
+
+                // Push the return value onto the stack.
+                lua_pushboolean(state, result);
+
+                return 1;
+            }
+
+            lua_pushstring(state, "lua_Control_isVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 1).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Control_release(lua_State* state)
 {
     // Get the number of parameters.
@@ -3167,6 +3139,42 @@ int lua_Control_setCursorRegion(lua_State* state)
     return 0;
 }
 
+int lua_Control_setEnabled(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Control* instance = getInstance(state);
+                instance->setEnabled(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Control_setEnabled - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Control_setFocusIndex(lua_State* state)
 {
     // Get the number of parameters.
@@ -4161,6 +4169,42 @@ int lua_Control_setTextRightToLeft(lua_State* state)
     return 0;
 }
 
+int lua_Control_setVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Control* instance = getInstance(state);
+                instance->setVisible(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Control_setVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Control_setWidth(lua_State* state)
 {
     // Get the number of parameters.

+ 3 - 2
gameplay/src/lua/lua_Control.h

@@ -13,8 +13,6 @@ int lua_Control_createAnimation(lua_State* state);
 int lua_Control_createAnimationFromBy(lua_State* state);
 int lua_Control_createAnimationFromTo(lua_State* state);
 int lua_Control_destroyAnimation(lua_State* state);
-int lua_Control_disable(lua_State* state);
-int lua_Control_enable(lua_State* state);
 int lua_Control_getAlignment(lua_State* state);
 int lua_Control_getAnimation(lua_State* state);
 int lua_Control_getAnimationPropertyComponentCount(lua_State* state);
@@ -55,6 +53,7 @@ int lua_Control_getY(lua_State* state);
 int lua_Control_getZIndex(lua_State* state);
 int lua_Control_isContainer(lua_State* state);
 int lua_Control_isEnabled(lua_State* state);
+int lua_Control_isVisible(lua_State* state);
 int lua_Control_release(lua_State* state);
 int lua_Control_removeListener(lua_State* state);
 int lua_Control_removeScriptCallback(lua_State* state);
@@ -67,6 +66,7 @@ int lua_Control_setBounds(lua_State* state);
 int lua_Control_setConsumeInputEvents(lua_State* state);
 int lua_Control_setCursorColor(lua_State* state);
 int lua_Control_setCursorRegion(lua_State* state);
+int lua_Control_setEnabled(lua_State* state);
 int lua_Control_setFocusIndex(lua_State* state);
 int lua_Control_setFont(lua_State* state);
 int lua_Control_setFontSize(lua_State* state);
@@ -85,6 +85,7 @@ int lua_Control_setStyle(lua_State* state);
 int lua_Control_setTextAlignment(lua_State* state);
 int lua_Control_setTextColor(lua_State* state);
 int lua_Control_setTextRightToLeft(lua_State* state);
+int lua_Control_setVisible(lua_State* state);
 int lua_Control_setWidth(lua_State* state);
 int lua_Control_setZIndex(lua_State* state);
 int lua_Control_static_ANIMATE_OPACITY(lua_State* state);

+ 110 - 66
gameplay/src/lua/lua_Form.cpp

@@ -48,9 +48,7 @@ void luaRegister_Form()
         {"createAnimationFromBy", lua_Form_createAnimationFromBy},
         {"createAnimationFromTo", lua_Form_createAnimationFromTo},
         {"destroyAnimation", lua_Form_destroyAnimation},
-        {"disable", lua_Form_disable},
         {"draw", lua_Form_draw},
-        {"enable", lua_Form_enable},
         {"getAlignment", lua_Form_getAlignment},
         {"getAnimation", lua_Form_getAnimation},
         {"getAnimationPropertyComponentCount", lua_Form_getAnimationPropertyComponentCount},
@@ -98,6 +96,7 @@ void luaRegister_Form()
         {"isEnabled", lua_Form_isEnabled},
         {"isScrollBarsAutoHide", lua_Form_isScrollBarsAutoHide},
         {"isScrolling", lua_Form_isScrolling},
+        {"isVisible", lua_Form_isVisible},
         {"release", lua_Form_release},
         {"removeControl", lua_Form_removeControl},
         {"removeListener", lua_Form_removeListener},
@@ -111,6 +110,7 @@ void luaRegister_Form()
         {"setConsumeInputEvents", lua_Form_setConsumeInputEvents},
         {"setCursorColor", lua_Form_setCursorColor},
         {"setCursorRegion", lua_Form_setCursorRegion},
+        {"setEnabled", lua_Form_setEnabled},
         {"setFocusIndex", lua_Form_setFocusIndex},
         {"setFont", lua_Form_setFont},
         {"setFontSize", lua_Form_setFontSize},
@@ -132,6 +132,7 @@ void luaRegister_Form()
         {"setTextAlignment", lua_Form_setTextAlignment},
         {"setTextColor", lua_Form_setTextColor},
         {"setTextRightToLeft", lua_Form_setTextRightToLeft},
+        {"setVisible", lua_Form_setVisible},
         {"setWidth", lua_Form_setWidth},
         {"setZIndex", lua_Form_setZIndex},
         {"update", lua_Form_update},
@@ -753,38 +754,6 @@ int lua_Form_destroyAnimation(lua_State* state)
     return 0;
 }
 
-int lua_Form_disable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Form* instance = getInstance(state);
-                instance->disable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Form_disable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
 int lua_Form_draw(lua_State* state)
 {
     // Get the number of parameters.
@@ -817,38 +786,6 @@ int lua_Form_draw(lua_State* state)
     return 0;
 }
 
-int lua_Form_enable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Form* instance = getInstance(state);
-                instance->enable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Form_enable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
 int lua_Form_getAlignment(lua_State* state)
 {
     // Get the number of parameters.
@@ -3043,6 +2980,41 @@ int lua_Form_isScrolling(lua_State* state)
     return 0;
 }
 
+int lua_Form_isVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 1:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA))
+            {
+                Form* instance = getInstance(state);
+                bool result = instance->isVisible();
+
+                // Push the return value onto the stack.
+                lua_pushboolean(state, result);
+
+                return 1;
+            }
+
+            lua_pushstring(state, "lua_Form_isVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 1).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Form_release(lua_State* state)
 {
     // Get the number of parameters.
@@ -3667,6 +3639,42 @@ int lua_Form_setCursorRegion(lua_State* state)
     return 0;
 }
 
+int lua_Form_setEnabled(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Form* instance = getInstance(state);
+                instance->setEnabled(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Form_setEnabled - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Form_setFocusIndex(lua_State* state)
 {
     // Get the number of parameters.
@@ -4775,6 +4783,42 @@ int lua_Form_setTextRightToLeft(lua_State* state)
     return 0;
 }
 
+int lua_Form_setVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Form* instance = getInstance(state);
+                instance->setVisible(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Form_setVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Form_setWidth(lua_State* state)
 {
     // Get the number of parameters.

+ 3 - 2
gameplay/src/lua/lua_Form.h

@@ -14,9 +14,7 @@ int lua_Form_createAnimation(lua_State* state);
 int lua_Form_createAnimationFromBy(lua_State* state);
 int lua_Form_createAnimationFromTo(lua_State* state);
 int lua_Form_destroyAnimation(lua_State* state);
-int lua_Form_disable(lua_State* state);
 int lua_Form_draw(lua_State* state);
-int lua_Form_enable(lua_State* state);
 int lua_Form_getAlignment(lua_State* state);
 int lua_Form_getAnimation(lua_State* state);
 int lua_Form_getAnimationPropertyComponentCount(lua_State* state);
@@ -64,6 +62,7 @@ int lua_Form_isContainer(lua_State* state);
 int lua_Form_isEnabled(lua_State* state);
 int lua_Form_isScrollBarsAutoHide(lua_State* state);
 int lua_Form_isScrolling(lua_State* state);
+int lua_Form_isVisible(lua_State* state);
 int lua_Form_release(lua_State* state);
 int lua_Form_removeControl(lua_State* state);
 int lua_Form_removeListener(lua_State* state);
@@ -77,6 +76,7 @@ int lua_Form_setBounds(lua_State* state);
 int lua_Form_setConsumeInputEvents(lua_State* state);
 int lua_Form_setCursorColor(lua_State* state);
 int lua_Form_setCursorRegion(lua_State* state);
+int lua_Form_setEnabled(lua_State* state);
 int lua_Form_setFocusIndex(lua_State* state);
 int lua_Form_setFont(lua_State* state);
 int lua_Form_setFontSize(lua_State* state);
@@ -98,6 +98,7 @@ int lua_Form_setStyle(lua_State* state);
 int lua_Form_setTextAlignment(lua_State* state);
 int lua_Form_setTextColor(lua_State* state);
 int lua_Form_setTextRightToLeft(lua_State* state);
+int lua_Form_setVisible(lua_State* state);
 int lua_Form_setWidth(lua_State* state);
 int lua_Form_setZIndex(lua_State* state);
 int lua_Form_static_ANIMATE_OPACITY(lua_State* state);

+ 110 - 66
gameplay/src/lua/lua_Joystick.cpp

@@ -31,8 +31,6 @@ void luaRegister_Joystick()
         {"createAnimationFromBy", lua_Joystick_createAnimationFromBy},
         {"createAnimationFromTo", lua_Joystick_createAnimationFromTo},
         {"destroyAnimation", lua_Joystick_destroyAnimation},
-        {"disable", lua_Joystick_disable},
-        {"enable", lua_Joystick_enable},
         {"getAlignment", lua_Joystick_getAlignment},
         {"getAnimation", lua_Joystick_getAnimation},
         {"getAnimationPropertyComponentCount", lua_Joystick_getAnimationPropertyComponentCount},
@@ -77,6 +75,7 @@ void luaRegister_Joystick()
         {"isContainer", lua_Joystick_isContainer},
         {"isEnabled", lua_Joystick_isEnabled},
         {"isRelative", lua_Joystick_isRelative},
+        {"isVisible", lua_Joystick_isVisible},
         {"release", lua_Joystick_release},
         {"removeListener", lua_Joystick_removeListener},
         {"removeScriptCallback", lua_Joystick_removeScriptCallback},
@@ -89,6 +88,7 @@ void luaRegister_Joystick()
         {"setConsumeInputEvents", lua_Joystick_setConsumeInputEvents},
         {"setCursorColor", lua_Joystick_setCursorColor},
         {"setCursorRegion", lua_Joystick_setCursorRegion},
+        {"setEnabled", lua_Joystick_setEnabled},
         {"setFocusIndex", lua_Joystick_setFocusIndex},
         {"setFont", lua_Joystick_setFont},
         {"setFontSize", lua_Joystick_setFontSize},
@@ -110,6 +110,7 @@ void luaRegister_Joystick()
         {"setTextAlignment", lua_Joystick_setTextAlignment},
         {"setTextColor", lua_Joystick_setTextColor},
         {"setTextRightToLeft", lua_Joystick_setTextRightToLeft},
+        {"setVisible", lua_Joystick_setVisible},
         {"setWidth", lua_Joystick_setWidth},
         {"setZIndex", lua_Joystick_setZIndex},
         {NULL, NULL}
@@ -683,70 +684,6 @@ int lua_Joystick_destroyAnimation(lua_State* state)
     return 0;
 }
 
-int lua_Joystick_disable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Joystick* instance = getInstance(state);
-                instance->disable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Joystick_disable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
-int lua_Joystick_enable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Joystick* instance = getInstance(state);
-                instance->enable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Joystick_enable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
 int lua_Joystick_getAlignment(lua_State* state)
 {
     // Get the number of parameters.
@@ -2791,6 +2728,41 @@ int lua_Joystick_isRelative(lua_State* state)
     return 0;
 }
 
+int lua_Joystick_isVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 1:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA))
+            {
+                Joystick* instance = getInstance(state);
+                bool result = instance->isVisible();
+
+                // Push the return value onto the stack.
+                lua_pushboolean(state, result);
+
+                return 1;
+            }
+
+            lua_pushstring(state, "lua_Joystick_isVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 1).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Joystick_release(lua_State* state)
 {
     // Get the number of parameters.
@@ -3343,6 +3315,42 @@ int lua_Joystick_setCursorRegion(lua_State* state)
     return 0;
 }
 
+int lua_Joystick_setEnabled(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Joystick* instance = getInstance(state);
+                instance->setEnabled(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Joystick_setEnabled - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Joystick_setFocusIndex(lua_State* state)
 {
     // Get the number of parameters.
@@ -4457,6 +4465,42 @@ int lua_Joystick_setTextRightToLeft(lua_State* state)
     return 0;
 }
 
+int lua_Joystick_setVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Joystick* instance = getInstance(state);
+                instance->setVisible(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Joystick_setVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Joystick_setWidth(lua_State* state)
 {
     // Get the number of parameters.

+ 3 - 2
gameplay/src/lua/lua_Joystick.h

@@ -13,8 +13,6 @@ int lua_Joystick_createAnimation(lua_State* state);
 int lua_Joystick_createAnimationFromBy(lua_State* state);
 int lua_Joystick_createAnimationFromTo(lua_State* state);
 int lua_Joystick_destroyAnimation(lua_State* state);
-int lua_Joystick_disable(lua_State* state);
-int lua_Joystick_enable(lua_State* state);
 int lua_Joystick_getAlignment(lua_State* state);
 int lua_Joystick_getAnimation(lua_State* state);
 int lua_Joystick_getAnimationPropertyComponentCount(lua_State* state);
@@ -59,6 +57,7 @@ int lua_Joystick_getZIndex(lua_State* state);
 int lua_Joystick_isContainer(lua_State* state);
 int lua_Joystick_isEnabled(lua_State* state);
 int lua_Joystick_isRelative(lua_State* state);
+int lua_Joystick_isVisible(lua_State* state);
 int lua_Joystick_release(lua_State* state);
 int lua_Joystick_removeListener(lua_State* state);
 int lua_Joystick_removeScriptCallback(lua_State* state);
@@ -71,6 +70,7 @@ int lua_Joystick_setBounds(lua_State* state);
 int lua_Joystick_setConsumeInputEvents(lua_State* state);
 int lua_Joystick_setCursorColor(lua_State* state);
 int lua_Joystick_setCursorRegion(lua_State* state);
+int lua_Joystick_setEnabled(lua_State* state);
 int lua_Joystick_setFocusIndex(lua_State* state);
 int lua_Joystick_setFont(lua_State* state);
 int lua_Joystick_setFontSize(lua_State* state);
@@ -92,6 +92,7 @@ int lua_Joystick_setStyle(lua_State* state);
 int lua_Joystick_setTextAlignment(lua_State* state);
 int lua_Joystick_setTextColor(lua_State* state);
 int lua_Joystick_setTextRightToLeft(lua_State* state);
+int lua_Joystick_setVisible(lua_State* state);
 int lua_Joystick_setWidth(lua_State* state);
 int lua_Joystick_setZIndex(lua_State* state);
 int lua_Joystick_static_ANIMATE_OPACITY(lua_State* state);

+ 110 - 66
gameplay/src/lua/lua_Label.cpp

@@ -31,8 +31,6 @@ void luaRegister_Label()
         {"createAnimationFromBy", lua_Label_createAnimationFromBy},
         {"createAnimationFromTo", lua_Label_createAnimationFromTo},
         {"destroyAnimation", lua_Label_destroyAnimation},
-        {"disable", lua_Label_disable},
-        {"enable", lua_Label_enable},
         {"getAlignment", lua_Label_getAlignment},
         {"getAnimation", lua_Label_getAnimation},
         {"getAnimationPropertyComponentCount", lua_Label_getAnimationPropertyComponentCount},
@@ -74,6 +72,7 @@ void luaRegister_Label()
         {"getZIndex", lua_Label_getZIndex},
         {"isContainer", lua_Label_isContainer},
         {"isEnabled", lua_Label_isEnabled},
+        {"isVisible", lua_Label_isVisible},
         {"release", lua_Label_release},
         {"removeListener", lua_Label_removeListener},
         {"removeScriptCallback", lua_Label_removeScriptCallback},
@@ -86,6 +85,7 @@ void luaRegister_Label()
         {"setConsumeInputEvents", lua_Label_setConsumeInputEvents},
         {"setCursorColor", lua_Label_setCursorColor},
         {"setCursorRegion", lua_Label_setCursorRegion},
+        {"setEnabled", lua_Label_setEnabled},
         {"setFocusIndex", lua_Label_setFocusIndex},
         {"setFont", lua_Label_setFont},
         {"setFontSize", lua_Label_setFontSize},
@@ -105,6 +105,7 @@ void luaRegister_Label()
         {"setTextAlignment", lua_Label_setTextAlignment},
         {"setTextColor", lua_Label_setTextColor},
         {"setTextRightToLeft", lua_Label_setTextRightToLeft},
+        {"setVisible", lua_Label_setVisible},
         {"setWidth", lua_Label_setWidth},
         {"setZIndex", lua_Label_setZIndex},
         {NULL, NULL}
@@ -678,70 +679,6 @@ int lua_Label_destroyAnimation(lua_State* state)
     return 0;
 }
 
-int lua_Label_disable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Label* instance = getInstance(state);
-                instance->disable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Label_disable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
-int lua_Label_enable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Label* instance = getInstance(state);
-                instance->enable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Label_enable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
 int lua_Label_getAlignment(lua_State* state)
 {
     // Get the number of parameters.
@@ -2654,6 +2591,41 @@ int lua_Label_isEnabled(lua_State* state)
     return 0;
 }
 
+int lua_Label_isVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 1:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA))
+            {
+                Label* instance = getInstance(state);
+                bool result = instance->isVisible();
+
+                // Push the return value onto the stack.
+                lua_pushboolean(state, result);
+
+                return 1;
+            }
+
+            lua_pushstring(state, "lua_Label_isVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 1).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Label_release(lua_State* state)
 {
     // Get the number of parameters.
@@ -3206,6 +3178,42 @@ int lua_Label_setCursorRegion(lua_State* state)
     return 0;
 }
 
+int lua_Label_setEnabled(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Label* instance = getInstance(state);
+                instance->setEnabled(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Label_setEnabled - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Label_setFocusIndex(lua_State* state)
 {
     // Get the number of parameters.
@@ -4236,6 +4244,42 @@ int lua_Label_setTextRightToLeft(lua_State* state)
     return 0;
 }
 
+int lua_Label_setVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Label* instance = getInstance(state);
+                instance->setVisible(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Label_setVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Label_setWidth(lua_State* state)
 {
     // Get the number of parameters.

+ 3 - 2
gameplay/src/lua/lua_Label.h

@@ -13,8 +13,6 @@ int lua_Label_createAnimation(lua_State* state);
 int lua_Label_createAnimationFromBy(lua_State* state);
 int lua_Label_createAnimationFromTo(lua_State* state);
 int lua_Label_destroyAnimation(lua_State* state);
-int lua_Label_disable(lua_State* state);
-int lua_Label_enable(lua_State* state);
 int lua_Label_getAlignment(lua_State* state);
 int lua_Label_getAnimation(lua_State* state);
 int lua_Label_getAnimationPropertyComponentCount(lua_State* state);
@@ -56,6 +54,7 @@ int lua_Label_getY(lua_State* state);
 int lua_Label_getZIndex(lua_State* state);
 int lua_Label_isContainer(lua_State* state);
 int lua_Label_isEnabled(lua_State* state);
+int lua_Label_isVisible(lua_State* state);
 int lua_Label_release(lua_State* state);
 int lua_Label_removeListener(lua_State* state);
 int lua_Label_removeScriptCallback(lua_State* state);
@@ -68,6 +67,7 @@ int lua_Label_setBounds(lua_State* state);
 int lua_Label_setConsumeInputEvents(lua_State* state);
 int lua_Label_setCursorColor(lua_State* state);
 int lua_Label_setCursorRegion(lua_State* state);
+int lua_Label_setEnabled(lua_State* state);
 int lua_Label_setFocusIndex(lua_State* state);
 int lua_Label_setFont(lua_State* state);
 int lua_Label_setFontSize(lua_State* state);
@@ -87,6 +87,7 @@ int lua_Label_setText(lua_State* state);
 int lua_Label_setTextAlignment(lua_State* state);
 int lua_Label_setTextColor(lua_State* state);
 int lua_Label_setTextRightToLeft(lua_State* state);
+int lua_Label_setVisible(lua_State* state);
 int lua_Label_setWidth(lua_State* state);
 int lua_Label_setZIndex(lua_State* state);
 int lua_Label_static_ANIMATE_OPACITY(lua_State* state);

+ 110 - 66
gameplay/src/lua/lua_RadioButton.cpp

@@ -33,8 +33,6 @@ void luaRegister_RadioButton()
         {"createAnimationFromBy", lua_RadioButton_createAnimationFromBy},
         {"createAnimationFromTo", lua_RadioButton_createAnimationFromTo},
         {"destroyAnimation", lua_RadioButton_destroyAnimation},
-        {"disable", lua_RadioButton_disable},
-        {"enable", lua_RadioButton_enable},
         {"getAlignment", lua_RadioButton_getAlignment},
         {"getAnimation", lua_RadioButton_getAnimation},
         {"getAnimationPropertyComponentCount", lua_RadioButton_getAnimationPropertyComponentCount},
@@ -79,6 +77,7 @@ void luaRegister_RadioButton()
         {"isContainer", lua_RadioButton_isContainer},
         {"isEnabled", lua_RadioButton_isEnabled},
         {"isSelected", lua_RadioButton_isSelected},
+        {"isVisible", lua_RadioButton_isVisible},
         {"release", lua_RadioButton_release},
         {"removeListener", lua_RadioButton_removeListener},
         {"removeScriptCallback", lua_RadioButton_removeScriptCallback},
@@ -91,6 +90,7 @@ void luaRegister_RadioButton()
         {"setConsumeInputEvents", lua_RadioButton_setConsumeInputEvents},
         {"setCursorColor", lua_RadioButton_setCursorColor},
         {"setCursorRegion", lua_RadioButton_setCursorRegion},
+        {"setEnabled", lua_RadioButton_setEnabled},
         {"setFocusIndex", lua_RadioButton_setFocusIndex},
         {"setFont", lua_RadioButton_setFont},
         {"setFontSize", lua_RadioButton_setFontSize},
@@ -113,6 +113,7 @@ void luaRegister_RadioButton()
         {"setTextAlignment", lua_RadioButton_setTextAlignment},
         {"setTextColor", lua_RadioButton_setTextColor},
         {"setTextRightToLeft", lua_RadioButton_setTextRightToLeft},
+        {"setVisible", lua_RadioButton_setVisible},
         {"setWidth", lua_RadioButton_setWidth},
         {"setZIndex", lua_RadioButton_setZIndex},
         {NULL, NULL}
@@ -686,70 +687,6 @@ int lua_RadioButton_destroyAnimation(lua_State* state)
     return 0;
 }
 
-int lua_RadioButton_disable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                RadioButton* instance = getInstance(state);
-                instance->disable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_RadioButton_disable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
-int lua_RadioButton_enable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                RadioButton* instance = getInstance(state);
-                instance->enable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_RadioButton_enable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
 int lua_RadioButton_getAlignment(lua_State* state)
 {
     // Get the number of parameters.
@@ -2776,6 +2713,41 @@ int lua_RadioButton_isSelected(lua_State* state)
     return 0;
 }
 
+int lua_RadioButton_isVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 1:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA))
+            {
+                RadioButton* instance = getInstance(state);
+                bool result = instance->isVisible();
+
+                // Push the return value onto the stack.
+                lua_pushboolean(state, result);
+
+                return 1;
+            }
+
+            lua_pushstring(state, "lua_RadioButton_isVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 1).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_RadioButton_release(lua_State* state)
 {
     // Get the number of parameters.
@@ -3328,6 +3300,42 @@ int lua_RadioButton_setCursorRegion(lua_State* state)
     return 0;
 }
 
+int lua_RadioButton_setEnabled(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                RadioButton* instance = getInstance(state);
+                instance->setEnabled(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_RadioButton_setEnabled - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_RadioButton_setFocusIndex(lua_State* state)
 {
     // Get the number of parameters.
@@ -4470,6 +4478,42 @@ int lua_RadioButton_setTextRightToLeft(lua_State* state)
     return 0;
 }
 
+int lua_RadioButton_setVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                RadioButton* instance = getInstance(state);
+                instance->setVisible(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_RadioButton_setVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_RadioButton_setWidth(lua_State* state)
 {
     // Get the number of parameters.

+ 3 - 2
gameplay/src/lua/lua_RadioButton.h

@@ -13,8 +13,6 @@ int lua_RadioButton_createAnimation(lua_State* state);
 int lua_RadioButton_createAnimationFromBy(lua_State* state);
 int lua_RadioButton_createAnimationFromTo(lua_State* state);
 int lua_RadioButton_destroyAnimation(lua_State* state);
-int lua_RadioButton_disable(lua_State* state);
-int lua_RadioButton_enable(lua_State* state);
 int lua_RadioButton_getAlignment(lua_State* state);
 int lua_RadioButton_getAnimation(lua_State* state);
 int lua_RadioButton_getAnimationPropertyComponentCount(lua_State* state);
@@ -59,6 +57,7 @@ int lua_RadioButton_getZIndex(lua_State* state);
 int lua_RadioButton_isContainer(lua_State* state);
 int lua_RadioButton_isEnabled(lua_State* state);
 int lua_RadioButton_isSelected(lua_State* state);
+int lua_RadioButton_isVisible(lua_State* state);
 int lua_RadioButton_release(lua_State* state);
 int lua_RadioButton_removeListener(lua_State* state);
 int lua_RadioButton_removeScriptCallback(lua_State* state);
@@ -71,6 +70,7 @@ int lua_RadioButton_setBounds(lua_State* state);
 int lua_RadioButton_setConsumeInputEvents(lua_State* state);
 int lua_RadioButton_setCursorColor(lua_State* state);
 int lua_RadioButton_setCursorRegion(lua_State* state);
+int lua_RadioButton_setEnabled(lua_State* state);
 int lua_RadioButton_setFocusIndex(lua_State* state);
 int lua_RadioButton_setFont(lua_State* state);
 int lua_RadioButton_setFontSize(lua_State* state);
@@ -93,6 +93,7 @@ int lua_RadioButton_setText(lua_State* state);
 int lua_RadioButton_setTextAlignment(lua_State* state);
 int lua_RadioButton_setTextColor(lua_State* state);
 int lua_RadioButton_setTextRightToLeft(lua_State* state);
+int lua_RadioButton_setVisible(lua_State* state);
 int lua_RadioButton_setWidth(lua_State* state);
 int lua_RadioButton_setZIndex(lua_State* state);
 int lua_RadioButton_static_ANIMATE_OPACITY(lua_State* state);

+ 110 - 66
gameplay/src/lua/lua_Slider.cpp

@@ -32,8 +32,6 @@ void luaRegister_Slider()
         {"createAnimationFromBy", lua_Slider_createAnimationFromBy},
         {"createAnimationFromTo", lua_Slider_createAnimationFromTo},
         {"destroyAnimation", lua_Slider_destroyAnimation},
-        {"disable", lua_Slider_disable},
-        {"enable", lua_Slider_enable},
         {"getAlignment", lua_Slider_getAlignment},
         {"getAnimation", lua_Slider_getAnimation},
         {"getAnimationPropertyComponentCount", lua_Slider_getAnimationPropertyComponentCount},
@@ -79,6 +77,7 @@ void luaRegister_Slider()
         {"getZIndex", lua_Slider_getZIndex},
         {"isContainer", lua_Slider_isContainer},
         {"isEnabled", lua_Slider_isEnabled},
+        {"isVisible", lua_Slider_isVisible},
         {"release", lua_Slider_release},
         {"removeListener", lua_Slider_removeListener},
         {"removeScriptCallback", lua_Slider_removeScriptCallback},
@@ -91,6 +90,7 @@ void luaRegister_Slider()
         {"setConsumeInputEvents", lua_Slider_setConsumeInputEvents},
         {"setCursorColor", lua_Slider_setCursorColor},
         {"setCursorRegion", lua_Slider_setCursorRegion},
+        {"setEnabled", lua_Slider_setEnabled},
         {"setFocusIndex", lua_Slider_setFocusIndex},
         {"setFont", lua_Slider_setFont},
         {"setFontSize", lua_Slider_setFontSize},
@@ -114,6 +114,7 @@ void luaRegister_Slider()
         {"setTextColor", lua_Slider_setTextColor},
         {"setTextRightToLeft", lua_Slider_setTextRightToLeft},
         {"setValue", lua_Slider_setValue},
+        {"setVisible", lua_Slider_setVisible},
         {"setWidth", lua_Slider_setWidth},
         {"setZIndex", lua_Slider_setZIndex},
         {NULL, NULL}
@@ -687,70 +688,6 @@ int lua_Slider_destroyAnimation(lua_State* state)
     return 0;
 }
 
-int lua_Slider_disable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Slider* instance = getInstance(state);
-                instance->disable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Slider_disable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
-int lua_Slider_enable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                Slider* instance = getInstance(state);
-                instance->enable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_Slider_enable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
 int lua_Slider_getAlignment(lua_State* state)
 {
     // Get the number of parameters.
@@ -2803,6 +2740,41 @@ int lua_Slider_isEnabled(lua_State* state)
     return 0;
 }
 
+int lua_Slider_isVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 1:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA))
+            {
+                Slider* instance = getInstance(state);
+                bool result = instance->isVisible();
+
+                // Push the return value onto the stack.
+                lua_pushboolean(state, result);
+
+                return 1;
+            }
+
+            lua_pushstring(state, "lua_Slider_isVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 1).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Slider_release(lua_State* state)
 {
     // Get the number of parameters.
@@ -3355,6 +3327,42 @@ int lua_Slider_setCursorRegion(lua_State* state)
     return 0;
 }
 
+int lua_Slider_setEnabled(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Slider* instance = getInstance(state);
+                instance->setEnabled(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Slider_setEnabled - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Slider_setFocusIndex(lua_State* state)
 {
     // Get the number of parameters.
@@ -4529,6 +4537,42 @@ int lua_Slider_setValue(lua_State* state)
     return 0;
 }
 
+int lua_Slider_setVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                Slider* instance = getInstance(state);
+                instance->setVisible(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_Slider_setVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_Slider_setWidth(lua_State* state)
 {
     // Get the number of parameters.

+ 3 - 2
gameplay/src/lua/lua_Slider.h

@@ -13,8 +13,6 @@ int lua_Slider_createAnimation(lua_State* state);
 int lua_Slider_createAnimationFromBy(lua_State* state);
 int lua_Slider_createAnimationFromTo(lua_State* state);
 int lua_Slider_destroyAnimation(lua_State* state);
-int lua_Slider_disable(lua_State* state);
-int lua_Slider_enable(lua_State* state);
 int lua_Slider_getAlignment(lua_State* state);
 int lua_Slider_getAnimation(lua_State* state);
 int lua_Slider_getAnimationPropertyComponentCount(lua_State* state);
@@ -60,6 +58,7 @@ int lua_Slider_getY(lua_State* state);
 int lua_Slider_getZIndex(lua_State* state);
 int lua_Slider_isContainer(lua_State* state);
 int lua_Slider_isEnabled(lua_State* state);
+int lua_Slider_isVisible(lua_State* state);
 int lua_Slider_release(lua_State* state);
 int lua_Slider_removeListener(lua_State* state);
 int lua_Slider_removeScriptCallback(lua_State* state);
@@ -72,6 +71,7 @@ int lua_Slider_setBounds(lua_State* state);
 int lua_Slider_setConsumeInputEvents(lua_State* state);
 int lua_Slider_setCursorColor(lua_State* state);
 int lua_Slider_setCursorRegion(lua_State* state);
+int lua_Slider_setEnabled(lua_State* state);
 int lua_Slider_setFocusIndex(lua_State* state);
 int lua_Slider_setFont(lua_State* state);
 int lua_Slider_setFontSize(lua_State* state);
@@ -95,6 +95,7 @@ int lua_Slider_setTextAlignment(lua_State* state);
 int lua_Slider_setTextColor(lua_State* state);
 int lua_Slider_setTextRightToLeft(lua_State* state);
 int lua_Slider_setValue(lua_State* state);
+int lua_Slider_setVisible(lua_State* state);
 int lua_Slider_setWidth(lua_State* state);
 int lua_Slider_setZIndex(lua_State* state);
 int lua_Slider_static_ANIMATE_OPACITY(lua_State* state);

+ 110 - 66
gameplay/src/lua/lua_TextBox.cpp

@@ -32,8 +32,6 @@ void luaRegister_TextBox()
         {"createAnimationFromBy", lua_TextBox_createAnimationFromBy},
         {"createAnimationFromTo", lua_TextBox_createAnimationFromTo},
         {"destroyAnimation", lua_TextBox_destroyAnimation},
-        {"disable", lua_TextBox_disable},
-        {"enable", lua_TextBox_enable},
         {"getAlignment", lua_TextBox_getAlignment},
         {"getAnimation", lua_TextBox_getAnimation},
         {"getAnimationPropertyComponentCount", lua_TextBox_getAnimationPropertyComponentCount},
@@ -76,6 +74,7 @@ void luaRegister_TextBox()
         {"getZIndex", lua_TextBox_getZIndex},
         {"isContainer", lua_TextBox_isContainer},
         {"isEnabled", lua_TextBox_isEnabled},
+        {"isVisible", lua_TextBox_isVisible},
         {"release", lua_TextBox_release},
         {"removeListener", lua_TextBox_removeListener},
         {"removeScriptCallback", lua_TextBox_removeScriptCallback},
@@ -88,6 +87,7 @@ void luaRegister_TextBox()
         {"setConsumeInputEvents", lua_TextBox_setConsumeInputEvents},
         {"setCursorColor", lua_TextBox_setCursorColor},
         {"setCursorRegion", lua_TextBox_setCursorRegion},
+        {"setEnabled", lua_TextBox_setEnabled},
         {"setFocusIndex", lua_TextBox_setFocusIndex},
         {"setFont", lua_TextBox_setFont},
         {"setFontSize", lua_TextBox_setFontSize},
@@ -107,6 +107,7 @@ void luaRegister_TextBox()
         {"setTextAlignment", lua_TextBox_setTextAlignment},
         {"setTextColor", lua_TextBox_setTextColor},
         {"setTextRightToLeft", lua_TextBox_setTextRightToLeft},
+        {"setVisible", lua_TextBox_setVisible},
         {"setWidth", lua_TextBox_setWidth},
         {"setZIndex", lua_TextBox_setZIndex},
         {NULL, NULL}
@@ -680,70 +681,6 @@ int lua_TextBox_destroyAnimation(lua_State* state)
     return 0;
 }
 
-int lua_TextBox_disable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                TextBox* instance = getInstance(state);
-                instance->disable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_TextBox_disable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
-int lua_TextBox_enable(lua_State* state)
-{
-    // Get the number of parameters.
-    int paramCount = lua_gettop(state);
-
-    // Attempt to match the parameters to a valid binding.
-    switch (paramCount)
-    {
-        case 1:
-        {
-            if ((lua_type(state, 1) == LUA_TUSERDATA))
-            {
-                TextBox* instance = getInstance(state);
-                instance->enable();
-                
-                return 0;
-            }
-
-            lua_pushstring(state, "lua_TextBox_enable - Failed to match the given parameters to a valid function signature.");
-            lua_error(state);
-            break;
-        }
-        default:
-        {
-            lua_pushstring(state, "Invalid number of parameters (expected 1).");
-            lua_error(state);
-            break;
-        }
-    }
-    return 0;
-}
-
 int lua_TextBox_getAlignment(lua_State* state)
 {
     // Get the number of parameters.
@@ -2691,6 +2628,41 @@ int lua_TextBox_isEnabled(lua_State* state)
     return 0;
 }
 
+int lua_TextBox_isVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 1:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA))
+            {
+                TextBox* instance = getInstance(state);
+                bool result = instance->isVisible();
+
+                // Push the return value onto the stack.
+                lua_pushboolean(state, result);
+
+                return 1;
+            }
+
+            lua_pushstring(state, "lua_TextBox_isVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 1).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_TextBox_release(lua_State* state)
 {
     // Get the number of parameters.
@@ -3243,6 +3215,42 @@ int lua_TextBox_setCursorRegion(lua_State* state)
     return 0;
 }
 
+int lua_TextBox_setEnabled(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                TextBox* instance = getInstance(state);
+                instance->setEnabled(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_TextBox_setEnabled - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_TextBox_setFocusIndex(lua_State* state)
 {
     // Get the number of parameters.
@@ -4273,6 +4281,42 @@ int lua_TextBox_setTextRightToLeft(lua_State* state)
     return 0;
 }
 
+int lua_TextBox_setVisible(lua_State* state)
+{
+    // Get the number of parameters.
+    int paramCount = lua_gettop(state);
+
+    // Attempt to match the parameters to a valid binding.
+    switch (paramCount)
+    {
+        case 2:
+        {
+            if ((lua_type(state, 1) == LUA_TUSERDATA) &&
+                lua_type(state, 2) == LUA_TBOOLEAN)
+            {
+                // Get parameter 1 off the stack.
+                bool param1 = ScriptUtil::luaCheckBool(state, 2);
+
+                TextBox* instance = getInstance(state);
+                instance->setVisible(param1);
+                
+                return 0;
+            }
+
+            lua_pushstring(state, "lua_TextBox_setVisible - Failed to match the given parameters to a valid function signature.");
+            lua_error(state);
+            break;
+        }
+        default:
+        {
+            lua_pushstring(state, "Invalid number of parameters (expected 2).");
+            lua_error(state);
+            break;
+        }
+    }
+    return 0;
+}
+
 int lua_TextBox_setWidth(lua_State* state)
 {
     // Get the number of parameters.

+ 3 - 2
gameplay/src/lua/lua_TextBox.h

@@ -13,8 +13,6 @@ int lua_TextBox_createAnimation(lua_State* state);
 int lua_TextBox_createAnimationFromBy(lua_State* state);
 int lua_TextBox_createAnimationFromTo(lua_State* state);
 int lua_TextBox_destroyAnimation(lua_State* state);
-int lua_TextBox_disable(lua_State* state);
-int lua_TextBox_enable(lua_State* state);
 int lua_TextBox_getAlignment(lua_State* state);
 int lua_TextBox_getAnimation(lua_State* state);
 int lua_TextBox_getAnimationPropertyComponentCount(lua_State* state);
@@ -57,6 +55,7 @@ int lua_TextBox_getY(lua_State* state);
 int lua_TextBox_getZIndex(lua_State* state);
 int lua_TextBox_isContainer(lua_State* state);
 int lua_TextBox_isEnabled(lua_State* state);
+int lua_TextBox_isVisible(lua_State* state);
 int lua_TextBox_release(lua_State* state);
 int lua_TextBox_removeListener(lua_State* state);
 int lua_TextBox_removeScriptCallback(lua_State* state);
@@ -69,6 +68,7 @@ int lua_TextBox_setBounds(lua_State* state);
 int lua_TextBox_setConsumeInputEvents(lua_State* state);
 int lua_TextBox_setCursorColor(lua_State* state);
 int lua_TextBox_setCursorRegion(lua_State* state);
+int lua_TextBox_setEnabled(lua_State* state);
 int lua_TextBox_setFocusIndex(lua_State* state);
 int lua_TextBox_setFont(lua_State* state);
 int lua_TextBox_setFontSize(lua_State* state);
@@ -88,6 +88,7 @@ int lua_TextBox_setText(lua_State* state);
 int lua_TextBox_setTextAlignment(lua_State* state);
 int lua_TextBox_setTextColor(lua_State* state);
 int lua_TextBox_setTextRightToLeft(lua_State* state);
+int lua_TextBox_setVisible(lua_State* state);
 int lua_TextBox_setWidth(lua_State* state);
 int lua_TextBox_setZIndex(lua_State* state);
 int lua_TextBox_static_ANIMATE_OPACITY(lua_State* state);