| 3151 | } |
| 3152 | |
| 3153 | void ScriptEditor::_file_removed(const String &p_removed_file) { |
| 3154 | for (int i = 0; i < tab_container->get_tab_count(); i++) { |
| 3155 | ScriptEditorBase *se = Object::cast_to<ScriptEditorBase>(tab_container->get_tab_control(i)); |
| 3156 | if (!se) { |
| 3157 | continue; |
| 3158 | } |
| 3159 | if (se->edited_file_data.path == p_removed_file) { |
| 3160 | // The script is deleted with no undo, so just close the tab. |
| 3161 | _close_tab(i, false, false); |
| 3162 | } |
| 3163 | } |
| 3164 | |
| 3165 | // Check closed. |
| 3166 | if (script_editor_cache->has_section(p_removed_file)) { |
| 3167 | Array breakpoints = _get_cached_breakpoints_for_script(p_removed_file); |
| 3168 | for (int breakpoint : breakpoints) { |
| 3169 | EditorDebuggerNode::get_singleton()->set_breakpoint(p_removed_file, (int)breakpoint + 1, false); |
| 3170 | } |
| 3171 | script_editor_cache->erase_section(p_removed_file); |
| 3172 | } |
| 3173 | } |
| 3174 | |
| 3175 | void ScriptEditor::_update_find_replace_bar() { |
| 3176 | ScriptEditorBase *se = _get_current_editor(); |
nothing calls this directly
no test coverage detected