Audacity 3.2.0
TagsEditor.h
Go to the documentation of this file.
1/**********************************************************************
2
3 Audacity: A Digital Audio Editor
4
5 TagsEditor.h
6
7 Paul Licameli split from Tags.h
8
9 **********************************************************************/
10
11#ifndef __AUDACITY_TAGS_EDITOR__
12#define __AUDACITY_TAGS_EDITOR__
13
14#include "Tags.h" // member variable
15#include "widgets/wxPanelWrapper.h" // to inherit
16
17class ShuttleGui;
18
20{
21 public:
22 // constructors and destructors
23 TagsEditorDialog(wxWindow * parent,
25 Tags * tags,
26 bool editTitle,
27 bool editTrack);
28
29 virtual ~TagsEditorDialog();
30
31 AUDACITY_DLL_API static bool ShowEditDialog( Tags &tags,
32 wxWindow *parent, const TranslatableString &title, bool force = false);
33
34#if !defined(__WXMSW__)
35 bool IsEscapeKey(const wxKeyEvent& /*event*/) override { return false; }
36#endif
37
39
40 void OnDontShow( wxCommandEvent & Evt);
41 void OnHelp(wxCommandEvent & Evt);
42 bool TransferDataToWindow() override;
43 bool TransferDataFromWindow() override;
44
45 private:
46 void PopulateGenres();
47 void SetEditors();
48
49 void OnChange(wxGridEvent & event);
50
51 void OnEdit(wxCommandEvent & event);
52 void OnReset(wxCommandEvent & event);
53
54 void OnClear(wxCommandEvent & event);
55
56 void OnLoad(wxCommandEvent & event);
57 void OnSave(wxCommandEvent & event);
58 void OnSaveDefaults(wxCommandEvent & event);
59
60 void OnAdd(wxCommandEvent & event);
61 void OnRemove(wxCommandEvent & event);
62
63 void OnOk(wxCommandEvent & event);
64 void DoCancel(bool escKey);
65 void OnCancel(wxCommandEvent & event);
66
67 void OnKeyDown(wxKeyEvent &event);
68
69 bool IsWindowRectValid(const wxRect *windowRect) const;
70
71 private:
75
77
80 wxGridCellStringRenderer *mStringRenderer;
81
82 DECLARE_EVENT_TABLE()
83};
84
85#endif
static const auto title
#define S(N)
Definition: ToChars.cpp:64
Supplies an accessible grid based on wxGrid.
Definition: Grid.h:185
Derived from ShuttleGuiBase, an Audacity specific class for shuttling data to and from GUI.
Definition: ShuttleGui.h:628
Derived from ExpandingToolBar, this dialog allows editing of Tags.
Definition: TagsEditor.h:20
void OnRemove(wxCommandEvent &event)
Definition: TagsEditor.cpp:805
void OnDontShow(wxCommandEvent &Evt)
Definition: TagsEditor.cpp:375
TagsEditorDialog(wxWindow *parent, const TranslatableString &title, Tags *tags, bool editTitle, bool editTrack)
Definition: TagsEditor.cpp:208
wxGridCellStringRenderer * mStringRenderer
Definition: TagsEditor.h:80
void DoCancel(bool escKey)
Definition: TagsEditor.cpp:860
virtual ~TagsEditorDialog()
Definition: TagsEditor.cpp:271
void OnClear(wxCommandEvent &event)
Definition: TagsEditor.cpp:638
void OnAdd(wxCommandEvent &event)
Definition: TagsEditor.cpp:800
void OnKeyDown(wxKeyEvent &event)
Definition: TagsEditor.cpp:881
bool IsWindowRectValid(const wxRect *windowRect) const
Definition: TagsEditor.cpp:928
void OnReset(wxCommandEvent &event)
Definition: TagsEditor.cpp:593
void PopulateOrExchange(ShuttleGui &S)
Definition: TagsEditor.cpp:284
bool TransferDataToWindow() override
Definition: TagsEditor.cpp:441
void OnOk(wxCommandEvent &event)
Definition: TagsEditor.cpp:826
void OnLoad(wxCommandEvent &event)
Definition: TagsEditor.cpp:645
static AUDACITY_DLL_API bool ShowEditDialog(Tags &tags, wxWindow *parent, const TranslatableString &title, bool force=false)
Definition: TagsEditor.cpp:23
void OnSave(wxCommandEvent &event)
Definition: TagsEditor.cpp:700
bool TransferDataFromWindow() override
Definition: TagsEditor.cpp:387
void OnHelp(wxCommandEvent &Evt)
Definition: TagsEditor.cpp:382
void OnSaveDefaults(wxCommandEvent &event)
Definition: TagsEditor.cpp:759
void OnChange(wxGridEvent &event)
Definition: TagsEditor.cpp:503
ComboEditor * mComboEditor
Definition: TagsEditor.h:79
void OnEdit(wxCommandEvent &event)
Definition: TagsEditor.cpp:540
void OnCancel(wxCommandEvent &event)
Definition: TagsEditor.cpp:855
ID3 Tags (for MP3)
Definition: Tags.h:73
Holds a msgid for the translation catalog; may also bind format arguments.