HackStudio: Drop files to the selected editor

Previously, the files were opened in the current editor, instead of one
that received a drop event.
This commit is contained in:
Karol Kosek 2021-09-04 15:45:49 +02:00 committed by Andreas Kling
commit dcc9db48c5
Notes: sideshowbarker 2024-07-19 17:15:22 +09:00

View file

@ -357,6 +357,7 @@ void Editor::drop_event(GUI::DropEvent& event)
GUI::MessageBox::show(window(), "HackStudio can only open one file at a time!", "One at a time please!", GUI::MessageBox::Type::Error);
return;
}
set_current_editor_wrapper(static_cast<EditorWrapper*>(parent()));
open_file(urls.first().path());
}
}