def onClicked(self, item, col): if col == 1: #editor view toggle app.getModule('layer_manager').toggleEditVisible( self.getNodeByItem(item)) elif col == 2: #lock toggle app.getModule('layer_manager').toggleLock(self.getNodeByItem(item)) elif col == 3: app.getModule('layer_manager').toggleSolo(self.getNodeByItem(item))
def run ( self, *args ): if len ( args ) >= 1: s = ' '.join ( args ) runtime = app.getModule ( 'moai' ) print ( '> ' + s ) runtime.runString ( s )
def editAsset(self, node): editor = app.getModule('candy.stylesheet_editor') if not editor: return alertMessage('Editor not load', 'Style Editor not found!') editor.setFocus() editor.openAsset(node)
def onItemChanged(self, item, col): layer = self.getNodeByItem(item) app.getModule('layer_manager').changeLayerName(layer, item.text(0))
def getSceneSelectionManager (): return app.getModule ('scene_editor').selectionManager