+void MainBar::on_actionSaveSetup_triggered()
+{
+ QSettings settings;
+ const QString dir = settings.value(SettingSaveDirectory).toString();
+
+ const QString file_name = QFileDialog::getSaveFileName(
+ this, tr("Save File"), dir, tr(
+ "PulseView Session Setups (*.pvs);;"
+ "All Files (*)"));
+
+ if (file_name.isEmpty())
+ return;
+
+ QSettings settings_storage(file_name, QSettings::IniFormat);
+ session_.save_setup(settings_storage);
+}
+
+void MainBar::on_actionRestoreSetup_triggered()
+{
+ QSettings settings;
+ const QString dir = settings.value(SettingSaveDirectory).toString();
+
+ const QString file_name = QFileDialog::getOpenFileName(
+ this, tr("Open File"), dir, tr(
+ "PulseView Session Setups (*.pvs);;"
+ "All Files (*)"));
+
+ if (file_name.isEmpty())
+ return;
+
+ QSettings settings_storage(file_name, QSettings::IniFormat);
+ session_.restore_setup(settings_storage);
+}
+