mirror of
https://github.com/arcan1s/awesome-widgets.git
synced 2025-07-14 22:35:49 +00:00
refactor: split formatters and matchers into separated singleton classes (#166)
* split formatter into separated singleton classes * split data engine matchers to classes * nodiscard attribute for formatter methods * small refactoring in matchers * fix codefactor warnings * fix test building
This commit is contained in:
@ -20,6 +20,7 @@
|
||||
#include <QObject>
|
||||
|
||||
#include "extitemaggregator.h"
|
||||
#include "matchers/awpluginmatchersettings.h"
|
||||
|
||||
|
||||
class AWCustomKeysHelper;
|
||||
@ -38,8 +39,7 @@ class AWKeyOperations : public QObject
|
||||
public:
|
||||
explicit AWKeyOperations(QObject *_parent = nullptr);
|
||||
~AWKeyOperations() override = default;
|
||||
[[nodiscard]] QStringList devices(const QString &_type) const;
|
||||
[[nodiscard]] QHash<QString, QStringList> devices() const;
|
||||
[[nodiscard]] AWPluginMatcherSettings devices() const;
|
||||
void updateCache();
|
||||
// keys
|
||||
[[nodiscard]] QStringList dictKeys() const;
|
||||
@ -73,6 +73,6 @@ private:
|
||||
ExtItemAggregator<ExtUpgrade> *m_extUpgrade = nullptr;
|
||||
ExtItemAggregator<ExtWeather> *m_extWeather = nullptr;
|
||||
// variables
|
||||
QHash<QString, QStringList> m_devices;
|
||||
AWPluginMatcherSettings m_devices;
|
||||
QString m_pattern;
|
||||
};
|
||||
|
Reference in New Issue
Block a user