aboutsummaryrefslogtreecommitdiffstats
path: root/ClickableLabel.h
diff options
context:
space:
mode:
authorScott Murray <scott.murray@konsulko.com>2019-08-30 11:43:58 -0400
committerScott Murray <scott.murray@konsulko.com>2019-08-30 11:45:55 -0400
commitededa7e3ef24a8cea9e513fa008ef481c1675457 (patch)
tree86a4c79d066b9638b11c0f127ad8f3c66c38c4f7 /ClickableLabel.h
parent706ad73eb02caf8532deaf5d38995bd258725cb8 (diff)
Initial check in
Initial check in of the original repository: git://github.com/AGLExport/genivi-navi-yelp-client.git as of commit c2691cb265d9198542482a860f1df378e8c2708b. Bug-AGL: SPEC-2787 Signed-off-by: Scott Murray <scott.murray@konsulko.com> Change-Id: I7405367387622fb788a5712ed24005ee6d7ce495
Diffstat (limited to 'ClickableLabel.h')
-rw-r--r--ClickableLabel.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/ClickableLabel.h b/ClickableLabel.h
new file mode 100644
index 0000000..86d39e8
--- /dev/null
+++ b/ClickableLabel.h
@@ -0,0 +1,23 @@
+#ifndef __CLICKABLE_LABEL_H__
+#define __CLICKABLE_LABEL_H__
+
+#include <QLabel>
+#include <QWidget>
+#include <QString>
+
+class ClickableLabel : public QLabel
+{
+ Q_OBJECT
+ public:
+ ClickableLabel(const QString& text="", QWidget* parent=0 ):QLabel(parent)
+ {
+ setText(text);
+ }
+ ~ClickableLabel(){}
+ signals:
+ void clicked();
+ protected:
+ void mouseReleaseEvent(QMouseEvent* event) { emit clicked(); }
+};
+
+#endif // __CLICKABLE_LABEL_H__