Python ida_kernwin.action_handler_t() Examples
The following are 7
code examples of ida_kernwin.action_handler_t().
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example.
You may also want to check out all available functions/classes of the module
ida_kernwin
, or try the search function
.
Example #1
Source File: hooks.py From idapkg with MIT License | 6 votes |
def init_hooks(idausr): _setter = IdausrTemporarySetter(idausr) class ActionHandler(ida_kernwin.action_handler_t): def __init__(self, handler): ida_kernwin.action_handler_t.__init__(self) self.handler = handler def activate(self, ctx): with _setter: self.handler() def update(self, ctx): return ida_kernwin.AST_ENABLE_ALWAYS for name, label, handler, before in _HOOKS: if ida_kernwin.unregister_action(name): action = ida_kernwin.action_desc_t(name, label, ActionHandler(handler)) ida_kernwin.register_action(action) ida_kernwin.attach_action_to_menu(before, name, ida_kernwin.SETMENU_INS)
Example #2
Source File: fn_fuzzy.py From ida_haru with Apache License 2.0 | 5 votes |
def __init__(self, items, idb_path, title): ida_kernwin.action_handler_t.__init__(self) self.items = items self.idb_path = idb_path self.title = title
Example #3
Source File: dep_graph.py From UEFI_RETool with MIT License | 5 votes |
def __init__(self, graph): ida_kernwin.action_handler_t.__init__(self) self.graph = graph
Example #4
Source File: Python_editor.py From Python_editor with The Unlicense | 5 votes |
def __init__(self): ida_kernwin.action_handler_t.__init__(self) # Run editor when invoked.
Example #5
Source File: OL_OSX_decryptor.py From malware-research with BSD 2-Clause "Simplified" License | 5 votes |
def __init__(self, callback, var_prop=False): ida_kernwin.action_handler_t.__init__(self) self.var_prop = var_prop self.callback = callback
Example #6
Source File: util.py From idapkg with MIT License | 5 votes |
def register_action(name, shortcut=''): def handler(f): # 1) Create the handler class class MyHandler(ida_kernwin.action_handler_t): def __init__(self): ida_kernwin.action_handler_t.__init__(self) # Say hello when invoked. def activate(self, ctx): t = threading.Thread(target=f) t.start() return 1 # This action is always available. def update(self, ctx): return ida_kernwin.AST_ENABLE_ALWAYS # 2) Describe the action action_desc = ida_kernwin.action_desc_t( name, # The action name. This acts like an ID and must be unique name, # The action text. MyHandler(), # The action handler. shortcut, # Optional: the action shortcut name, # Optional: the action tooltip (available in menus/toolbar) 0) # Optional: the action icon (shows when in menus/toolbars) # 3) Register the action ida_kernwin.register_action(action_desc) return f return handler
Example #7
Source File: stack_strings_helper.py From flare-ida with Apache License 2.0 | 5 votes |
def __init__(self): ida_kernwin.action_handler_t.__init__(self)