mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-10 18:10:56 +09:00
HackStudio: Detection of externally deleted files
HackStudio can now detect that files that have been opened in it were deleted. When this occurs, it will update the list of open files and reasign a file to the editors that showed the deleted file before the deletion. The new file is either another file that was opened or the default editor is no other open file is available Closes SerenityOS#6632
This commit is contained in:
parent
a6201f708e
commit
56fc949646
Notes:
sideshowbarker
2024-07-18 18:49:39 +09:00
Author: https://github.com/iCristalrope
Commit: 56fc949646
Pull-request: https://github.com/SerenityOS/serenity/pull/6708
Issue: https://github.com/SerenityOS/serenity/issues/6632
Reviewed-by: https://github.com/awesomekling
Reviewed-by: https://github.com/itamar8910 ✅
2 changed files with 50 additions and 1 deletions
|
@ -93,6 +93,8 @@ private:
|
|||
void reveal_action_tab(GUI::Widget&);
|
||||
void initialize_debugger();
|
||||
|
||||
void handle_external_file_deletion(const String& filepath);
|
||||
|
||||
void create_open_files_view(GUI::Widget& parent);
|
||||
void create_form_editor(GUI::Widget& parent);
|
||||
void create_toolbar(GUI::Widget& parent);
|
||||
|
@ -118,7 +120,8 @@ private:
|
|||
String m_currently_open_file;
|
||||
|
||||
HashMap<String, NonnullRefPtr<ProjectFile>> m_open_files;
|
||||
Vector<String> m_open_files_vector; // NOTE: This contains the keys from m_open_files
|
||||
HashMap<String, NonnullRefPtr<Core::FileWatcher>> m_file_watchers;
|
||||
Vector<String> m_open_files_vector; // NOTE: This contains the keys from m_open_files and m_file_watchers
|
||||
|
||||
OwnPtr<Project> m_project;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue