diff options
author | Antti Hölttä <AHoelttae@luxoft.com> | 2018-07-23 14:53:11 +0200 |
---|---|---|
committer | Antti Hölttä <AHoelttae@luxoft.com> | 2019-03-18 16:29:30 +0100 |
commit | ffd151ecf3971fd8601d8b1d4e2f04fb5793e364 (patch) | |
tree | cd3b947f04781d59bc61306dd34ef15f8c3a24fd /plugin/itemregister.h |
Initial commit, demoable poc
Sort of working with 4 dir navigation, check demoapp
Diffstat (limited to 'plugin/itemregister.h')
-rw-r--r-- | plugin/itemregister.h | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/plugin/itemregister.h b/plugin/itemregister.h new file mode 100644 index 0000000..479bca7 --- /dev/null +++ b/plugin/itemregister.h @@ -0,0 +1,30 @@ +#ifndef ITEMREGISTER_H +#define ITEMREGISTER_H + +#include <QObject> + +class QQuickItem; + +//keeps track of items that are cursor navigable +class ItemRegister : public QObject +{ + Q_OBJECT + +public: + ItemRegister(); + + void registerItem(QQuickItem* item); + void unregisterItem(QQuickItem* item); + + const QList<QQuickItem*> items() const; + +private Q_SLOTS: + void onItemDestroyed(QObject *obj); + +private: + //for now the data structure is just a list. could be replaced with something more efficient for the final purpose + QList<QQuickItem*> m_items; + +}; + +#endif // ITEMREGISTER_H |