Changeset View
Changeset View
Standalone View
Standalone View
src/core/kconfigwatcher.h
Show First 20 Lines • Show All 43 Lines • ▼ Show 20 Line(s) | 42 | public: | |||
---|---|---|---|---|---|
44 | 44 | | |||
45 | /** | 45 | /** | ||
46 | * Instantiate a ConfigWatcher for a given config | 46 | * Instantiate a ConfigWatcher for a given config | ||
47 | * | 47 | * | ||
48 | * @note any additional config sources should be set before this point. | 48 | * @note any additional config sources should be set before this point. | ||
49 | */ | 49 | */ | ||
50 | static Ptr create(const KSharedConfig::Ptr &config); | 50 | static Ptr create(const KSharedConfig::Ptr &config); | ||
51 | 51 | | |||
52 | ~KConfigWatcher() override; | ||||
53 | | ||||
52 | Q_SIGNALS: | 54 | Q_SIGNALS: | ||
53 | /** | 55 | /** | ||
54 | * Emitted when a config group has changed | 56 | * Emitted when a config group has changed | ||
55 | * The config will be reloaded before this signal is emitted | 57 | * The config will be reloaded before this signal is emitted | ||
56 | * | 58 | * | ||
57 | * @arg group the config group that has changed | 59 | * @arg group the config group that has changed | ||
58 | * @arg names a list of entries that have changed within that group | 60 | * @arg names a list of entries that have changed within that group | ||
59 | */ | 61 | */ | ||
60 | void configChanged(const KConfigGroup &group, const QByteArrayList &names); | 62 | void configChanged(const KConfigGroup &group, const QByteArrayList &names); | ||
61 | 63 | | |||
62 | private Q_SLOTS: | 64 | private Q_SLOTS: | ||
63 | void onConfigChangeNotification(const QHash<QString, QByteArrayList> &changes); | 65 | void onConfigChangeNotification(const QHash<QString, QByteArrayList> &changes); | ||
64 | 66 | | |||
65 | private: | 67 | private: | ||
66 | KConfigWatcher(const KSharedConfig::Ptr &config); | 68 | KConfigWatcher(const KSharedConfig::Ptr &config); | ||
67 | Q_DISABLE_COPY(KConfigWatcher) | 69 | Q_DISABLE_COPY(KConfigWatcher) | ||
68 | KConfigWatcherPrivate *const d; | 70 | const QScopedPointer<KConfigWatcherPrivate> d; | ||
69 | }; | 71 | }; | ||
70 | 72 | | |||
71 | #endif | 73 | #endif |