Skip to content

Commit

Permalink
Merge pull request #90633 from YeldhamDev/the_popup_is_not_wearing_an…
Browse files Browse the repository at this point in the history
…y_panels

Remove `Popup`'s unused "panel" style
  • Loading branch information
akien-mga committed Apr 14, 2024
2 parents 122054c + 7c75355 commit 41fc152
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 11 deletions.
5 changes: 0 additions & 5 deletions doc/classes/Popup.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,4 @@
</description>
</signal>
</signals>
<theme_items>
<theme_item name="panel" data_type="style" type="StyleBox">
Default [StyleBox] for the [Popup].
</theme_item>
</theme_items>
</class>
3 changes: 3 additions & 0 deletions doc/classes/PopupMenu.xml
Original file line number Diff line number Diff line change
Expand Up @@ -768,6 +768,9 @@
<theme_item name="labeled_separator_right" data_type="style" type="StyleBox">
[StyleBox] for the right side of labeled separator. See [method add_separator].
</theme_item>
<theme_item name="panel" data_type="style" type="StyleBox">
[StyleBox] for the the background panel.
</theme_item>
<theme_item name="separator" data_type="style" type="StyleBox">
[StyleBox] used for the separators. See [method add_separator].
</theme_item>
Expand Down
5 changes: 5 additions & 0 deletions doc/classes/PopupPanel.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,9 @@
</description>
<tutorials>
</tutorials>
<theme_items>
<theme_item name="panel" data_type="style" type="StyleBox">
[StyleBox] for the the background panel.
</theme_item>
</theme_items>
</class>
2 changes: 0 additions & 2 deletions scene/gui/popup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,6 @@ Rect2i Popup::_popup_adjust_rect() const {

void Popup::_bind_methods() {
ADD_SIGNAL(MethodInfo("popup_hide"));

BIND_THEME_ITEM_CUSTOM(Theme::DATA_TYPE_STYLEBOX, Popup, panel_style, "panel");
}

Popup::Popup() {
Expand Down
4 changes: 0 additions & 4 deletions scene/gui/popup.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,6 @@ class Popup : public Window {
LocalVector<Window *> visible_parents;
bool popped_up = false;

struct ThemeCache {
Ref<StyleBox> panel_style;
} theme_cache;

void _initialize_visible_parents();
void _deinitialize_visible_parents();

Expand Down

0 comments on commit 41fc152

Please sign in to comment.