35 QML_UNCREATABLE(
"Can only access Job via JobDetailsRole of JobsModel")
40 Q_PROPERTY(
QString summary READ summary NOTIFY summaryChanged)
46 Q_PROPERTY(
QString text READ text NOTIFY textChanged)
51 Q_PROPERTY(
QString desktopEntry READ desktopEntry CONSTANT)
55 Q_PROPERTY(
QString applicationName READ applicationName CONSTANT)
59 Q_PROPERTY(
QString applicationIconName READ applicationIconName CONSTANT)
63 Q_PROPERTY(
Notifications::JobState state READ state NOTIFY stateChanged)
67 Q_PROPERTY(
int percentage READ percentage NOTIFY percentageChanged)
71 Q_PROPERTY(
int error READ error NOTIFY errorChanged)
78 Q_PROPERTY(
bool suspendable READ suspendable CONSTANT)
84 Q_PROPERTY(
bool killable READ killable CONSTANT)
89 Q_PROPERTY(
QUrl destUrl READ destUrl NOTIFY destUrlChanged)
94 Q_PROPERTY(qulonglong speed READ speed NOTIFY speedChanged)
96 Q_PROPERTY(qulonglong processedBytes READ processedBytes NOTIFY processedBytesChanged)
97 Q_PROPERTY(qulonglong processedFiles READ processedFiles NOTIFY processedFilesChanged)
98 Q_PROPERTY(qulonglong processedDirectories READ processedDirectories NOTIFY processedDirectoriesChanged)
99 Q_PROPERTY(qulonglong processedItems READ processedItems NOTIFY processedItemsChanged)
101 Q_PROPERTY(qulonglong totalBytes READ totalBytes NOTIFY totalBytesChanged)
102 Q_PROPERTY(qulonglong totalFiles READ totalFiles NOTIFY totalFilesChanged)
103 Q_PROPERTY(qulonglong totalDirectories READ totalDirectories NOTIFY totalDirectoriesChanged)
104 Q_PROPERTY(qulonglong totalItems READ totalItems NOTIFY totalItemsChanged)
106 Q_PROPERTY(
QString descriptionLabel1 READ descriptionLabel1 NOTIFY descriptionLabel1Changed)
107 Q_PROPERTY(
QString descriptionValue1 READ descriptionValue1 NOTIFY descriptionValue1Changed)
109 Q_PROPERTY(
QString descriptionLabel2 READ descriptionLabel2 NOTIFY descriptionLabel2Changed)
110 Q_PROPERTY(
QString descriptionValue2 READ descriptionValue2 NOTIFY descriptionValue2Changed)
121 Q_PROPERTY(
bool hasDetails READ hasDetails NOTIFY hasDetailsChanged)
127 Q_PROPERTY(
QUrl descriptionUrl READ descriptionUrl NOTIFY descriptionUrlChanged)
130 explicit
Job(uint
id,
QObject *parent =
nullptr);
145 void setDesktopEntry(const
QString &desktopEntry);
147 QString applicationName() const;
149 void setApplicationName(const
QString &applicationName);
151 QString applicationIconName() const;
153 void setApplicationIconName(const
QString &applicationIconName);
158 int percentage() const;
161 void setError(
int error);
164 void setErrorText(const
QString &errorText);
166 bool suspendable() const;
168 void setSuspendable(
bool suspendable);
170 bool killable() const;
172 void setKillable(
bool killable);
174 bool transient() const;
175 void setTransient(
bool transient);
177 QUrl destUrl() const;
179 qulonglong speed() const;
181 qulonglong processedBytes() const;
182 qulonglong processedFiles() const;
183 qulonglong processedDirectories() const;
184 qulonglong processedItems() const;
186 qulonglong totalBytes() const;
187 qulonglong totalFiles() const;
188 qulonglong totalDirectories() const;
189 qulonglong totalItems() const;
191 QString descriptionLabel1() const;
192 QString descriptionValue1() const;
194 QString descriptionLabel2() const;
195 QString descriptionValue2() const;
197 bool hasDetails() const;
199 QUrl descriptionUrl() const;
201 bool expired() const;
202 void setExpired(
bool expired);
204 bool dismissed() const;
205 void setDismissed(
bool dismissed);
208 Q_INVOKABLE
void resume();
209 Q_INVOKABLE
void kill();
212 void updatedChanged();
213 void summaryChanged();
216 void percentageChanged(
int percentage);
217 void errorChanged(
int error);
218 void errorTextChanged(const
QString &errorText);
219 void destUrlChanged();
221 void processedBytesChanged();
222 void processedFilesChanged();
223 void processedDirectoriesChanged();
224 void processedItemsChanged();
225 void processedAmountChanged();
226 void totalBytesChanged();
227 void totalFilesChanged();
228 void totalDirectoriesChanged();
229 void totalItemsChanged();
230 void totalAmountChanged();
231 void descriptionLabel1Changed();
232 void descriptionValue1Changed();
233 void descriptionLabel2Changed();
234 void descriptionValue2Changed();
235 void descriptionUrlChanged();
236 void hasDetailsChanged();
237 void expiredChanged();
238 void dismissedChanged();
244 friend class JobsModelPrivate;