diff options
author | Yuri Sizov <yuris@humnom.net> | 2022-09-06 20:09:32 +0300 |
---|---|---|
committer | Yuri Sizov <yuris@humnom.net> | 2022-09-06 22:53:17 +0300 |
commit | 43f03e2ce66ce87646642879011c416bbf4ae6fb (patch) | |
tree | d602f1e2c9190453f4dff760b43f68e78af458f2 /scene/gui/scroll_container.cpp | |
parent | 432c4c40a9d29c127a5957944ca8f805dfb836ce (diff) |
Improve naming of theme properties throughout GUI code
Rename ItemList's bg -> panel
Rename ItemList's bg_focus -> focus
Rename ProgressBar's bg -> background
Rename ProgressBar's fg -> fill
Rename Tree's bg -> panel
Rename Tree's bg_focus -> focus
Rename ScrollContainer's bg -> panel
Rename FileDialog's *_icon_modulate -> *_icon_color
Rename FileDialog's files_disabled -> file_disabled_color
Rename CheckButton's on/off -> checked/unchecked
Rename check_v_adjust -> check_v_offset
Diffstat (limited to 'scene/gui/scroll_container.cpp')
-rw-r--r-- | scene/gui/scroll_container.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/scene/gui/scroll_container.cpp b/scene/gui/scroll_container.cpp index f68cebd657..c12ac115b7 100644 --- a/scene/gui/scroll_container.cpp +++ b/scene/gui/scroll_container.cpp @@ -76,14 +76,14 @@ Size2 ScrollContainer::get_minimum_size() const { min_size.x += v_scroll->get_minimum_size().x; } - min_size += theme_cache.bg_style->get_minimum_size(); + min_size += theme_cache.panel_style->get_minimum_size(); return min_size; } void ScrollContainer::_update_theme_item_cache() { Container::_update_theme_item_cache(); - theme_cache.bg_style = get_theme_stylebox(SNAME("bg")); + theme_cache.panel_style = get_theme_stylebox(SNAME("panel")); } void ScrollContainer::_cancel_drag() { @@ -276,8 +276,8 @@ void ScrollContainer::_reposition_children() { Size2 size = get_size(); Point2 ofs; - size -= theme_cache.bg_style->get_minimum_size(); - ofs += theme_cache.bg_style->get_offset(); + size -= theme_cache.panel_style->get_minimum_size(); + ofs += theme_cache.panel_style->get_offset(); bool rtl = is_layout_rtl(); if (h_scroll->is_visible_in_tree() && h_scroll->get_parent() == this) { //scrolls may have been moved out for reasons @@ -341,7 +341,7 @@ void ScrollContainer::_notification(int p_what) { } break; case NOTIFICATION_DRAW: { - draw_style_box(theme_cache.bg_style, Rect2(Vector2(), get_size())); + draw_style_box(theme_cache.panel_style, Rect2(Vector2(), get_size())); } break; case NOTIFICATION_INTERNAL_PHYSICS_PROCESS: { @@ -416,7 +416,7 @@ void ScrollContainer::_notification(int p_what) { void ScrollContainer::update_scrollbars() { Size2 size = get_size(); - size -= theme_cache.bg_style->get_minimum_size(); + size -= theme_cache.panel_style->get_minimum_size(); Size2 hmin = h_scroll->get_combined_minimum_size(); Size2 vmin = v_scroll->get_combined_minimum_size(); |