mirror of
https://github.com/OrcaSlicer/OrcaSlicer.git
synced 2026-09-27 10:51:22 +00:00
feat: support tab icons
This commit is contained in:
@@ -108,7 +108,7 @@ public:
|
||||
// by this control) and show it immediately.
|
||||
bool ShowNewPage(wxWindow * page)
|
||||
{
|
||||
return AddPage(page, wxString(), ""/*true *//* select it */);
|
||||
return AddPage(page, wxString());
|
||||
}
|
||||
|
||||
// Set effect to use for showing/hiding pages.
|
||||
@@ -139,14 +139,13 @@ public:
|
||||
|
||||
// Implement base class pure virtual methods.
|
||||
|
||||
// adds a new page to the control
|
||||
bool AddPage(wxWindow* page,
|
||||
const wxString& text,
|
||||
const std::string& bmp_name,
|
||||
bool bSelect = false)
|
||||
bool bSelect = false,
|
||||
int imageId = NO_IMAGE) override
|
||||
{
|
||||
DoInvalidateBestSize();
|
||||
return InsertNewPage(GetPageCount(), page, text, bmp_name, bSelect);
|
||||
return InsertPage(GetPageCount(), page, text, bSelect, imageId);
|
||||
}
|
||||
|
||||
//// Page management
|
||||
@@ -167,23 +166,6 @@ public:
|
||||
return true;
|
||||
}
|
||||
|
||||
bool InsertNewPage(size_t n,
|
||||
wxWindow * page,
|
||||
const wxString & text,
|
||||
const std::string& bmp_name = "",
|
||||
bool bSelect = false)
|
||||
{
|
||||
if (!wxBookCtrlBase::InsertPage(n, page, text, bSelect))
|
||||
return false;
|
||||
|
||||
GetBtnsListCtrl()->InsertPage(n, text, bSelect, bmp_name);
|
||||
|
||||
if (bSelect)
|
||||
SetSelection(n);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool RemovePage(size_t n)
|
||||
{
|
||||
if (!wxBookCtrlBase::RemovePage(n))
|
||||
|
||||
Reference in New Issue
Block a user