FIX: wxWidgets asserts

Change-Id: I583edbde501c2bfe8adfa8fdb525479a379a4cb8
This commit is contained in:
chunmao.guo 2022-08-05 14:38:19 +08:00 committed by Lane.Wei
parent a7bd14003b
commit 66c89c62e2
17 changed files with 46 additions and 39 deletions

View file

@ -43,9 +43,16 @@ void CheckBox::SetHalfChecked(bool value)
void CheckBox::Rescale()
{
m_on.msw_rescale();
m_off.msw_rescale();
SetSize(m_on.GetBmpSize());
m_on.msw_rescale();
m_half.msw_rescale();
m_off.msw_rescale();
m_on_disabled.msw_rescale();
m_half_disabled.msw_rescale();
m_off_disabled.msw_rescale();
m_on_focused.msw_rescale();
m_half_focused.msw_rescale();
m_off_focused.msw_rescale();
SetSize(m_on.GetBmpSize());
update();
}

View file

@ -4,8 +4,8 @@
#include "TextInput.hpp"
#include "DropDown.hpp"
#define CB_NO_DROP_ICON 0x1000000
#define CB_NO_TEXT 0x2000000
#define CB_NO_DROP_ICON DD_NO_CHECK_ICON
#define CB_NO_TEXT DD_NO_TEXT
class ComboBox : public wxWindowWithItems<TextInput, wxItemContainer>
{

View file

@ -5,9 +5,9 @@
#include "../wxExtensions.hpp"
#include "StateHandler.hpp"
#define DD_NO_CHECK_ICON 0x1000000
#define DD_NO_TEXT 0x2000000
#define DD_STYLE_MASK 0x3000000
#define DD_NO_CHECK_ICON 0x0001
#define DD_NO_TEXT 0x0002
#define DD_STYLE_MASK 0x0003
wxDECLARE_EVENT(EVT_DISMISS, wxCommandEvent);