Fix wrongly recreating wxComboBox in disabled state in wxMSW
When recreating a wxComboBox, as sometimes needs to be done when adding a new bitmap to wxBitmapComboBox, for example, we should only disable it if the old combobox itself was disabled, not if (any of) its parent(s) were disabled, but IsEnabled() returned true even in this case. Use IsThisEnabled() instead to ensure that we only disable the new combobox if necessary. Closes #23132.
This commit is contained in:
parent
451772530c
commit
8e604926c3
1 changed files with 1 additions and 1 deletions
|
|
@ -537,7 +537,7 @@ void wxComboBox::MSWRecreate()
|
|||
SetSelection(selection);
|
||||
|
||||
// If disabled we'll have to disable it again after re-creating
|
||||
if ( !IsEnabled() )
|
||||
if ( !IsThisEnabled() )
|
||||
DoEnable(false);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue