1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 05:47:34 +00:00

FileManager: Use FileIconProvider in the properties dialog

This removes the need for the properties dialog to access the internal
data model used by the directory view.
This commit is contained in:
Andreas Kling 2020-08-12 19:29:02 +02:00
parent 3dd15da7b1
commit aae296ef08
3 changed files with 10 additions and 12 deletions

View file

@ -40,7 +40,7 @@ public:
virtual ~PropertiesDialog() override;
private:
PropertiesDialog(GUI::FileSystemModel&, String, bool disable_rename, Window* parent = nullptr);
PropertiesDialog(const String& path, bool disable_rename, Window* parent = nullptr);
struct PropertyValuePair {
String property;
@ -82,17 +82,16 @@ private:
void permission_changed(mode_t mask, bool set);
bool apply_changes();
void update();
String make_full_path(String name);
String make_full_path(const String& name);
GUI::FileSystemModel& m_model;
RefPtr<GUI::Button> m_apply_button;
RefPtr<GUI::TextBox> m_name_box;
RefPtr<GUI::ImageWidget> m_icon;
String m_name;
String m_parent_path;
String m_path;
mode_t m_mode;
mode_t m_old_mode;
mode_t m_mode { 0 };
mode_t m_old_mode { 0 };
bool m_permissions_dirty { false };
bool m_name_dirty { false };
};