Commit 805e952c authored by Emmanuel Promayon's avatar Emmanuel Promayon

NEW show an information dialog about the view menu

This is only valid for imp and will only show the dialog once
(first call)
parent d8c8397f
......@@ -25,12 +25,9 @@
#include "SwitchViewer.h"
#include <BitmapViewer.h>
#include <Application.h>
#include <MainWindow.h>
#include <MedicalImageViewer.h>
#include <ImageComponent.h>
#include <QColor>
#include <QMessageBox>
using namespace camitk;
......@@ -44,6 +41,8 @@ SwitchViewer::SwitchViewer(ActionExtension* extension) : Action(extension) {
setFamily("Tutorial");
addTag("Viewer");
addTag("MainWindow");
firstCall = true;
}
// --------------- getWidget -------------------
......@@ -55,5 +54,9 @@ QWidget* SwitchViewer::getWidget() {
Action::ApplyStatus SwitchViewer::apply() {
// just ask the BitMap viewer to switch the central viewer
BitmapViewer::getInstance()->switchCentralViewer();
if (firstCall) {
QMessageBox::information(nullptr,"Switch Viewer From the Menu", "The next time you can also use the \"View Menu\" item \"Toggle Central Viewers\" to switch the central viewer from/to the Medical Image Viewer");
firstCall = false;
}
return SUCCESS;
}
......@@ -52,6 +52,7 @@ public slots:
/// method called when the action is applied
virtual ApplyStatus apply();
bool firstCall;
};
#endif // SWITCH_VIEWER_H
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment