-
Notifications
You must be signed in to change notification settings - Fork 3.3k
/
keyitem.h
43 lines (33 loc) · 1.3 KB
/
keyitem.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#ifndef KEYITEM_H
#define KEYITEM_H
#include "treeitem.h"
#include "connections-tree/operations.h"
namespace ConnectionsTree {
class KeyItem : public TreeItem
{
public:
KeyItem(const QString& fullPath, unsigned short int dbIndex, QSharedPointer<Operations> operations, QWeakPointer<TreeItem> parent);
QString getDisplayName() const override;
QIcon getIcon() const override;
QList<QSharedPointer<TreeItem>> getAllChilds() const override;
uint childCount() const override;
QSharedPointer<TreeItem> child(uint row) const override;
QWeakPointer<TreeItem> parent() const override;
bool onClick(ParentView& treeView) override;
void onWheelClick(ParentView& treeView) override;
QSharedPointer<QMenu> getContextMenu(ParentView& treeView) override;
bool isLocked() const override;
bool isEnabled() const;
QString getFullPath() const;
int getDbIndex() const;
void setRemoved();
private:
QString m_fullPath;
unsigned short int m_dbIndex;
QSharedPointer<Operations> m_operations;
QWeakPointer<TreeItem> m_parent;
QSharedPointer<QObject> m_signalReciever;
bool m_removed;
};
}
#endif // KEYITEM_H