Remove wxTextCtrl::OnEnabled() hack from wxGTK.
Don't change the background colour when the control is being enabled or disabled, it doesn't seem necessary and it's unclear why was this added by r10179 in the first place. It does result in problems however as it could somehow make the selection of wxTextCtrl invisible when it lost focus and so fixes a serious usability problem which happened to all wxTextCtrls for which a wxEVT_UPDATE_UI handler using wxUpdateUIEvent::Enable() was defined. Closes #14898. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@73756 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1511,11 +1511,6 @@ protected:
|
||||
// widgets state are necessary
|
||||
virtual void DoEnable(bool WXUNUSED(enable)) { }
|
||||
|
||||
// called when the on-screen widget state changes and provides an
|
||||
// an opportunity for the widget to update its visual state (colours,
|
||||
// fonts, anything else) as necessary
|
||||
virtual void OnEnabled(bool WXUNUSED(enabled)) { }
|
||||
|
||||
|
||||
// the window id - a number which uniquely identifies a window among
|
||||
// its siblings unless it is wxID_ANY
|
||||
@@ -1768,7 +1763,7 @@ protected:
|
||||
static void NotifyCaptureLost();
|
||||
|
||||
private:
|
||||
// recursively call our own and our children OnEnabled() when the
|
||||
// recursively call our own and our children DoEnable() when the
|
||||
// enabled/disabled status changed because a parent window had been
|
||||
// enabled/disabled
|
||||
void NotifyWindowOnEnableChange(bool enabled);
|
||||
|
Reference in New Issue
Block a user