diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2022-01-05 10:55:33 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-05 10:55:33 +0100 |
commit | e32c6850920d852b97e0dad3f5d10d21db7d4788 (patch) | |
tree | 61daba643eae0c4808624461de4afa8513b0751d /scene/gui/button.cpp | |
parent | 7c5c3517666a8d9157802ae24b9498a40fcc35dd (diff) | |
parent | 231285b6fb321d4d7e37ee18038e9137acf010eb (diff) |
Merge pull request #54441 from Geometror/checkbutton-checkbox-font-hover-pressed-color
Diffstat (limited to 'scene/gui/button.cpp')
-rw-r--r-- | scene/gui/button.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/scene/gui/button.cpp b/scene/gui/button.cpp index 0c58ec0c60..25e931c287 100644 --- a/scene/gui/button.cpp +++ b/scene/gui/button.cpp @@ -126,7 +126,8 @@ void Button::_notification(int p_what) { } } break; case DRAW_HOVER_PRESSED: { - if (has_theme_stylebox(SNAME("hover_pressed")) && has_theme_stylebox_override("hover_pressed")) { + // Edge case for CheckButton and CheckBox. + if (has_theme_stylebox("hover_pressed")) { if (rtl && has_theme_stylebox(SNAME("hover_pressed_mirrored"))) { style = get_theme_stylebox(SNAME("hover_pressed_mirrored")); } else { @@ -138,8 +139,6 @@ void Button::_notification(int p_what) { } if (has_theme_color(SNAME("font_hover_pressed_color"))) { color = get_theme_color(SNAME("font_hover_pressed_color")); - } else { - color = get_theme_color(SNAME("font_color")); } if (has_theme_color(SNAME("icon_hover_pressed_color"))) { color_icon = get_theme_color(SNAME("icon_hover_pressed_color")); |