diff options
Diffstat (limited to 'Userland/Libraries/LibGUI/FileSystemModel.cpp')
-rw-r--r-- | Userland/Libraries/LibGUI/FileSystemModel.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Userland/Libraries/LibGUI/FileSystemModel.cpp b/Userland/Libraries/LibGUI/FileSystemModel.cpp index cb4b437030..bede6e23ec 100644 --- a/Userland/Libraries/LibGUI/FileSystemModel.cpp +++ b/Userland/Libraries/LibGUI/FileSystemModel.cpp @@ -711,10 +711,12 @@ String FileSystemModel::column_name(int column) const bool FileSystemModel::accepts_drag(ModelIndex const& index, Vector<String> const& mime_types) const { - if (!index.is_valid()) - return false; if (!mime_types.contains_slow("text/uri-list")) return false; + + if (!index.is_valid()) + return true; + auto& node = this->node(index); return node.is_directory(); } |