Over 10 years of community discussion and knowledge are maintained here as a read-only archive.
var tabs=new JQuery("#theTabs");tabs.bind("easytabs:before",tabHooksHandler); //setup the handler for the tab eventprivate function tabHooksHandler(e:Dynamic,clicked:Dynamic,targetPanel:Dynamic,settings:Dynamic):Bool{ switch(targetPanel.selector){ case"#tab1": sendNotification ( StateMachine.ACTION, null, Main.ACTION_GOTO_FILE ); case"#tab2": sendNotification ( StateMachine.ACTION, null, Main.ACTION_GOTO_TREES ); case"#tab3": sendNotification ( StateMachine.ACTION, null, Main.ACTION_GOTO_MAP ); case"#tab4": sendNotification ( StateMachine.ACTION, null, Main.ACTION_GOTO_CALCULATOR ); } return true; //this lets EasyTabs complete the switch of tabs. If the StateMachine does a cancel, I would want this to return false. }