def Register(self, *args, **kwargs) -> Dict: super().Register(*args, **kwargs) Globals.oNotifications.RegisterNotification( uNotification="DEFINITIONPAGESLOADED", fNotifyFunction=self.LoadScriptPages, uDescription="Script Tools iTach2Keene") Globals.oNotifications.RegisterNotification( uNotification="STARTSCRIPTITACH2KEENE", fNotifyFunction=self.ShowPageItach2Keene, uDescription="Script Tools iTach2Keene") oScriptSettingPlugin = cScriptSettingPlugin() oScriptSettingPlugin.uScriptName = self.uObjectName oScriptSettingPlugin.uSettingName = "ORCA" oScriptSettingPlugin.uSettingPage = "$lvar(572)" oScriptSettingPlugin.uSettingTitle = "$lvar(SCRIPT_TOOLS_ITACH2KEENE_4)" oScriptSettingPlugin.aSettingJson = [ u'{"type": "buttons","title": "$lvar(SCRIPT_TOOLS_ITACH2KEENE_1)","desc": "$lvar(SCRIPT_TOOLS_ITACH2KEENE_2)","section": "ORCA","key": "button_notification","buttons":[{"title":"$lvar(SCRIPT_TOOLS_ITACH2KEENE_3)","id":"button_notification_STARTSCRIPTITACH2KEENE"}]}' ] Globals.oScripts.RegisterScriptInSetting( uScriptName=self.uObjectName, oScriptSettingPlugin=oScriptSettingPlugin) ''' If we press ESC on the iTach2Keene page, goto to the settings page ''' aActions: List[cAction] = Globals.oEvents.CreateSimpleActionList( aActions=[{ 'name': 'ESC Key Handler iTach2Keene', 'string': 'registernotification', 'filterpagename': 'Page_iTach2Keene', 'notification': 'on_key_ESC', 'notifyaction': 'gotosettingspage' }]) Globals.oEvents.ExecuteActionsNewQueue(aActions=aActions, oParentWidget=None) return {}
def Register(self, *args, **kwargs) -> None: super().Register(*args, **kwargs) Globals.oNotifications.RegisterNotification(uNotification="STARTSCRIPTWIKIDOC", fNotifyFunction=self.WikiDoc, uDescription="Script WikiDoc") oScriptSettingPlugin:cScriptSettingPlugin = cScriptSettingPlugin() oScriptSettingPlugin.uScriptName = self.uObjectName oScriptSettingPlugin.uSettingName = "ORCA" oScriptSettingPlugin.uSettingPage = "$lvar(572)" oScriptSettingPlugin.uSettingTitle = "$lvar(SCRIPT_TOOLS_WIKIDOC_4)" oScriptSettingPlugin.aSettingJson = [u'{"type": "buttons","title": "$lvar(SCRIPT_TOOLS_WIKIDOC_1)","desc": "$lvar(SCRIPT_TOOLS_WIKIDOC_2)","section": "ORCA","key": "button_notification","buttons":[{"title":"$lvar(SCRIPT_TOOLS_WIKIDOC_3)","id":"button_notification_STARTSCRIPTWIKIDOC"}]}'] Globals.oScripts.RegisterScriptInSetting(uScriptName=self.uObjectName,oScriptSettingPlugin=oScriptSettingPlugin)
def Register(self, *args, **kwargs): cToolsTemplate.Register(self,*args, **kwargs) Globals.oNotifications.RegisterNotification("STARTSCRIPTREPOSITORYMANAGER", fNotifyFunction=self.StartRepositoryManager, uDescription="Script Repository Manager") Globals.oNotifications.RegisterNotification("CREATEREPOSITORYVARARRAY", fNotifyFunction=self.CreateRepositoryVarArray, uDescription="Script Repository Manager") oScriptSettingPlugin = cScriptSettingPlugin() oScriptSettingPlugin.uScriptName = self.uScriptName oScriptSettingPlugin.uSettingName = "TOOLS" oScriptSettingPlugin.uSettingPage = "$lvar(699)" oScriptSettingPlugin.uSettingTitle = "$lvar(SCRIPT_TOOLS_REPMANAGER_4)" oScriptSettingPlugin.aSettingJson = [u'{"type": "buttons","title": "$lvar(SCRIPT_TOOLS_REPMANAGER_1)","desc": "$lvar(SCRIPT_TOOLS_REPMANAGER_2)","section": "ORCA","key": "button_notification","buttons":[{"title":"$lvar(SCRIPT_TOOLS_REPMANAGER_3)","id":"button_notification_STARTSCRIPTREPOSITORYMANAGER"}]}'] Globals.oScripts.RegisterScriptInSetting(uScriptName=self.uScriptName,oScriptSettingPlugin=oScriptSettingPlugin) self.LoadActions()
def Register(self, *args, **kwargs): cToolsTemplate.Register(self, *args, **kwargs) Globals.oNotifications.RegisterNotification( "DEFINITIONPAGESLOADED", fNotifyFunction=self.LoadScriptPages, uDescription="Script Tools GestureRecorder") Globals.oNotifications.RegisterNotification( "STARTSCRIPTGESTURERECORDER", fNotifyFunction=self.ShowPageGestureRecorder, uDescription="Script Tools GestureRecorder") oScriptSettingPlugin = cScriptSettingPlugin() oScriptSettingPlugin.uScriptName = self.uScriptName oScriptSettingPlugin.uSettingName = "ORCA" oScriptSettingPlugin.uSettingPage = "$lvar(572)" oScriptSettingPlugin.uSettingTitle = "$lvar(SCRIPT_TOOLS_GESTURERECORDER_4)" oScriptSettingPlugin.aSettingJson = [ u'{"type": "buttons","title": "$lvar(SCRIPT_TOOLS_GESTURERECORDER_1)","desc": "$lvar(SCRIPT_TOOLS_GESTURERECORDER_2)","section": "ORCA","key": "button_notification","buttons":[{"title":"$lvar(SCRIPT_TOOLS_GESTURERECORDER_3)","id":"button_notification_STARTSCRIPTGESTURERECORDER"}]}' ] Globals.oScripts.RegisterScriptInSetting( uScriptName=self.uScriptName, oScriptSettingPlugin=oScriptSettingPlugin) ''' If we press ESC on the Gestureboard page, goto to the settings page If we press the close button on the interface-settings page, goto to the settings page ''' oEvents = Globals.oEvents aActions = oEvents.CreateSimpleActionList([{ 'name': 'ESC Key Handler Gestureboard', 'string': 'registernotification', 'filterpagename': 'Page_GestureRecorder', 'notification': 'on_key_ESC', 'notifyaction': 'gotosettingspage' }, { 'name': 'Button Close Gestureboard Key Handler Settings', 'string': 'registernotification', 'filterpagename': 'Page_GestureRecorder', 'notification': 'closesetting_gesturerecorder', 'notifyaction': 'gotosettingspage' }]) oEvents.ExecuteActionsNewQueue(aActions=aActions, oParentWidget=None)
def Register(self, *args, **kwargs): cToolsTemplate.Register(self, *args, **kwargs) Globals.oNotifications.RegisterNotification( "STARTSCRIPTIRDBITACH", fNotifyFunction=self.ShowIRDB, uDescription="Script Tools IRDB iTach") oScriptSettingPlugin = cScriptSettingPlugin() oScriptSettingPlugin.uScriptName = self.uScriptName oScriptSettingPlugin.uSettingName = "ORCA" oScriptSettingPlugin.uSettingPage = "$lvar(572)" oScriptSettingPlugin.uSettingTitle = "$lvar(SCRIPT_TOOLS_IRDBITACH_4)" oScriptSettingPlugin.aSettingJson = [ u'{"type": "buttons","title": "$lvar(SCRIPT_TOOLS_IRDBITACH_1)","desc": "$lvar(SCRIPT_TOOLS_IRDBITACH_2)","section": "ORCA","key": "button_notification","buttons":[{"title":"$lvar(SCRIPT_TOOLS_IRDBITACH_3)","id":"button_notification_STARTSCRIPTIRDBITACH"}]}' ] Globals.oScripts.RegisterScriptInSetting( uScriptName=self.uScriptName, oScriptSettingPlugin=oScriptSettingPlugin)
def Register(self, *args, **kwargs) -> Dict: super().Register(*args, **kwargs) Globals.oNotifications.RegisterNotification( uNotification="DEFINITIONPAGESLOADED", fNotifyFunction=self.LoadScriptPages, uDescription="Script Tools Import Export") Globals.oNotifications.RegisterNotification( uNotification="STARTSCRIPTIMPORTEXPORT-IMPORT", fNotifyFunction=self.ShowPageImport, uDescription="Script Tools Import / Export") Globals.oNotifications.RegisterNotification( uNotification="STARTSCRIPTIMPORTEXPORT-EXPORT", fNotifyFunction=self.ShowPageExport, uDescription="Script Tools Import / Export") Globals.oNotifications.RegisterNotification( uNotification="STARTSCRIPTIMPORTEXPORT-DOIMPORT", fNotifyFunction=self.ImportOrcaFiles, uDescription="Script Tools Import / Export") Globals.oNotifications.RegisterNotification( uNotification="STARTSCRIPTIMPORTEXPORT-DOEXPORT", fNotifyFunction=self.ExportOrcaFiles, uDescription="Script Tools Import / Export") oScriptSettingPlugin = cScriptSettingPlugin() oScriptSettingPlugin.uScriptName = self.uObjectName oScriptSettingPlugin.uSettingName = "ORCA" oScriptSettingPlugin.uSettingPage = "$lvar(572)" oScriptSettingPlugin.uSettingTitle = "$lvar(SCRIPT_TOOLS_IMPORTEXPORT_4)" oScriptSettingPlugin.aSettingJson = [ u'{"type": "buttons","title": "$lvar(SCRIPT_TOOLS_IMPORTEXPORT_1)","desc": "$lvar(SCRIPT_TOOLS_IMPORTEXPORT_2)","section": "ORCA","key": "button_notification","buttons":[{"title":"$lvar(SCRIPT_TOOLS_IMPORTEXPORT_3)","id":"button_notification_STARTSCRIPTIMPORTEXPORT-EXPORT"}]}', u'{"type": "buttons","title": "$lvar(SCRIPT_TOOLS_IMPORTEXPORT_5)","desc": "$lvar(SCRIPT_TOOLS_IMPORTEXPORT_5)","section": "ORCA","key": "button_notification","buttons":[{"title":"$lvar(SCRIPT_TOOLS_IMPORTEXPORT_7)","id":"button_notification_STARTSCRIPTIMPORTEXPORT-IMPORT"}]}' ] Globals.oScripts.RegisterScriptInSetting( uScriptName=self.uObjectName, oScriptSettingPlugin=oScriptSettingPlugin) self.LoadActions() return {}