diff options
author | Karol Kosek <krkk@krkk.ct8.pl> | 2021-07-13 18:45:01 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-07-13 21:16:44 +0200 |
commit | 5c89305fc6fce3aeb50725341b95caa8e8da7e5c (patch) | |
tree | ef9821694efa872de86fc26c02922ed77284a018 /Userland | |
parent | f09e361eefcbb7c7aeaae0255b9fbb5aa6e5b2db (diff) | |
download | serenity-5c89305fc6fce3aeb50725341b95caa8e8da7e5c.zip |
LibGUI: Don't clear textbox on save mode in FilePicker
This fixes a rather frustrating issue during saving a file,
when clicking on a folder (to change the path of saved file)
caused the filename to disappear from the text box.
Diffstat (limited to 'Userland')
-rw-r--r-- | Userland/Libraries/LibGUI/FilePicker.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Libraries/LibGUI/FilePicker.cpp b/Userland/Libraries/LibGUI/FilePicker.cpp index 5830155ee3..f71b6bb611 100644 --- a/Userland/Libraries/LibGUI/FilePicker.cpp +++ b/Userland/Libraries/LibGUI/FilePicker.cpp @@ -165,7 +165,7 @@ FilePicker::FilePicker(Window* parent_window, Mode mode, const StringView& filen auto should_open_folder = m_mode == Mode::OpenFolder; if (should_open_folder == node.is_directory()) { m_filename_textbox->set_text(node.name); - } else { + } else if (m_mode != Mode::Save) { m_filename_textbox->clear(); } }; |