| 498 | } |
| 499 | |
| 500 | void EditorDebuggerNode::_debugger_changed(int p_tab) { |
| 501 | remote_scene_tree_wait = false; |
| 502 | inspect_edited_object_wait = false; |
| 503 | |
| 504 | if (Object *robjs = InspectorDock::get_inspector_singleton()->get_edited_object()) { |
| 505 | if (Object::cast_to<EditorDebuggerRemoteObjects>(robjs)) { |
| 506 | // Clear inspected object, you can only inspect objects in selected debugger. |
| 507 | // Hopefully, in the future, we will have one inspector per debugger. |
| 508 | EditorNode::get_singleton()->push_item(nullptr); |
| 509 | } |
| 510 | } |
| 511 | |
| 512 | if (ScriptEditorDebugger *prev_debug = get_previous_debugger()) { |
| 513 | prev_debug->clear_inspector(); |
| 514 | _text_editor_stack_clear(prev_debug); |
| 515 | } |
| 516 | if (remote_scene_tree->is_visible_in_tree()) { |
| 517 | get_current_debugger()->request_remote_tree(); |
| 518 | } |
| 519 | if (get_current_debugger()->is_breaked()) { |
| 520 | _text_editor_stack_goto(get_current_debugger()); |
| 521 | } |
| 522 | |
| 523 | _break_state_changed(); |
| 524 | } |
| 525 | |
| 526 | void EditorDebuggerNode::_debug_data(const String &p_msg, const Array &p_data, int p_debugger) { |
| 527 | if (p_debugger != tabs->get_current_tab()) { |
nothing calls this directly
no test coverage detected