Follow-up 4652733201
- Fixed Text alignment for Notebook tabs without bitmaps
This commit is contained in:
parent
ffc0e36570
commit
a0328772b9
1 changed files with 1 additions and 1 deletions
|
@ -83,7 +83,7 @@ void ButtonsListCtrl::SetSelection(int sel)
|
||||||
|
|
||||||
bool ButtonsListCtrl::InsertPage(size_t n, const wxString& text, bool bSelect/* = false*/, const std::string& bmp_name/* = ""*/)
|
bool ButtonsListCtrl::InsertPage(size_t n, const wxString& text, bool bSelect/* = false*/, const std::string& bmp_name/* = ""*/)
|
||||||
{
|
{
|
||||||
ScalableButton* btn = new ScalableButton(this, wxID_ANY, bmp_name, text, wxDefaultSize, wxDefaultPosition, wxBU_LEFT | wxBU_EXACTFIT);
|
ScalableButton* btn = new ScalableButton(this, wxID_ANY, bmp_name, text, wxDefaultSize, wxDefaultPosition, wxBU_EXACTFIT | wxNO_BORDER | (bmp_name.empty() ? 0 : wxBU_LEFT));
|
||||||
btn->Bind(wxEVT_BUTTON, [this, btn](wxCommandEvent& event) {
|
btn->Bind(wxEVT_BUTTON, [this, btn](wxCommandEvent& event) {
|
||||||
if (auto it = std::find(m_pageButtons.begin(), m_pageButtons.end(), btn); it != m_pageButtons.end()) {
|
if (auto it = std::find(m_pageButtons.begin(), m_pageButtons.end(), btn); it != m_pageButtons.end()) {
|
||||||
m_selection = it - m_pageButtons.begin();
|
m_selection = it - m_pageButtons.begin();
|
||||||
|
|
Loading…
Reference in a new issue