diff options
Diffstat (limited to 'Applications/FileManager')
-rw-r--r-- | Applications/FileManager/PropertiesDialog.cpp | 4 | ||||
-rw-r--r-- | Applications/FileManager/PropertiesDialog.h | 2 | ||||
-rw-r--r-- | Applications/FileManager/main.cpp | 6 |
3 files changed, 6 insertions, 6 deletions
diff --git a/Applications/FileManager/PropertiesDialog.cpp b/Applications/FileManager/PropertiesDialog.cpp index 3f3c09be4d..8101c52539 100644 --- a/Applications/FileManager/PropertiesDialog.cpp +++ b/Applications/FileManager/PropertiesDialog.cpp @@ -36,8 +36,8 @@ #include <stdio.h> #include <unistd.h> -PropertiesDialog::PropertiesDialog(GUI::FileSystemModel& model, String path, bool disable_rename, Core::Object* parent) - : Dialog(parent) +PropertiesDialog::PropertiesDialog(GUI::FileSystemModel& model, String path, bool disable_rename, Window* parent_window) + : Dialog(parent_window) , m_model(model) { auto file_path = FileSystemPath(path); diff --git a/Applications/FileManager/PropertiesDialog.h b/Applications/FileManager/PropertiesDialog.h index 08f2969894..69e23a820f 100644 --- a/Applications/FileManager/PropertiesDialog.h +++ b/Applications/FileManager/PropertiesDialog.h @@ -40,7 +40,7 @@ public: virtual ~PropertiesDialog() override; private: - PropertiesDialog(GUI::FileSystemModel&, String, bool disable_rename, Core::Object* parent = nullptr); + PropertiesDialog(GUI::FileSystemModel&, String, bool disable_rename, Window* parent = nullptr); struct PropertyValuePair { String property; diff --git a/Applications/FileManager/main.cpp b/Applications/FileManager/main.cpp index bc96ca6735..d035abef55 100644 --- a/Applications/FileManager/main.cpp +++ b/Applications/FileManager/main.cpp @@ -171,12 +171,12 @@ int main(int argc, char** argv) }); auto mkdir_action = GUI::Action::create("New directory...", { Mod_Ctrl | Mod_Shift, Key_N }, Gfx::Bitmap::load_from_file("/res/icons/16x16/mkdir.png"), [&](const GUI::Action&) { - auto& input_box = window->add<GUI::InputBox>("Enter name:", "New directory"); - if (input_box.exec() == GUI::InputBox::ExecOK && !input_box.text_value().is_empty()) { + auto input_box = GUI::InputBox::construct("Enter name:", "New directory", window); + if (input_box->exec() == GUI::InputBox::ExecOK && !input_box->text_value().is_empty()) { auto new_dir_path = canonicalized_path( String::format("%s/%s", directory_view.path().characters(), - input_box.text_value().characters())); + input_box->text_value().characters())); int rc = mkdir(new_dir_path.characters(), 0777); if (rc < 0) { GUI::MessageBox::show(String::format("mkdir(\"%s\") failed: %s", new_dir_path.characters(), strerror(errno)), "Error", GUI::MessageBox::Type::Error, GUI::MessageBox::InputType::OK, window); |