Refine ui bindings and JS constants

This commit is contained in:
pandamicro 2015-07-29 13:06:49 +08:00
parent f48dae09db
commit 3089ac302e
3 changed files with 15 additions and 1 deletions

View File

@ -340,6 +340,12 @@ ccui.TextField.EVENT_DELETE_BACKWARD = 3;
ccui.TextField.RENDERER_ZORDER = -1;
/*
* UIRadioButton
*/
ccui.RadioButton.EVENT_SELECTED = 0;
ccui.RadioButton.EVENT_UNSELECTED = 1;
ccui.RadioButtonGroup.EVENT_SELECT_CHANGED = 0;
/*
* UIMargin

View File

@ -183,6 +183,14 @@ void ScrollViewBar::updateLength(float length)
void ScrollViewBar::onEnter()
{
#if CC_ENABLE_SCRIPT_BINDING
if (_scriptType == kScriptTypeJavascript)
{
if (ScriptEngineManager::sendNodeEventToJSExtended(this, kNodeOnEnter))
return;
}
#endif
ProtectedNode::onEnter();
scheduleUpdate();
}

View File

@ -32,7 +32,7 @@ headers = %(cocosdir)s/cocos/ui/CocosGUI.h %(cocosdir)s/cocos/ui/UIScrollViewBar
# expression, it will be enclosed in "^$", like this: "^Menu*$".
classes = Helper Layout Widget Button CheckBox ImageView Text TextAtlas TextBMFont RichText RichElement RichElementText RichElementImage RichElementCustomNode LoadingBar Slider TextField UICCTextField ScrollView ScrollViewBar PageView ListView LayoutParameter LinearLayoutParameter RelativeLayoutParameter VideoPlayer HBox VBox RelativeBox Scale9Sprite EditBox$ LayoutComponent RadioButtonGroup RadioButton AbstractCheckButton
classes_need_extend = Layout Widget Button CheckBox ImageView Text TextAtlas TextBMFont RichText RichElement RichElementText RichElementImage RichElementCustomNode LoadingBar Slider TextField ScrollView ScrollViewBar PageView ListView VideoPlayer HBox VBox RelativeBox Scale9Sprite EditBox$ LayoutComponent
classes_need_extend = Layout Widget Button CheckBox ImageView Text TextAtlas TextBMFont RichText RichElement RichElementText RichElementImage RichElementCustomNode LoadingBar Slider TextField ScrollView ScrollViewBar PageView ListView VideoPlayer HBox VBox RelativeBox Scale9Sprite EditBox$ LayoutComponent RadioButtonGroup RadioButton AbstractCheckButton
# what should we skip? in the format ClassName::[function function]
# ClassName is a regular expression, but will be used like this: "^ClassName$" functions are also