|
@@ -362,6 +362,7 @@ Control *EditorToaster::popup(Control *p_control, Severity p_severity, double p_
|
|
|
close_button->set_flat(true);
|
|
|
close_button->set_icon(get_theme_icon("Close", "EditorIcons"));
|
|
|
close_button->connect("pressed", callable_bind(callable_mp(this, &EditorToaster::close), panel));
|
|
|
+ close_button->connect("theme_changed", callable_bind(callable_mp(this, &EditorToaster::_close_button_theme_changed), close_button));
|
|
|
hbox_container->add_child(close_button);
|
|
|
}
|
|
|
|
|
@@ -438,6 +439,13 @@ void EditorToaster::close(Control *p_control) {
|
|
|
toasts[p_control].popped = false;
|
|
|
}
|
|
|
|
|
|
+void EditorToaster::_close_button_theme_changed(Control *p_close_button) {
|
|
|
+ Button *close_button = Object::cast_to<Button>(p_close_button);
|
|
|
+ if (close_button) {
|
|
|
+ close_button->set_icon(get_theme_icon("Close", "EditorIcons"));
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
EditorToaster *EditorToaster::get_singleton() {
|
|
|
return singleton;
|
|
|
}
|