summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2016-06-12 18:33:02 +0200
committerStanislaw Halik <sthalik@misaki.pl>2016-06-14 18:14:46 +0200
commitd745fb68e2a05371e7935239cc60256bd4733957 (patch)
treec2fce735b702255bf8d57c0ef7a8575260aab80a
parent0c029da344b45154d4c68debe127d8cdf3843751 (diff)
gui: reformat curly braces only
-rw-r--r--gui/ui.cpp34
1 files changed, 22 insertions, 12 deletions
diff --git a/gui/ui.cpp b/gui/ui.cpp
index 40ac6c8d..10be1e30 100644
--- a/gui/ui.cpp
+++ b/gui/ui.cpp
@@ -186,11 +186,13 @@ void MainWindow::save()
#endif
}
-void MainWindow::load_mappings() {
+void MainWindow::load_mappings()
+{
pose.load_mappings();
}
-void MainWindow::load_settings() {
+void MainWindow::load_settings()
+{
s.b->reload();
load_mappings();
}
@@ -267,7 +269,8 @@ void MainWindow::updateButtonState(bool running, bool inertialp)
ui.iconcomboTrackerSource->setEnabled(not_running);
ui.profile_button->setEnabled(not_running);
ui.video_frame_label->setVisible(not_running || inertialp);
- if(not_running) {
+ if(not_running)
+ {
ui.video_frame_label->setPixmap(QPixmap(":/images/tracking-not-started.png"));
}
else {
@@ -282,7 +285,8 @@ void MainWindow::reload_options()
ensure_tray();
}
-void MainWindow::startTracker() {
+void MainWindow::startTracker()
+{
if (work)
return;
@@ -326,12 +330,13 @@ void MainWindow::startTracker() {
const bool is_inertial = ui.video_frame->layout() == nullptr;
updateButtonState(true, is_inertial);
- maybe_save();
+ save();
ui.btnStopTracker->setFocus();
}
-void MainWindow::stopTracker() {
+void MainWindow::stopTracker()
+{
if (!work)
return;
@@ -349,7 +354,7 @@ void MainWindow::stopTracker() {
if (pFilterDialog)
pFilterDialog->unregister_filter();
- maybe_save();
+ save();
work = nullptr;
libs = SelectedLibraries();
@@ -455,12 +460,14 @@ void MainWindow::showTrackerSettings()
pTrackerDialog->register_tracker(libs.pTracker.get());
}
-void MainWindow::showProtocolSettings() {
+void MainWindow::showProtocolSettings()
+{
if (mk_dialog(current_protocol(), pProtocolDialog) && libs.pProtocol)
pProtocolDialog->register_protocol(libs.pProtocol.get());
}
-void MainWindow::showFilterSettings() {
+void MainWindow::showFilterSettings()
+{
if (mk_dialog(current_filter(), pFilterDialog) && libs.pFilter)
pFilterDialog->register_filter(libs.pFilter.get());
}
@@ -483,18 +490,21 @@ bool mk_window(mem<t>* place, Args&&... params)
}
}
-void MainWindow::show_options_dialog() {
+void MainWindow::show_options_dialog()
+{
if (mk_window(&options_widget, s, [&](bool flag) -> void { set_keys_enabled(!flag); }))
{
connect(options_widget.get(), SIGNAL(reload()), this, SLOT(reload_options()));
}
}
-void MainWindow::showCurveConfiguration() {
+void MainWindow::showCurveConfiguration()
+{
mk_window(&mapping_widget, pose, s);
}
-void MainWindow::exit() {
+void MainWindow::exit()
+{
QCoreApplication::exit(0);
}