godot/scene/gui
aaronp64 5a25637ca9 Fix Container::pending_sort tracking
When Container::queue_sort() is called, pending_sort is set to true to indicate when a call to _sort_children() is queued, to avoid queueing multiple calls. Container::_sort_children() sets pending_sort back to false when finished, but did not do this when the container was not inside the tree.  This would allow cases where queue_sort() could be called just before removing from the tree, causing _sort_children() to never reset pending_sort, preventing any future queue_sort() calls from queueing again.

One case where this happened was with the "Saving Scene" progress bar in the editor - when saving for the first time (or the first time the progress bar popup otherwise appeared in the editor), _sort_children() would be called successfully.  After the progress bar popup was hidden, then shown again on future saves, _sort_children() would not be called again, resulting in the progress bar not taking up as much space as it should.

This issue used to be avoided by setting pending_sort to false immediately on NOTIFICATION_ENTER_TREE - however, this would allow multiple calls to be queued at the same time when entering the tree (#92644).  The multiple calls was fixed recently by removing this assignment, but this also made possible the case where pending_sort is never reset.

This change sets pending_sort back to false in _sort_children() whether or not it's in the tree.  Since this is done in a deferred call, it should still avoid the previous issue of multiple calls being queued at once on entering the tree.

Fixes #92971
2024-06-10 20:17:47 -04:00
..
aspect_ratio_container.cpp Add as_sortable_control() to unify Container checks 2024-05-08 11:45:52 +02:00
aspect_ratio_container.h
base_button.cpp [Scene] Add SceneStringNames::pressed 2024-05-14 15:51:28 +02:00
base_button.h Revert "Update Node::get_configuration_warnings signature" 2024-02-17 19:03:21 +01:00
box_container.cpp Add visibilty mode to as_sortable_control() 2024-06-03 20:01:31 +02:00
box_container.h Register theme properties with ThemeDB 2023-09-11 13:45:23 +02:00
button.cpp Improve button min. size calculation. 2024-05-16 22:37:12 +03:00
button.h Fix CheckBox and CheckButton not using max_icon_width 2024-05-20 10:40:21 +02:00
center_container.cpp Add as_sortable_control() to unify Container checks 2024-05-08 11:45:52 +02:00
center_container.h
check_box.cpp Fix CheckBox and CheckButton not using max_icon_width 2024-05-20 10:40:21 +02:00
check_box.h Register theme properties with ThemeDB 2023-09-11 13:45:23 +02:00
check_button.cpp Fix CheckBox and CheckButton not using max_icon_width 2024-05-20 10:40:21 +02:00
check_button.h Register theme properties with ThemeDB 2023-09-11 13:45:23 +02:00
code_edit.compat.inc Fix some DEFVALs to use the right type 2024-02-23 01:50:18 +01:00
code_edit.cpp Fix crash during code editor folding and LSP 2024-05-23 20:01:11 -07:00
code_edit.h Overhaul multiple caret editing in TextEdit. 2024-04-26 14:26:10 -04:00
color_mode.cpp Bind remaining theme properties to their respective classes 2023-09-13 19:31:35 +02:00
color_mode.h Increase precision of RAW mode in ColorPicker 2023-10-23 18:33:56 +02:00
color_picker.cpp [Scene] Add SceneStringNames::panel 2024-05-30 22:54:50 +02:00
color_picker.h Fixed undo/redo behaviour of color picker and added ability to cancel/confirm color selection. 2024-03-24 15:12:11 -05:00
color_rect.cpp
color_rect.h
container.cpp Fix Container::pending_sort tracking 2024-06-10 20:17:47 -04:00
container.h Add visibilty mode to as_sortable_control() 2024-06-03 20:01:31 +02:00
control.compat.inc Fix some DEFVALs to use the right type 2024-02-23 01:50:18 +01:00
control.cpp Invalidate Control global transform before notifying about resize / rect change 2024-05-30 10:10:24 +02:00
control.h Avoid incorrect computing anchor of Control node when reset on save 2024-05-05 08:33:37 +09:00
dialogs.compat.inc Fix some AcceptDialog argument types 2024-03-12 14:33:43 +01:00
dialogs.cpp [Scene] Add SceneStringNames::panel 2024-05-30 22:54:50 +02:00
dialogs.h Fix duplicate AcceptDialog cancel/confirm events. 2024-05-28 10:46:28 +03:00
file_dialog.cpp Fix native file dialogs being shown on set_visible(false) 2024-06-09 17:54:18 +03:00
file_dialog.h Automatically use property count in PropertyListHelper 2024-05-25 10:51:37 +02:00
flow_container.cpp Add as_sortable_control() to unify Container checks 2024-05-08 11:45:52 +02:00
flow_container.h Add FlowContainer wrap options for center alignment. 2024-04-29 08:26:45 -05:00
graph_edit.compat.inc Rework GraphEdit connections (drawing, API, optimizations) 2024-01-18 16:53:15 +01:00
graph_edit.cpp [Scene] Add SceneStringNames::panel 2024-05-30 22:54:50 +02:00
graph_edit.h [GraphEdit] Convert to minimap line after getting connection line. 2024-05-29 12:58:51 +08:00
graph_edit_arranger.cpp [Core] Add scalar versions of Vector* min/max/clamp/snap(ped) 2024-05-02 10:31:13 +02:00
graph_edit_arranger.h Add const lvalue ref to container parameters 2024-01-05 14:49:57 -03:00
graph_element.cpp Add visibilty mode to as_sortable_control() 2024-06-03 20:01:31 +02:00
graph_element.h Bind remaining theme properties to their respective classes 2023-09-13 19:31:35 +02:00
graph_frame.cpp Add as_sortable_control() to unify Container checks 2024-05-08 11:45:52 +02:00
graph_frame.h Add GraphFrame and integrate it in VisualShader 2024-04-04 15:11:00 +02:00
graph_node.cpp Add visibilty mode to as_sortable_control() 2024-06-03 20:01:31 +02:00
graph_node.h [VisualShader] Add reroute node and improve port drawing 2024-05-13 03:26:01 +02:00
grid_container.cpp Add as_sortable_control() to unify Container checks 2024-05-08 11:45:52 +02:00
grid_container.h Bind remaining theme properties to their respective classes 2023-09-13 19:31:35 +02:00
item_list.cpp Fix Huge .tscn Icon and icon in background of File System panel 2024-06-02 09:11:56 -04:00
item_list.h Fix Huge .tscn Icon and icon in background of File System panel 2024-06-02 09:11:56 -04:00
label.cpp [Label] Move shadow drawing into a separate draw step. 2024-03-15 11:24:08 +02:00
label.h [Label] Move shadow drawing into a separate draw step. 2024-03-15 11:24:08 +02:00
line_edit.cpp Fix IME activation in subviewports. 2024-06-04 00:03:02 +03:00
line_edit.h Revert "Update Node::get_configuration_warnings signature" 2024-02-17 19:03:21 +01:00
link_button.cpp Merge pull request #80555 from GrammAcc/fix-80507 2023-10-02 15:18:38 +02:00
link_button.h Merge pull request #80555 from GrammAcc/fix-80507 2023-10-02 15:18:38 +02:00
margin_container.cpp Add visibilty mode to as_sortable_control() 2024-06-03 20:01:31 +02:00
margin_container.h Bind remaining theme properties to their respective classes 2023-09-13 19:31:35 +02:00
menu_bar.cpp [MenuBar] Use NativeMenu RIDs instead of indices to track items. 2024-03-25 10:58:05 +02:00
menu_bar.h [MenuBar] Use NativeMenu RIDs instead of indices to track items. 2024-03-25 10:58:05 +02:00
menu_button.cpp Fix PropertyListHelper::_get_property returning a valid value even if an index is outside the array valid indices 2024-05-10 10:46:04 +02:00
menu_button.h Automatically use property count in PropertyListHelper 2024-05-25 10:51:37 +02:00
nine_patch_rect.cpp Use Core/Scene stringnames consistently 2024-05-13 23:41:07 +02:00
nine_patch_rect.h Make NinePatchRect listen to texture changes 2023-06-20 08:40:35 +02:00
option_button.cpp Improve button min. size calculation. 2024-05-16 22:37:12 +03:00
option_button.h Automatically use property count in PropertyListHelper 2024-05-25 10:51:37 +02:00
panel.cpp Register theme properties with ThemeDB 2023-09-11 13:45:23 +02:00
panel.h Register theme properties with ThemeDB 2023-09-11 13:45:23 +02:00
panel_container.cpp Add visibilty mode to as_sortable_control() 2024-06-03 20:01:31 +02:00
panel_container.h Register theme properties with ThemeDB 2023-09-11 13:45:23 +02:00
popup.cpp [Scene] Add SceneStringNames::panel 2024-05-30 22:54:50 +02:00
popup.h Make handling of rename line-edit popups more robust 2024-05-07 14:29:35 +02:00
popup_menu.compat.inc Move global_menu_* methods to a separate NativeMenu class. 2024-03-04 23:41:41 +02:00
popup_menu.cpp [Scene] Add SceneStringNames::panel 2024-05-30 22:54:50 +02:00
popup_menu.h Automatically use property count in PropertyListHelper 2024-05-25 10:51:37 +02:00
progress_bar.cpp [Core] Add scalar versions of Vector* min/max/clamp/snap(ped) 2024-05-02 10:31:13 +02:00
progress_bar.h Add indeterminate mode to ProgressBar 2024-01-31 18:11:18 -03:00
range.cpp Use Core/Scene stringnames consistently 2024-05-13 23:41:07 +02:00
range.h Revert "Update Node::get_configuration_warnings signature" 2024-02-17 19:03:21 +01:00
reference_rect.cpp
reference_rect.h
rich_text_effect.cpp Add transform support to CharFXTransform 2023-08-23 00:18:37 -05:00
rich_text_effect.h Merge pull request #77819 from 0xafbf/char-fx-tests 2023-09-26 13:44:28 +02:00
rich_text_label.compat.inc [RTL] Adds extra argument to remove_paragraph to skip cache invalidation and a method for manual cache invalidation. 2024-05-02 14:03:21 +03:00
rich_text_label.cpp [RTL] Fix nested ordered lists inside unordered lists. 2024-06-04 08:08:16 +03:00
rich_text_label.h Fix RichTextLabel table overlapping with next line 2024-05-31 16:21:17 -04:00
scroll_bar.cpp Use Core/Scene stringnames consistently 2024-05-13 23:41:07 +02:00
scroll_bar.h Enabled 'Scrolling' signal when scrolling with middle mouse on RichTextLabel/ScrollContainer 2024-04-22 20:44:03 +01:00
scroll_container.cpp Add visibilty mode to as_sortable_control() 2024-06-03 20:01:31 +02:00
scroll_container.h Revert "Update Node::get_configuration_warnings signature" 2024-02-17 19:03:21 +01:00
SCsub
separator.cpp Register theme properties with ThemeDB 2023-09-11 13:45:23 +02:00
separator.h Register theme properties with ThemeDB 2023-09-11 13:45:23 +02:00
slider.cpp Fix Slider's drag mouse position when grabber is centered 2024-02-07 17:19:13 +00:00
slider.h Emit slider's drag_started signal before the first value change 2023-12-21 11:23:35 +08:00
spin_box.cpp Use Core/Scene stringnames consistently 2024-05-13 23:41:07 +02:00
spin_box.h Fix spinBox will reset text when redrawing 2023-10-08 20:03:08 +08:00
split_container.cpp Use as_sortable_control() in SplitContainer 2024-05-08 13:17:34 -04:00
split_container.h Use as_sortable_control() in SplitContainer 2024-05-08 13:17:34 -04:00
subviewport_container.cpp Add range hint for SubViewportContainer.stretch_shrink 2024-05-29 09:03:15 +08:00
subviewport_container.h Revert "Update Node::get_configuration_warnings signature" 2024-02-17 19:03:21 +01:00
tab_bar.cpp Use Core/Scene stringnames consistently 2024-05-13 23:41:07 +02:00
tab_bar.h Automatically use property count in PropertyListHelper 2024-05-25 10:51:37 +02:00
tab_container.cpp Add visibilty mode to as_sortable_control() 2024-06-03 20:01:31 +02:00
tab_container.h Allow setting icon max width for TabContainer 2024-04-26 08:27:27 +08:00
text_edit.compat.inc Overhaul multiple caret editing in TextEdit. 2024-04-26 14:26:10 -04:00
text_edit.cpp Merge pull request #92271 from kitbdev/fix-max-line-size 2024-06-07 23:29:28 +02:00
text_edit.h Overhaul multiple caret editing in TextEdit. 2024-04-26 14:26:10 -04:00
texture_button.cpp Fix TextureButton's click mask texture size ignored if missing normal texture 2024-05-25 15:40:09 +02:00
texture_button.h Make TextureButton and Button update on texture change 2023-05-29 16:40:56 +02:00
texture_progress_bar.cpp Replace find with contains/has where applicable 2024-05-08 12:37:42 +02:00
texture_progress_bar.h Hide ineffective TextureProgressBar properties in the editor 2023-11-15 18:35:54 +01:00
texture_rect.cpp Remove unnecessary validity checks from Button and TextureRect 2023-09-06 16:39:06 +02:00
texture_rect.h
tree.cpp [Scene] Add SceneStringNames::id_pressed 2024-05-30 22:54:04 +02:00
tree.h Fix Tree and FileSystemList edit popup double events and ESC behavior. 2024-05-17 10:03:52 +03:00
video_stream_player.cpp Use Core/Scene stringnames consistently 2024-05-13 23:41:07 +02:00
video_stream_player.h Replace internal usage of ImageTexture in VideoStreamPlayer for Texture2D 2024-01-24 23:44:46 +01:00
view_panner.cpp Merge pull request #85473 from miv391/fix-horizontal-mouse-wheeling-in-2d-view 2023-12-19 13:02:04 +01:00
view_panner.h Add vararg call() method to C++ Callable 2023-10-05 11:35:29 +02:00