|
IDA C++ SDK 9.2
|
Chooser object. #chooser. More...
#include <kernwin.hpp>
Public Types | |
| enum | { POPUP_INS , POPUP_DEL , POPUP_EDIT , POPUP_REFRESH , NSTDPOPUPS } |
| enum | cbres_t { NOTHING_CHANGED , ALL_CHANGED , SELECTION_CHANGED } |
| return value of ins(), del(), edit(), enter(), refresh() callbacks More... | |
Public Member Functions | |
| chooser_base_t (uint32 flags_=0, int columns_=0, const int *widths_=nullptr, const char *const *header_=nullptr, const char *title_=nullptr, uint16 flags2_=0) | |
| virtual | ~chooser_base_t () |
| DEFINE_MEMORY_ALLOCATION_FUNCS () void call_destructor() | |
| virtual void * | get_chooser_obj () |
| get pointer to some custom data. | |
| virtual const void * | get_obj_id (size_t *len) const |
| get the id of the chooser data. | |
| bool | is_same (const chooser_base_t *other) const |
| do the current and the given objects hold the same data? | |
| bool | can_ins () const |
| is an operation allowed? | |
| bool | can_del () const |
| bool | can_edit () const |
| bool | can_refresh () const |
| bool | popup_allowed (int stdact_idx) const |
| is a standard action allowed? | |
| bool | is_status_bar_hidden () const |
| bool | should_restore_geometry () const |
| bool | is_modal () const |
| is choose modal? | |
| bool | has_widget_lifecycle () const |
| should chooser object be deleted when the widget gets destroyed? | |
| bool | is_multi () const |
| is multi-selection allowed? | |
| bool | ask_item_attrs () const |
| should chooser generate ui_get_chooser_item_attrs events? | |
| bool | is_force_default () const |
| should selection of the already opened non-modal chooser be changed? | |
| uint | get_builtin_number () const |
| get number of the built-in chooser | |
| void | set_ask_item_attrs (bool enable) |
| enable or disable generation of ui_get_chooser_item_attrs events | |
| void | check_version (uint32 ver) const |
| bool | is_quick_filter_visible_initially () const |
| int | get_quick_filter_initial_mode () const |
| bool | has_dirtree () const |
| bool | has_diff_capability () const |
| bool | can_sort () const |
| bool | can_filter () const |
| bool | should_rename_trigger_edit () const |
| bool | is_dirtree_persisted () const |
| bool | is_lazy_loaded () const |
| bool | has_inode_to_index () const |
| virtual bool idaapi | init () |
| initialize the chooser and populate it. | |
| virtual size_t idaapi | get_count () const =0 |
| get the number of elements in the chooser | |
| virtual void idaapi | get_row (qstrvec_t *out, int *out_icon, chooser_item_attrs_t *out_attrs, size_t n) const =0 |
| get a description of an element. | |
| virtual ea_t idaapi | get_ea (size_t) const |
| get the address of an element. | |
| virtual void idaapi | closed () |
| The chooser window is closed. | |
Public Attributes | |
| immutable | |
| int | x0 = -1 |
| screen position, Functions: generic list choosers | |
| int | y0 = -1 |
| int | x1 = -1 |
| int | y1 = -1 |
| int | width = 0 |
| (in chars) | |
| int | height = 0 |
| (in chars) | |
| const char * | title |
| menu title (includes ptr to help). | |
| int | columns |
| number of columns | |
| const int * | widths |
| column widths | |
| const char *const * | header |
| header line; contains the tooltips, and column name for each of 'columns' columns. | |
| int | icon = -1 |
| default icon | |
| qstring | popup_names [NSTDPOPUPS] |
| array of custom labels of the standard actions. | |
| int | deflt_col = 0 |
| Column that will have focus. | |
Static Public Attributes | |
| static constexpr ssize_t | NO_SELECTION = -1 |
| there is no selected item | |
| static constexpr ssize_t | EMPTY_CHOOSER = -2 |
| the chooser has no data and cannot be displayed | |
| static constexpr ssize_t | ALREADY_EXISTS = -3 |
| the non-modal chooser with the same data is already open | |
| static constexpr ssize_t | NO_ATTR = -4 |
| reserved for IDAPython | |
Protected Member Functions | |
| void | init_popup_names (const char *const default_popup_names[NSTDPOPUPS]) |
Protected Attributes | |
| uint8 | version = 3 |
| version of the class | |
| uint8 | reserved = 0 |
| uint16 | flags2 |
| Extended chooser flags | |
| uint32 | flags |
| Generic chooser flags | |
| mutable | |
Chooser object. #chooser.
return value of ins(), del(), edit(), enter(), refresh() callbacks
If the chooser implements get_dirtree(), and has ins() and/or del() capabilities, the meaning of the returned index(es) combined with ALL_CHANGED and SELECTION_CHANGED must be as follows:
| Enumerator | |
|---|---|
| NOTHING_CHANGED | |
| ALL_CHANGED | |
| SELECTION_CHANGED | |
|
inline |
|
inlinevirtual |
|
inline |
|
inlinevirtual |
get pointer to some custom data.
|
inlinevirtual |
get the id of the chooser data.
The choosers are the same if they have the same data ids.
| [out] | len | length of the id. If it is 0 then it is considered that the method returned an unique id. |
|
inline |
do the current and the given objects hold the same data?
|
inline |
is an operation allowed?
|
inline |
|
inline |
|
inline |
|
inline |
is a standard action allowed?
|
inline |
|
inline |
|
inline |
is choose modal?
|
inline |
should chooser object be deleted when the widget gets destroyed?
|
inline |
is multi-selection allowed?
|
inline |
should chooser generate ui_get_chooser_item_attrs events?
|
inline |
should selection of the already opened non-modal chooser be changed?
|
inline |
get number of the built-in chooser
enable or disable generation of ui_get_chooser_item_attrs events
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlinevirtual |
initialize the chooser and populate it.
| false | the chooser is empty, do not display it |
|
pure virtual |
get the number of elements in the chooser
|
pure virtual |
get a description of an element.
| [out] | out | vector of strings. will receive the contents of each column |
| [out] | out_icon | element's icon id, -1 - no icon |
| [out] | out_attrs | element attributes |
| n | element number (0..get_count()-1) |
|
inlinevirtual |
get the address of an element.
When this function returns valid addresses:
| n | element number (0-based) |
|
inlinevirtual |
The chooser window is closed.
|
inlineprotected |
| chooser_base_t::immutable |
|
protected |
version of the class
|
protected |
|
protected |
|
protected |
| int chooser_base_t::x0 = -1 |
screen position, Functions: generic list choosers
| int chooser_base_t::y0 = -1 |
| int chooser_base_t::x1 = -1 |
| int chooser_base_t::y1 = -1 |
| int chooser_base_t::width = 0 |
(in chars)
| int chooser_base_t::height = 0 |
(in chars)
| const char* chooser_base_t::title |
menu title (includes ptr to help).
May have chooser title prefixes (see "Chooser title" above).
| int chooser_base_t::columns |
number of columns
| const int* chooser_base_t::widths |
column widths
| const char* const* chooser_base_t::header |
header line; contains the tooltips, and column name for each of 'columns' columns.
When tooltips need to be provided, the syntax should be: "#tooltip#column-name". (Otherwise, the syntax is simply "column-name".)
| int chooser_base_t::icon = -1 |
default icon
| qstring chooser_base_t::popup_names[NSTDPOPUPS] |
array of custom labels of the standard actions.
Used to replace labels for these actions.
An empty name means that the default name will be used.
| int chooser_base_t::deflt_col = 0 |
Column that will have focus.
|
protected |