godot/editor/debugger
Rémi Verschelde fd6453c45e Revert "Remove NOTIFICATION_ENTER_TREE when paired with NOTIFICATION_THEME_CHANGED"
This reverts commit 4b817a565c.

Fixes #64988.
Fixes #64997.

This caused several regressions (#64988, #64997,
https://github.com/godotengine/godot/issues/64997#issuecomment-1229970605)
which point at a flaw in the current logic:

- `Control::NOTIFICATION_ENTER_TREE` triggers a *deferred* notification with
  `NOTIFCATION_THEME_CHANGED` as introduced in #62845.
- Some classes use their `THEME_CHANGED` to cache theme items in
  member variables (e.g. `style_normal`, etc.), and use those member
  variables in `ENTER_TREE`, `READY`, `DRAW`, etc. Since the `THEME_CHANGE`
  notification is now deferred, they end up accessing invalid state and this
  can lead to not applying theme properly (e.g. for EditorHelp) or crashing
  (e.g. for EditorLog or CodeEdit).

So we need to go back to the drawing board and see if `THEME_CHANGED` can be
called earlier so that the previous logic still works?

Or can we refactor all engine code to make sure that:
- `ENTER_TREE` and similar do not depend on theme properties cached in member
  variables.
- Or `THEME_CHANGE` does trigger a general UI update to make sure that any
  bad theme handling in `ENTER_TREE` and co. gets fixed when `THEME_CHANGE`
  does arrive for the first time. But that means having a temporary invalid
  (and possibly still crashing) state, and doing some computations twice
  which might be heavy (e.g. `EditorHelp::_update_doc()`).
2022-08-29 11:11:29 +02:00
..
debug_adapter Extract EditorResourceConversionPlugin into its own source files and clean up editor includes 2022-07-31 21:14:15 +03:00
editor_debugger_inspector.cpp Disable editing properties in foreign resources 2022-08-23 23:16:13 +01:00
editor_debugger_inspector.h Disable editing properties in foreign resources 2022-08-23 23:16:13 +01:00
editor_debugger_node.cpp Add per-scene UndoRedo 2022-08-22 18:05:10 +02:00
editor_debugger_node.h Add per-scene UndoRedo 2022-08-22 18:05:10 +02:00
editor_debugger_server.cpp Replace most uses of Map by HashMap 2022-05-16 10:37:48 +02:00
editor_debugger_server.h Code quality: Fix header guards consistency 2022-07-25 11:17:40 +02:00
editor_debugger_tree.cpp Add node path drag from remote tree 2022-07-31 18:24:56 +02:00
editor_debugger_tree.h Add node path drag from remote tree 2022-07-31 18:24:56 +02:00
editor_network_profiler.cpp Revert "Remove NOTIFICATION_ENTER_TREE when paired with NOTIFICATION_THEME_CHANGED" 2022-08-29 11:11:29 +02:00
editor_network_profiler.h Code quality: Fix header guards consistency 2022-07-25 11:17:40 +02:00
editor_performance_profiler.cpp Rename Control PRESET_WIDE to PRESET_FULL_RECT 2022-07-18 20:08:11 -05:00
editor_performance_profiler.h Replace most uses of Map by HashMap 2022-05-16 10:37:48 +02:00
editor_profiler.cpp Revert "Remove NOTIFICATION_ENTER_TREE when paired with NOTIFICATION_THEME_CHANGED" 2022-08-29 11:11:29 +02:00
editor_profiler.h Code quality: Fix header guards consistency 2022-07-25 11:17:40 +02:00
editor_visual_profiler.cpp Revert "Remove NOTIFICATION_ENTER_TREE when paired with NOTIFICATION_THEME_CHANGED" 2022-08-29 11:11:29 +02:00
editor_visual_profiler.h Code quality: Fix header guards consistency 2022-07-25 11:17:40 +02:00
script_editor_debugger.cpp Revert "Remove NOTIFICATION_ENTER_TREE when paired with NOTIFICATION_THEME_CHANGED" 2022-08-29 11:11:29 +02:00
script_editor_debugger.h Add the button pressed to some signals in Tree 2022-05-21 17:16:52 +02:00
SCsub Implemented initial DAP support 2021-08-02 10:43:35 +01:00