|
@@ -13,10 +13,13 @@
|
|
#include <LibGUI/GTextBox.h>
|
|
#include <LibGUI/GTextBox.h>
|
|
#include <LibGUI/GToolBar.h>
|
|
#include <LibGUI/GToolBar.h>
|
|
|
|
|
|
-Optional<String> GFilePicker::get_open_filepath()
|
|
|
|
|
|
+Optional<String> GFilePicker::get_open_filepath(const String& window_title)
|
|
{
|
|
{
|
|
auto picker = GFilePicker::construct(Mode::Open);
|
|
auto picker = GFilePicker::construct(Mode::Open);
|
|
|
|
|
|
|
|
+ if (!window_title.is_null())
|
|
|
|
+ picker->set_title(window_title);
|
|
|
|
+
|
|
if (picker->exec() == GDialog::ExecOK) {
|
|
if (picker->exec() == GDialog::ExecOK) {
|
|
String file_path = picker->selected_file().string();
|
|
String file_path = picker->selected_file().string();
|
|
|
|
|