Salome HOME
V2008a - invoking cmake from configure and remaining plugins
[modules/paravis.git] / src / Plugins / ToolBar / MyToolBarActions.cxx
1
2
3 #include "MyToolBarActions.h"
4
5 #include <QApplication>
6 #include <QStyle>
7 #include <QMessageBox>
8
9 MyToolBarActions::MyToolBarActions(QObject* p)
10   : QActionGroup(p)
11 {
12   QIcon icon = qApp->style()->standardIcon(QStyle::SP_MessageBoxCritical);
13
14   QAction* a = this->addAction(new QAction(icon, "MyAction", this));
15   QObject::connect(a, SIGNAL(triggered(bool)), this, SLOT(onAction()));
16 }
17
18 MyToolBarActions::~MyToolBarActions()
19 {
20 }
21
22 void MyToolBarActions::onAction()
23 {
24   QMessageBox::information(NULL, "MyAction", "MyAction was invoked\n");
25 }
26