diff options
author | jaseg <git-bigdata-wsl-arch@jaseg.de> | 2020-08-09 17:12:14 +0200 |
---|---|---|
committer | jaseg <git-bigdata-wsl-arch@jaseg.de> | 2020-08-09 17:12:14 +0200 |
commit | 0afe9ca6bf53da111e445d2aea7cfc94e7e3c601 (patch) | |
tree | dba69d8eb86e81a1a56a388eafa85817762cf87f /tagscene.h | |
parent | 872bb95acf6fabd639da57cd41a4844d7e6dd0f0 (diff) | |
download | numberator-0afe9ca6bf53da111e445d2aea7cfc94e7e3c601.tar.gz numberator-0afe9ca6bf53da111e445d2aea7cfc94e7e3c601.tar.bz2 numberator-0afe9ca6bf53da111e445d2aea7cfc94e7e3c601.zip |
db backend: mostly feature-complete
Diffstat (limited to 'tagscene.h')
-rw-r--r-- | tagscene.h | 30 |
1 files changed, 29 insertions, 1 deletions
@@ -1,14 +1,42 @@ #ifndef TAGSCENE_H #define TAGSCENE_H +#include "sqlitebackend.h" +#include "tagitem.h" + +#include <QGraphicsPixmapItem> #include <QGraphicsScene> class TagScene : public QGraphicsScene { + Q_OBJECT + public: - TagScene(); + TagScene(SQLiteSaveFile &proj); + +public slots: + void reloadPicture(); + void reloadTags(); + +signals: + void tagDoubleClicked(const Tag &tag); + +protected: + void mouseDoubleClickEvent(QGraphicsSceneMouseEvent *event) override; + +private slots: + void tagChanged(TagChange change, const Tag &tag); + +private: + void addTag(const Tag tag); + + SQLiteSaveFile &proj; + + QGraphicsPixmapItem *pix_it; + QPixmap pix; + QMap<long long int, TagItem*> tags; }; #endif // TAGSCENE_H |