Add full screen
This commit is contained in:
@@ -80,6 +80,7 @@ MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent)
|
|||||||
viewMenu->addAction(tr("Zoom Out"), m_imageGL, SLOT(zoomOut()), QKeySequence::ZoomOut);
|
viewMenu->addAction(tr("Zoom Out"), m_imageGL, SLOT(zoomOut()), QKeySequence::ZoomOut);
|
||||||
viewMenu->addAction(tr("Best Fit"), m_imageGL, SLOT(bestFit()), QKeySequence("Ctrl+1"));
|
viewMenu->addAction(tr("Best Fit"), m_imageGL, SLOT(bestFit()), QKeySequence("Ctrl+1"));
|
||||||
viewMenu->addAction(tr("100%"), m_imageGL, SLOT(oneToOne()));
|
viewMenu->addAction(tr("100%"), m_imageGL, SLOT(oneToOne()));
|
||||||
|
viewMenu->addAction(tr("Fullscreen"), this, SLOT(toggleFullScreen()), QKeySequence::FullScreen);
|
||||||
menuBar()->addMenu(viewMenu);
|
menuBar()->addMenu(viewMenu);
|
||||||
|
|
||||||
QMenu *selectMenu = new QMenu(tr("Select"), this);
|
QMenu *selectMenu = new QMenu(tr("Select"), this);
|
||||||
@@ -322,6 +323,20 @@ void MainWindow::copyMarked()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void MainWindow::toggleFullScreen()
|
||||||
|
{
|
||||||
|
if(isFullScreen())
|
||||||
|
{
|
||||||
|
showNormal();
|
||||||
|
if(_maximized)showMaximized();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
_maximized = isMaximized();
|
||||||
|
showFullScreen();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void MainWindow::liveMode(bool active)
|
void MainWindow::liveMode(bool active)
|
||||||
{
|
{
|
||||||
m_ringList->setLiveMode(active);
|
m_ringList->setLiveMode(active);
|
||||||
|
|||||||
@@ -20,6 +20,7 @@ class MainWindow : public QMainWindow
|
|||||||
static int socketPair[2];
|
static int socketPair[2];
|
||||||
QSocketNotifier *socketNotifier;
|
QSocketNotifier *socketNotifier;
|
||||||
QString _lastDir;
|
QString _lastDir;
|
||||||
|
bool _maximized;
|
||||||
public:
|
public:
|
||||||
MainWindow(QWidget *parent = 0);
|
MainWindow(QWidget *parent = 0);
|
||||||
~MainWindow();
|
~MainWindow();
|
||||||
@@ -40,6 +41,7 @@ protected slots:
|
|||||||
void markAndNext();
|
void markAndNext();
|
||||||
void unmarkAndNext();
|
void unmarkAndNext();
|
||||||
void copyMarked();
|
void copyMarked();
|
||||||
|
void toggleFullScreen();
|
||||||
void liveMode(bool active);
|
void liveMode(bool active);
|
||||||
void imageStats(bool imageStats);
|
void imageStats(bool imageStats);
|
||||||
void peakFinder(bool findPeaks);
|
void peakFinder(bool findPeaks);
|
||||||
|
|||||||
Reference in New Issue
Block a user