Changeset - 92c0f8665f08
[Not reviewed]
snapshots
0 2 0
Hasan Yavuz Ă–ZDERYA - 10 years ago 2015-09-20 08:17:23
hy@ozderya.net
implemented clear snapshots menu item
2 files changed with 14 insertions and 0 deletions:
0 comments (0 inline, 0 general)
mainwindow.cpp
Show inline comments
 
@@ -118,6 +118,9 @@ MainWindow::MainWindow(QWidget *parent) 
 
    QObject::connect(ui->actionSnapShot, SIGNAL(triggered(bool)),
 
                     this, SLOT(takeSnapShot()));
 

	
 
    QObject::connect(ui->actionClearSnapShots, SIGNAL(triggered(bool)),
 
                     this, SLOT(clearSnapshots()));
 

	
 
    // setup number of channels spinbox
 
    QObject::connect(ui->spNumOfChannels,
 
                     SELECT<int>::OVERLOAD_OF(&QSpinBox::valueChanged),
 
@@ -760,3 +763,13 @@ void MainWindow::updateSnapShotMenu()
 
        ui->menuSnapShots->addAction(ui->actionClearSnapShots);
 
    }
 
}
 

	
 
void MainWindow::clearSnapshots()
 
{
 
    for (auto snapshot : snapshots)
 
    {
 
        delete snapshot;
 
    }
 
    snapshots.clear();
 
    updateSnapShotMenu();
 
}
mainwindow.h
Show inline comments
 
@@ -133,6 +133,7 @@ private slots:
 
    void spsTimerTimeout();
 

	
 
    void takeSnapShot();
 
    void clearSnapshots();
 

	
 
    void demoTimerTimeout();
 
    void enableDemo(bool enabled);
0 comments (0 inline, 0 general)