diff options
Diffstat (limited to 'scene')
-rw-r--r-- | scene/gui/item_list.cpp | 2 | ||||
-rw-r--r-- | scene/gui/item_list.h | 2 | ||||
-rw-r--r-- | scene/gui/popup_menu.cpp | 10 | ||||
-rw-r--r-- | scene/gui/rich_text_label.cpp | 2 | ||||
-rw-r--r-- | scene/gui/rich_text_label.h | 2 | ||||
-rw-r--r-- | scene/gui/scroll_container.cpp | 8 | ||||
-rw-r--r-- | scene/gui/scroll_container.h | 4 |
7 files changed, 15 insertions, 15 deletions
diff --git a/scene/gui/item_list.cpp b/scene/gui/item_list.cpp index 6deb39b9e2..34b1dd4f24 100644 --- a/scene/gui/item_list.cpp +++ b/scene/gui/item_list.cpp @@ -1652,7 +1652,7 @@ void ItemList::_bind_methods() { ClassDB::bind_method(D_METHOD("ensure_current_is_visible"), &ItemList::ensure_current_is_visible); - ClassDB::bind_method(D_METHOD("get_v_scroll"), &ItemList::get_v_scroll); + ClassDB::bind_method(D_METHOD("get_v_scroll_bar"), &ItemList::get_v_scroll_bar); ClassDB::bind_method(D_METHOD("set_text_overrun_behavior", "overrun_behavior"), &ItemList::set_text_overrun_behavior); ClassDB::bind_method(D_METHOD("get_text_overrun_behavior"), &ItemList::get_text_overrun_behavior); diff --git a/scene/gui/item_list.h b/scene/gui/item_list.h index e780179e7b..83af879dff 100644 --- a/scene/gui/item_list.h +++ b/scene/gui/item_list.h @@ -255,7 +255,7 @@ public: void set_autoscroll_to_bottom(const bool p_enable); - VScrollBar *get_v_scroll() { return scroll_bar; } + VScrollBar *get_v_scroll_bar() { return scroll_bar; } ItemList(); ~ItemList(); diff --git a/scene/gui/popup_menu.cpp b/scene/gui/popup_menu.cpp index a61d77e95c..8837e5ea63 100644 --- a/scene/gui/popup_menu.cpp +++ b/scene/gui/popup_menu.cpp @@ -50,7 +50,7 @@ Size2 PopupMenu::_get_contents_minimum_size() const { int hseparation = get_theme_constant(SNAME("hseparation")); Size2 minsize = get_theme_stylebox(SNAME("panel"))->get_minimum_size(); // Accounts for margin in the margin container - minsize.x += scroll_container->get_v_scrollbar()->get_size().width * 2; // Adds a buffer so that the scrollbar does not render over the top of content + minsize.x += scroll_container->get_v_scroll_bar()->get_size().width * 2; // Adds a buffer so that the scrollbar does not render over the top of content float max_w = 0.0; float icon_w = 0.0; @@ -343,11 +343,11 @@ void PopupMenu::gui_input(const Ref<InputEvent> &p_event) { // Make an area which does not include v scrollbar, so that items are not activated when dragging scrollbar. Rect2 item_clickable_area = scroll_container->get_rect(); - if (scroll_container->get_v_scrollbar()->is_visible_in_tree()) { + if (scroll_container->get_v_scroll_bar()->is_visible_in_tree()) { if (is_layout_rtl()) { - item_clickable_area.position.x += scroll_container->get_v_scrollbar()->get_size().width; + item_clickable_area.position.x += scroll_container->get_v_scroll_bar()->get_size().width; } else { - item_clickable_area.size.width -= scroll_container->get_v_scrollbar()->get_size().width; + item_clickable_area.size.width -= scroll_container->get_v_scroll_bar()->get_size().width; } } @@ -508,7 +508,7 @@ void PopupMenu::_draw_items() { Color font_hover_color = get_theme_color(SNAME("font_hover_color")); Color font_separator_color = get_theme_color(SNAME("font_separator_color")); - float scroll_width = scroll_container->get_v_scrollbar()->is_visible_in_tree() ? scroll_container->get_v_scrollbar()->get_size().width : 0; + float scroll_width = scroll_container->get_v_scroll_bar()->is_visible_in_tree() ? scroll_container->get_v_scroll_bar()->get_size().width : 0; float display_width = control->get_size().width - scroll_width; // Find the widest icon and whether any items have a checkbox, and store the offsets for each. diff --git a/scene/gui/rich_text_label.cpp b/scene/gui/rich_text_label.cpp index 19d165ef54..dfa871a345 100644 --- a/scene/gui/rich_text_label.cpp +++ b/scene/gui/rich_text_label.cpp @@ -4121,7 +4121,7 @@ void RichTextLabel::_bind_methods() { ClassDB::bind_method(D_METHOD("set_scroll_follow", "follow"), &RichTextLabel::set_scroll_follow); ClassDB::bind_method(D_METHOD("is_scroll_following"), &RichTextLabel::is_scroll_following); - ClassDB::bind_method(D_METHOD("get_v_scroll"), &RichTextLabel::get_v_scroll); + ClassDB::bind_method(D_METHOD("get_v_scroll_bar"), &RichTextLabel::get_v_scroll_bar); ClassDB::bind_method(D_METHOD("scroll_to_line", "line"), &RichTextLabel::scroll_to_line); ClassDB::bind_method(D_METHOD("scroll_to_paragraph", "paragraph"), &RichTextLabel::scroll_to_paragraph); diff --git a/scene/gui/rich_text_label.h b/scene/gui/rich_text_label.h index d803e44b65..63d78810bf 100644 --- a/scene/gui/rich_text_label.h +++ b/scene/gui/rich_text_label.h @@ -544,7 +544,7 @@ public: int get_content_height() const; - VScrollBar *get_v_scroll() { return vscroll; } + VScrollBar *get_v_scroll_bar() { return vscroll; } virtual CursorShape get_cursor_shape(const Point2 &p_pos) const override; diff --git a/scene/gui/scroll_container.cpp b/scene/gui/scroll_container.cpp index dcd2c32a3b..d957202550 100644 --- a/scene/gui/scroll_container.cpp +++ b/scene/gui/scroll_container.cpp @@ -532,11 +532,11 @@ TypedArray<String> ScrollContainer::get_configuration_warnings() const { return warnings; } -HScrollBar *ScrollContainer::get_h_scrollbar() { +HScrollBar *ScrollContainer::get_h_scroll_bar() { return h_scroll; } -VScrollBar *ScrollContainer::get_v_scrollbar() { +VScrollBar *ScrollContainer::get_v_scroll_bar() { return v_scroll; } @@ -561,8 +561,8 @@ void ScrollContainer::_bind_methods() { ClassDB::bind_method(D_METHOD("set_follow_focus", "enabled"), &ScrollContainer::set_follow_focus); ClassDB::bind_method(D_METHOD("is_following_focus"), &ScrollContainer::is_following_focus); - ClassDB::bind_method(D_METHOD("get_h_scrollbar"), &ScrollContainer::get_h_scrollbar); - ClassDB::bind_method(D_METHOD("get_v_scrollbar"), &ScrollContainer::get_v_scrollbar); + ClassDB::bind_method(D_METHOD("get_h_scroll_bar"), &ScrollContainer::get_h_scroll_bar); + ClassDB::bind_method(D_METHOD("get_v_scroll_bar"), &ScrollContainer::get_v_scroll_bar); ClassDB::bind_method(D_METHOD("ensure_control_visible", "control"), &ScrollContainer::ensure_control_visible); ADD_SIGNAL(MethodInfo("scroll_started")); diff --git a/scene/gui/scroll_container.h b/scene/gui/scroll_container.h index 0cec4db57a..8d710591a1 100644 --- a/scene/gui/scroll_container.h +++ b/scene/gui/scroll_container.h @@ -105,8 +105,8 @@ public: bool is_following_focus() const; void set_follow_focus(bool p_follow); - HScrollBar *get_h_scrollbar(); - VScrollBar *get_v_scrollbar(); + HScrollBar *get_h_scroll_bar(); + VScrollBar *get_v_scroll_bar(); void ensure_control_visible(Control *p_control); TypedArray<String> get_configuration_warnings() const override; |