Changeset View
Changeset View
Standalone View
Standalone View
solid-device-automounter/kcm/DeviceModel.h
Show First 20 Lines • Show All 51 Lines • ▼ Show 20 Line(s) | 34 | public: | |||
---|---|---|---|---|---|
52 | int rowCount(const QModelIndex &parent = QModelIndex()) const override; | 52 | int rowCount(const QModelIndex &parent = QModelIndex()) const override; | ||
53 | int columnCount(const QModelIndex &parent = QModelIndex()) const override; | 53 | int columnCount(const QModelIndex &parent = QModelIndex()) const override; | ||
54 | 54 | | |||
55 | QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const override; | 55 | QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const override; | ||
56 | QModelIndex parent(const QModelIndex &index) const override; | 56 | QModelIndex parent(const QModelIndex &index) const override; | ||
57 | 57 | | |||
58 | bool setData(const QModelIndex &index, const QVariant &value, int role = Qt::EditRole) override; | 58 | bool setData(const QModelIndex &index, const QVariant &value, int role = Qt::EditRole) override; | ||
59 | 59 | | |||
60 | void setAutomaticMountOnLogin(bool automaticLogin); | ||||
61 | void setAutomaticMountOnPlugin(bool automaticAttached); | ||||
62 | | ||||
60 | public slots: | 63 | public slots: | ||
61 | void forgetDevice(const QString &udi); | 64 | void forgetDevice(const QString &udi); | ||
62 | void reload(); | 65 | void reload(); | ||
63 | 66 | | |||
64 | private slots: | 67 | private slots: | ||
65 | void deviceAttached(const QString &udi); | 68 | void deviceAttached(const QString &udi); | ||
66 | void deviceRemoved(const QString &udi); | 69 | void deviceRemoved(const QString &udi); | ||
67 | 70 | | |||
68 | private: | 71 | private: | ||
69 | void addNewDevice(const QString &udi); | 72 | void addNewDevice(const QString &udi); | ||
70 | 73 | | |||
71 | QList<QString> m_attached; | 74 | QList<QString> m_attached; | ||
72 | QList<QString> m_disconnected; | 75 | QList<QString> m_disconnected; | ||
73 | QHash<QString, bool> m_loginForced; | 76 | QHash<QString, bool> m_loginForced; | ||
74 | QHash<QString, bool> m_attachedForced; | 77 | QHash<QString, bool> m_attachedForced; | ||
78 | bool m_automaticLogin; | ||||
79 | bool m_automaticAttached; | ||||
75 | }; | 80 | }; | ||
76 | 81 | | |||
77 | #endif | 82 | #endif |