add_menus
summary: add custom menus to IDA
- description:
It is possible to add custom menus to IDA, either at the toplevel (i.e., into the menubar), or as submenus of existing menus.
Notes:
the same action can be present in more than 1 menu
this example does not deal with context menus
keywords: actions
level: beginner
Attributes
Classes
Module Contents
- class add_menus.greeter_t(greetings)
Bases:
ida_kernwin.action_handler_t- greetings
- activate(ctx)
Activate an action. This function implements the core behavior of an action. It is called when the action is triggered, from a menu, from a popup menu, from the toolbar, or programmatically.
- Returns:
non-zero: all IDA windows will be refreshed
- update(ctx)
Update an action. This is called when the context of the UI changed, and we need to let the action update some of its properties if needed (label, icon, …) In addition, this lets IDA know whether the action is enabled, and when it should be queried for availability again. Note: This callback is not meant to change anything in the application’s state, except by calling one (or many) of the “update_action_*()” functions on this very action.
- add_menus.ACTION_NAME_0 = 'my_action_0'
- add_menus.ACTION_NAME_1 = 'my_action_1'
- add_menus.desc