From 6f7967e0e0e37926ff2e7fcc31f615567f31286d Mon Sep 17 00:00:00 2001 From: Tomaz Canabrava Date: Wed, 15 Jan 2014 13:04:01 -0200 Subject: Added a Context menu so we can test the state switching. The context menu added here should only be temporary, it's an easy and simple way to test the transitions of the items on screen. They seem a bit broken atm, I'll try to fix that. :) Signed-off-by: Tomaz Canabrava Signed-off-by: Dirk Hohndel --- qt-ui/profile/profilewidget2.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'qt-ui') diff --git a/qt-ui/profile/profilewidget2.cpp b/qt-ui/profile/profilewidget2.cpp index f052c88c8..e2c2b96aa 100644 --- a/qt-ui/profile/profilewidget2.cpp +++ b/qt-ui/profile/profilewidget2.cpp @@ -9,6 +9,8 @@ #include #include #include +#include +#include ProfileWidget2::ProfileWidget2(QWidget *parent) : QGraphicsView(parent), @@ -216,7 +218,14 @@ void ProfileWidget2::settingsChanged() void ProfileWidget2::contextMenuEvent(QContextMenuEvent* event) { - + // this menu should be completely replaced when things are working. + QMenu m; + m.addAction("Set Empty", this, SIGNAL(startEmptyState())); + m.addAction("Set Profile", this, SIGNAL(startProfileState())); + m.addAction("Set Add", this, SIGNAL(startAddState())); + m.addAction("Set Edit", this, SIGNAL(startEditState())); + m.addAction("Set Plan", this, SIGNAL(startPlanState())); + m.exec(event->globalPos()); } void ProfileWidget2::resizeEvent(QResizeEvent* event) -- cgit v1.2.3-70-g09d2