|
KiCad PCB EDA Suite
|
#include <dialog_template_selector.h>
Public Types | |
| enum class | CATEGORY { USER , SYSTEM , BROWSED } |
Public Member Functions | |
| TEMPLATE_WIDGET (wxWindow *aParent, DIALOG_TEMPLATE_SELECTOR *aDialog) | |
| void | SetTemplate (PROJECT_TEMPLATE *aTemplate) |
| Set the project template for this widget, which will determine the icon and title associated with this project template widget. | |
| PROJECT_TEMPLATE * | GetTemplate () |
| wxString | GetTemplatePath () const |
| The template directory, the identity used for recent and pinned templates. | |
| void | SetPinned (bool aPinned) |
| bool | IsPinned () const |
| void | Select () |
| void | SelectWithoutStateChange () |
| void | Unselect () |
| void | SetDescription (const wxString &aDescription) |
| wxString | GetDescription () const |
| void | SetCategory (CATEGORY aCategory) |
| CATEGORY | GetCategory () const |
| bool | IsUserTemplate () const |
| bool | IsSelected () const |
Protected Member Functions | |
| void | OnMouse (wxMouseEvent &event) |
| void | OnDoubleClick (wxMouseEvent &event) |
| void | OnSize (wxSizeEvent &event) |
| void | onRightClick (wxMouseEvent &event) |
| void | onEditTemplate (wxCommandEvent &event) |
| void | onOpenFolder (wxCommandEvent &event) |
| void | onDuplicateTemplate (wxCommandEvent &event) |
| void | onTogglePinned (wxCommandEvent &event) |
Protected Attributes | |
| DIALOG_TEMPLATE_SELECTOR * | m_dialog |
| wxWindow * | m_parent |
| wxPanel * | m_panel |
| bool | m_selected |
| bool | m_pinned |
| CATEGORY | m_category |
| wxString | m_description |
| PROJECT_TEMPLATE * | m_currTemplate |
| wxStaticBitmap * | m_bitmapIcon |
| wxStaticText * | m_titleLabel |
| wxStaticText * | m_descLabel |
Definition at line 64 of file dialog_template_selector.h.
|
strong |
| Enumerator | |
|---|---|
| USER | |
| SYSTEM | |
| BROWSED | |
Definition at line 67 of file dialog_template_selector.h.
| TEMPLATE_WIDGET::TEMPLATE_WIDGET | ( | wxWindow * | aParent, |
| DIALOG_TEMPLATE_SELECTOR * | aDialog ) |
Definition at line 143 of file dialog_template_selector.cpp.
References KIUI::GetInfoFont(), TEMPLATE_WIDGET_BASE::m_bitmapIcon, m_category, m_currTemplate, TEMPLATE_WIDGET_BASE::m_descLabel, m_dialog, m_parent, m_pinned, TEMPLATE_WIDGET_BASE::m_titleLabel, OnDoubleClick(), OnMouse(), onRightClick(), OnSize(), TEMPLATE_WIDGET_BASE::TEMPLATE_WIDGET_BASE(), and Unselect().
|
inline |
Definition at line 98 of file dialog_template_selector.h.
References m_category.
|
inline |
Definition at line 95 of file dialog_template_selector.h.
References m_description.
|
inline |
Definition at line 82 of file dialog_template_selector.h.
References m_currTemplate.
Referenced by DIALOG_TEMPLATE_SELECTOR::SetWidget().
| wxString TEMPLATE_WIDGET::GetTemplatePath | ( | ) | const |
The template directory, the identity used for recent and pinned templates.
Definition at line 257 of file dialog_template_selector.cpp.
References m_currTemplate.
Referenced by onTogglePinned().
|
inline |
Definition at line 88 of file dialog_template_selector.h.
References m_pinned.
|
inline |
Definition at line 115 of file dialog_template_selector.h.
References m_selected.
|
inline |
Definition at line 102 of file dialog_template_selector.h.
References m_category.
|
protected |
Definition at line 327 of file dialog_template_selector.cpp.
References m_dialog, and Select().
Referenced by TEMPLATE_WIDGET().
|
protected |
Definition at line 424 of file dialog_template_selector.cpp.
References _, DisplayErrorMessage(), DisplayInfoMessage(), PROJECT_TREE_TRAVERSER::GetErrors(), m_currTemplate, m_dialog, and DIALOG_TEMPLATE_SELECTOR::RefreshTemplateList().
Referenced by onRightClick().
|
protected |
Definition at line 378 of file dialog_template_selector.cpp.
References _, DisplayErrorMessage(), m_currTemplate, and m_dialog.
Referenced by onRightClick().
|
protected |
Definition at line 320 of file dialog_template_selector.cpp.
References Select().
Referenced by TEMPLATE_WIDGET().
|
protected |
Definition at line 411 of file dialog_template_selector.cpp.
References _, DisplayError(), and m_currTemplate.
Referenced by onRightClick().
|
protected |
Definition at line 335 of file dialog_template_selector.cpp.
References _, ID_TOGGLE_PINNED, m_category, m_currTemplate, m_dialog, m_pinned, onDuplicateTemplate(), onEditTemplate(), onOpenFolder(), and onTogglePinned().
Referenced by TEMPLATE_WIDGET().
|
protected |
Definition at line 294 of file dialog_template_selector.cpp.
References TEMPLATE_WIDGET_BASE::m_descLabel, and m_description.
Referenced by TEMPLATE_WIDGET().
|
protected |
Definition at line 371 of file dialog_template_selector.cpp.
References GetTemplatePath(), m_currTemplate, m_dialog, and m_pinned.
Referenced by onRightClick().
| void TEMPLATE_WIDGET::Select | ( | ) |
Definition at line 187 of file dialog_template_selector.cpp.
References TEMPLATE_WIDGET_BASE::m_descLabel, m_dialog, m_selected, and TEMPLATE_WIDGET_BASE::m_titleLabel.
Referenced by OnDoubleClick(), and OnMouse().
| void TEMPLATE_WIDGET::SelectWithoutStateChange | ( | ) |
Definition at line 198 of file dialog_template_selector.cpp.
References TEMPLATE_WIDGET_BASE::m_descLabel, m_selected, and TEMPLATE_WIDGET_BASE::m_titleLabel.
|
inline |
Definition at line 97 of file dialog_template_selector.h.
References m_category.
Referenced by DIALOG_TEMPLATE_SELECTOR::BuildTemplateList().
| void TEMPLATE_WIDGET::SetDescription | ( | const wxString & | aDescription | ) |
Definition at line 280 of file dialog_template_selector.cpp.
References TEMPLATE_WIDGET_BASE::m_descLabel, and m_description.
Referenced by DIALOG_TEMPLATE_SELECTOR::BuildTemplateList().
| void TEMPLATE_WIDGET::SetPinned | ( | bool | aPinned | ) |
Definition at line 268 of file dialog_template_selector.cpp.
References LIB_TREE_MODEL_ADAPTER::GetPinningSymbol(), m_currTemplate, m_pinned, and TEMPLATE_WIDGET_BASE::m_titleLabel.
| void TEMPLATE_WIDGET::SetTemplate | ( | PROJECT_TEMPLATE * | aTemplate | ) |
Set the project template for this widget, which will determine the icon and title associated with this project template widget.
Definition at line 218 of file dialog_template_selector.cpp.
References PROJECT_TEMPLATE::GetIcon(), KIUI::GetInfoFont(), PROJECT_TEMPLATE::GetTitle(), icon_kicad, KiBitmapBundleDef(), TEMPLATE_WIDGET_BASE::m_bitmapIcon, m_currTemplate, TEMPLATE_WIDGET_BASE::m_titleLabel, and scale.
Referenced by DIALOG_TEMPLATE_SELECTOR::BuildTemplateList().
| void TEMPLATE_WIDGET::Unselect | ( | ) |
Definition at line 208 of file dialog_template_selector.cpp.
References TEMPLATE_WIDGET_BASE::m_descLabel, m_selected, and TEMPLATE_WIDGET_BASE::m_titleLabel.
Referenced by TEMPLATE_WIDGET().
|
protectedinherited |
Definition at line 115 of file dialog_template_selector_base.h.
Referenced by TEMPLATE_WIDGET::SetTemplate(), TEMPLATE_WIDGET::TEMPLATE_WIDGET(), and TEMPLATE_WIDGET_BASE().
|
protected |
Definition at line 123 of file dialog_template_selector.h.
Referenced by GetCategory(), IsUserTemplate(), onRightClick(), SetCategory(), and TEMPLATE_WIDGET().
|
protected |
Definition at line 126 of file dialog_template_selector.h.
Referenced by GetTemplate(), GetTemplatePath(), onDuplicateTemplate(), onEditTemplate(), onOpenFolder(), onRightClick(), onTogglePinned(), SetPinned(), SetTemplate(), and TEMPLATE_WIDGET().
|
protectedinherited |
Definition at line 117 of file dialog_template_selector_base.h.
Referenced by TEMPLATE_WIDGET::OnSize(), TEMPLATE_WIDGET::Select(), TEMPLATE_WIDGET::SelectWithoutStateChange(), TEMPLATE_WIDGET::SetDescription(), TEMPLATE_WIDGET::TEMPLATE_WIDGET(), TEMPLATE_WIDGET_BASE(), and TEMPLATE_WIDGET::Unselect().
|
protected |
Definition at line 124 of file dialog_template_selector.h.
Referenced by GetDescription(), OnSize(), and SetDescription().
|
protected |
Definition at line 118 of file dialog_template_selector.h.
Referenced by OnDoubleClick(), onDuplicateTemplate(), onEditTemplate(), onRightClick(), onTogglePinned(), Select(), and TEMPLATE_WIDGET().
|
protected |
Definition at line 120 of file dialog_template_selector.h.
|
protected |
Definition at line 119 of file dialog_template_selector.h.
Referenced by TEMPLATE_WIDGET().
|
protected |
Definition at line 122 of file dialog_template_selector.h.
Referenced by IsPinned(), onRightClick(), onTogglePinned(), SetPinned(), and TEMPLATE_WIDGET().
|
protected |
Definition at line 121 of file dialog_template_selector.h.
Referenced by IsSelected(), Select(), SelectWithoutStateChange(), and Unselect().
|
protectedinherited |
Definition at line 116 of file dialog_template_selector_base.h.
Referenced by TEMPLATE_WIDGET::Select(), TEMPLATE_WIDGET::SelectWithoutStateChange(), TEMPLATE_WIDGET::SetPinned(), TEMPLATE_WIDGET::SetTemplate(), TEMPLATE_WIDGET::TEMPLATE_WIDGET(), TEMPLATE_WIDGET_BASE(), and TEMPLATE_WIDGET::Unselect().