KiCad PCB EDA Suite
|
#include <panel_hotkeys_editor.h>
Public Member Functions | |
PANEL_HOTKEYS_EDITOR (EDA_BASE_FRAME *aFrame, wxWindow *aWindow, bool aReadOnly) | |
~PANEL_HOTKEYS_EDITOR () | |
std::vector< TOOL_ACTION * > & | ActionsList () |
bool | TransferDataToWindow () override |
bool | TransferDataFromWindow () override |
void | ResetPanel () override |
Reset the contents of this panel. | |
wxString | GetResetTooltip () const override |
Get the tooltip the reset button should display when showing this panel. | |
wxString | GetHelpTextAtPoint (const wxPoint &aPt, wxHelpEvent::Origin aOrigin) const override |
Overridden to supply the reset button tooltip when queried with { -INT_MAX, INT_MAX }. | |
Protected Attributes | |
EDA_BASE_FRAME * | m_frame |
bool | m_readOnly |
std::vector< TOOL_ACTION * > | m_actions |
HOTKEY_STORE | m_hotkeyStore |
WIDGET_HOTKEY_LIST * | m_hotkeyListCtrl |
Private Member Functions | |
void | installButtons (wxSizer *aSizer) |
Install the button panel (global reset/default, import/export) | |
void | OnFilterSearch (wxCommandEvent &aEvent) |
Handle a change in the hotkey filter text. | |
void | ImportHotKeys () |
Put up a dialog allowing the user to select a hotkeys file and then overlays those hotkeys onto the current hotkey store. | |
void | dumpHotkeys () |
Dump all actions and their hotkeys to a text file for inclusion in documentation. | |
Private Attributes | |
wxSearchCtrl * | m_filterSearch |
Definition at line 42 of file panel_hotkeys_editor.h.
PANEL_HOTKEYS_EDITOR::PANEL_HOTKEYS_EDITOR | ( | EDA_BASE_FRAME * | aFrame, |
wxWindow * | aWindow, | ||
bool | aReadOnly | ||
) |
Definition at line 68 of file panel_hotkeys_editor.cpp.
References _, CreateTextFilterBox(), installButtons(), m_filterSearch, m_hotkeyListCtrl, m_hotkeyStore, m_readOnly, and OnFilterSearch().
PANEL_HOTKEYS_EDITOR::~PANEL_HOTKEYS_EDITOR | ( | ) |
Definition at line 110 of file panel_hotkeys_editor.cpp.
References m_filterSearch, and OnFilterSearch().
|
inline |
Definition at line 48 of file panel_hotkeys_editor.h.
References m_actions.
Referenced by DIALOG_LIST_HOTKEYS::DIALOG_LIST_HOTKEYS(), and EDA_BASE_FRAME::ShowPreferences().
|
private |
Dump all actions and their hotkeys to a text file for inclusion in documentation.
The format is asciidoc-compatible table rows. This function is hidden behind an advanced config flag and not intended for users.
Definition at line 230 of file panel_hotkeys_editor.cpp.
References _, EDA_BASE_FRAME::GetMruPath(), HOTKEY_STORE::GetSections(), KeyNameFromKeyCode(), HOTKEY::m_Actions, HOTKEY::m_EditKeycode, m_frame, m_hotkeyStore, FILEEXT::TextFileExtension, and FILEEXT::TextFileWildcard().
Referenced by installButtons().
|
inlineoverrideinherited |
Overridden to supply the reset button tooltip when queried with { -INT_MAX, INT_MAX }.
Definition at line 72 of file resettable_panel.h.
References RESETTABLE_PANEL::GetResetTooltip().
|
inlineoverridevirtual |
Get the tooltip the reset button should display when showing this panel.
Reimplemented from RESETTABLE_PANEL.
Definition at line 55 of file panel_hotkeys_editor.h.
References _.
|
private |
Put up a dialog allowing the user to select a hotkeys file and then overlays those hotkeys onto the current hotkey store.
Definition at line 199 of file panel_hotkeys_editor.cpp.
References _, EDA_BASE_FRAME::GetMruPath(), HOTKEY_STORE::GetSections(), FILEEXT::HotkeyFileExtension, FILEEXT::HotkeyFileWildcard(), HOTKEY::m_Actions, HOTKEY::m_EditKeycode, HOTKEY::m_EditKeycodeAlt, m_frame, m_hotkeyListCtrl, m_hotkeyStore, ReadHotKeyConfig(), EDA_BASE_FRAME::SetMruPath(), and WIDGET_HOTKEY_LIST::TransferDataToControl().
Referenced by installButtons().
|
private |
Install the button panel (global reset/default, import/export)
aSizer | the dialog to install on. |
Definition at line 123 of file panel_hotkeys_editor.cpp.
References _, dumpHotkeys(), ADVANCED_CFG::GetCfg(), KIUI::GetStdMargin(), ImportHotKeys(), m_hotkeyListCtrl, and WIDGET_HOTKEY_LIST::ResetAllHotkeys().
Referenced by PANEL_HOTKEYS_EDITOR().
|
private |
Handle a change in the hotkey filter text.
aEvent | is the search event, used to get the search query. |
Definition at line 192 of file panel_hotkeys_editor.cpp.
References WIDGET_HOTKEY_LIST::ApplyFilterString(), and m_hotkeyListCtrl.
Referenced by PANEL_HOTKEYS_EDITOR(), and ~PANEL_HOTKEYS_EDITOR().
|
overridevirtual |
Reset the contents of this panel.
Implements RESETTABLE_PANEL.
Definition at line 117 of file panel_hotkeys_editor.cpp.
References m_hotkeyListCtrl, and WIDGET_HOTKEY_LIST::ResetAllHotkeys().
|
override |
Definition at line 178 of file panel_hotkeys_editor.cpp.
References m_actions, m_hotkeyListCtrl, m_readOnly, WIDGET_HOTKEY_LIST::TransferDataFromControl(), and WriteHotKeyConfig().
|
override |
Definition at line 167 of file panel_hotkeys_editor.cpp.
References HOTKEY_STORE::Init(), m_actions, m_hotkeyListCtrl, m_hotkeyStore, m_readOnly, and WIDGET_HOTKEY_LIST::TransferDataToControl().
Referenced by DIALOG_LIST_HOTKEYS::TransferDataToWindow().
|
protected |
Definition at line 95 of file panel_hotkeys_editor.h.
Referenced by ActionsList(), TransferDataFromWindow(), and TransferDataToWindow().
|
private |
Definition at line 89 of file panel_hotkeys_editor.h.
Referenced by PANEL_HOTKEYS_EDITOR(), and ~PANEL_HOTKEYS_EDITOR().
|
protected |
Definition at line 92 of file panel_hotkeys_editor.h.
Referenced by dumpHotkeys(), and ImportHotKeys().
|
protected |
Definition at line 97 of file panel_hotkeys_editor.h.
Referenced by ImportHotKeys(), installButtons(), OnFilterSearch(), PANEL_HOTKEYS_EDITOR(), ResetPanel(), TransferDataFromWindow(), and TransferDataToWindow().
|
protected |
Definition at line 96 of file panel_hotkeys_editor.h.
Referenced by dumpHotkeys(), ImportHotKeys(), PANEL_HOTKEYS_EDITOR(), and TransferDataToWindow().
|
protected |
Definition at line 93 of file panel_hotkeys_editor.h.
Referenced by PANEL_HOTKEYS_EDITOR(), TransferDataFromWindow(), and TransferDataToWindow().