Changeset View
Changeset View
Standalone View
Standalone View
src/kauthexecutejob.h
Show All 16 Lines | |||||
17 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA . | 17 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA . | ||
18 | */ | 18 | */ | ||
19 | 19 | | |||
20 | #ifndef EXECUTE_JOB_H | 20 | #ifndef EXECUTE_JOB_H | ||
21 | #define EXECUTE_JOB_H | 21 | #define EXECUTE_JOB_H | ||
22 | 22 | | |||
23 | #include <kjob.h> | 23 | #include <kjob.h> | ||
24 | 24 | | |||
25 | #include <kauth_export.h> | 25 | #include <kauthcore_export.h> | ||
26 | 26 | | |||
27 | #include "kauthaction.h" | 27 | #include "kauthaction.h" | ||
28 | #include "kauthactionreply.h" | 28 | #include "kauthactionreply.h" | ||
29 | 29 | | |||
30 | namespace KAuth | 30 | namespace KAuth | ||
31 | { | 31 | { | ||
32 | 32 | | |||
33 | /** | 33 | /** | ||
34 | * @brief Job for executing an Action | 34 | * @brief Job for executing an Action | ||
35 | * | 35 | * | ||
36 | * To run the action synchonously use KJob::exec() and check the return code for | 36 | * To run the action synchonously use KJob::exec() and check the return code for | ||
37 | * success. | 37 | * success. | ||
38 | * | 38 | * | ||
39 | * For longer tasks connect KJob::result(KJob*) and any other signals such as | 39 | * For longer tasks connect KJob::result(KJob*) and any other signals such as | ||
40 | * percent(KJob*, unsigned long) and newData(const QVariantMap &) then run start(). | 40 | * percent(KJob*, unsigned long) and newData(const QVariantMap &) then run start(). | ||
41 | * | 41 | * | ||
42 | * To check for authentiation success or problems connect to | 42 | * To check for authentiation success or problems connect to | ||
43 | * statusChanged(KAuth::Action::AuthStatus status) signal. | 43 | * statusChanged(KAuth::Action::AuthStatus status) signal. | ||
44 | * | 44 | * | ||
45 | * Use data() to get the return result of the action. | 45 | * Use data() to get the return result of the action. | ||
46 | * | 46 | * | ||
47 | * @since 5.0 | 47 | * @since 5.0 | ||
48 | */ | 48 | */ | ||
49 | class KAUTH_EXPORT ExecuteJob : public KJob | 49 | class KAUTHCORE_EXPORT ExecuteJob : public KJob | ||
50 | { | 50 | { | ||
51 | Q_OBJECT | 51 | Q_OBJECT | ||
52 | 52 | | |||
53 | ExecuteJob(const KAuth::Action &action, KAuth::Action::ExecutionMode mode, QObject *parent); | 53 | ExecuteJob(const KAuth::Action &action, KAuth::Action::ExecutionMode mode, QObject *parent); | ||
54 | 54 | | |||
55 | friend class Action; | 55 | friend class Action; | ||
56 | 56 | | |||
57 | class Private; | 57 | class Private; | ||
▲ Show 20 Lines • Show All 81 Lines • Show Last 20 Lines |