![]() |
Audacity 3.2.0
|
#include <ToolBarButtons.h>
Classes | |
| struct | Entry |
Public Types | |
| using | ButtonList = std::vector< Entry > |
Public Member Functions | |
| ToolBarButtons (ToolBar *const parent, AudacityProject &project, ButtonList buttonList, int size, int firstButtonId) | |
| void | OnButton (wxCommandEvent &event) |
| AButton * | CreateButton (teBmps eEnabledUp, teBmps eEnabledDown, teBmps eDisabled, int id, const TranslatableString &label, bool toggle=false) |
| void | SetEnabled (int id, bool state) |
| void | SetCustomEnableDisableButtonsAction (std::function< void()> action) |
| void | PopUp (int id) |
| void | PushDown (int id) |
| void | EnableDisableButtons () |
| void | RegenerateTooltips () |
Private Member Functions | |
| void | ForAllButtons (int Action) |
Private Attributes | |
| ToolBar * | mParent |
| AudacityProject & | mProject |
| int | mFirstButtonId |
| std::vector< AButton * > | mButtons |
| ButtonList | mButtonList |
| std::function< void()> | mCustomEnableDisableButtonsAction |
Definition at line 24 of file ToolBarButtons.h.
| using ToolBarButtons::ButtonList = std::vector<Entry> |
Definition at line 32 of file ToolBarButtons.h.
| ToolBarButtons::ToolBarButtons | ( | ToolBar *const | parent, |
| AudacityProject & | project, | ||
| ButtonList | buttonList, | ||
| int | size, | ||
| int | firstButtonId | ||
| ) |
Definition at line 31 of file ToolBarButtons.cpp.
| AButton * ToolBarButtons::CreateButton | ( | teBmps | eEnabledUp, |
| teBmps | eEnabledDown, | ||
| teBmps | eDisabled, | ||
| int | id, | ||
| const TranslatableString & | label, | ||
| bool | toggle = false |
||
| ) |
Definition at line 64 of file ToolBarButtons.cpp.
References AButton::FrameButton, ThemeBase::Image(), label, mButtons, mFirstButtonId, mParent, safenew, and theTheme.
Referenced by CutCopyPasteToolBar::AddButton(), and EditToolBar::AddButton().
| void ToolBarButtons::EnableDisableButtons | ( | ) |
Definition at line 104 of file ToolBarButtons.cpp.
References ForAllButtons(), and TBActEnableDisable.
Referenced by CutCopyPasteToolBar::EnableDisableButtons(), and EditToolBar::EnableDisableButtons().
|
private |
Definition at line 114 of file ToolBarButtons.cpp.
References entry, CommandManager::Get(), CommandManager::GetEnabled(), mButtonList, mButtons, mCustomEnableDisableButtonsAction, mProject, ToolBar::SetButtonToolTip(), SetEnabled(), TBActEnableDisable, and TBActTooltips.
Referenced by EnableDisableButtons(), and RegenerateTooltips().
| void ToolBarButtons::OnButton | ( | wxCommandEvent & | event | ) |
Definition at line 40 of file ToolBarButtons.cpp.
References CommandManager::Get(), CommandManager::GetUpdateFlags(), CommandDispatch::HandleTextualCommand(), id, mButtonList, mButtons, mFirstButtonId, and mProject.
Referenced by CutCopyPasteToolBar::OnButton(), and EditToolBar::OnButton().
| void ToolBarButtons::PopUp | ( | int | id | ) |
Definition at line 94 of file ToolBarButtons.cpp.
Referenced by EditToolBar::EditToolBar().
| void ToolBarButtons::PushDown | ( | int | id | ) |
Definition at line 99 of file ToolBarButtons.cpp.
Referenced by EditToolBar::EditToolBar(), and EditToolBar::Populate().
| void ToolBarButtons::RegenerateTooltips | ( | ) |
Definition at line 109 of file ToolBarButtons.cpp.
References ForAllButtons(), and TBActTooltips.
Referenced by CutCopyPasteToolBar::RegenerateTooltips(), and EditToolBar::RegenerateTooltips().
| void ToolBarButtons::SetCustomEnableDisableButtonsAction | ( | std::function< void()> | action | ) |
Definition at line 89 of file ToolBarButtons.cpp.
References mCustomEnableDisableButtonsAction.
Referenced by EditToolBar::EditToolBar().
| void ToolBarButtons::SetEnabled | ( | int | id, |
| bool | state | ||
| ) |
Definition at line 84 of file ToolBarButtons.cpp.
Referenced by ForAllButtons(), CutCopyPasteToolBar::Populate(), and EditToolBar::Populate().
|
private |
Definition at line 60 of file ToolBarButtons.h.
Referenced by ForAllButtons(), and OnButton().
|
private |
Definition at line 59 of file ToolBarButtons.h.
Referenced by CreateButton(), ForAllButtons(), OnButton(), PopUp(), PushDown(), and SetEnabled().
|
private |
Definition at line 62 of file ToolBarButtons.h.
Referenced by ForAllButtons(), and SetCustomEnableDisableButtonsAction().
|
private |
Definition at line 57 of file ToolBarButtons.h.
Referenced by CreateButton(), and OnButton().
|
private |
Definition at line 55 of file ToolBarButtons.h.
Referenced by CreateButton().
|
private |
Definition at line 56 of file ToolBarButtons.h.
Referenced by ForAllButtons(), and OnButton().