summaryrefslogtreecommitdiffstats
path: root/qt-ui
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2013-11-14 21:06:31 +0900
committerGravatar Dirk Hohndel <dirk@hohndel.org>2013-11-14 21:06:31 +0900
commit9c90d6790a9cb38521beaedaffd1e847784b4088 (patch)
tree631948a983edc974568bdbaeccfd0d1ac42d65fd /qt-ui
parented41d5a74490b9af03ece57015d6867bbf00df14 (diff)
downloadsubsurface-9c90d6790a9cb38521beaedaffd1e847784b4088.tar.gz
Fix some random compiler warnings
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui')
-rw-r--r--qt-ui/diveplanner.cpp2
-rw-r--r--qt-ui/maintab.h2
-rw-r--r--qt-ui/mainwindow.cpp2
3 files changed, 2 insertions, 4 deletions
diff --git a/qt-ui/diveplanner.cpp b/qt-ui/diveplanner.cpp
index 37005e149..0cb3a67f3 100644
--- a/qt-ui/diveplanner.cpp
+++ b/qt-ui/diveplanner.cpp
@@ -1321,7 +1321,7 @@ void DivePlannerPointsModel::tanksUpdated()
divedatapoint& p = divepoints[j];
int o2 = oldGases.at(i).first;
int he = oldGases.at(i).second;
- if (p.o2 == o2 && p.he == he ||
+ if ((p.o2 == o2 && p.he == he) ||
(is_air(p.o2, p.he) && (is_air(o2, he) || (o2 == 0 && he == 0)))) {
p.o2 = gases.at(i).first;
p.he = gases.at(i).second;
diff --git a/qt-ui/maintab.h b/qt-ui/maintab.h
index 5a9e2efac..d2c96a972 100644
--- a/qt-ui/maintab.h
+++ b/qt-ui/maintab.h
@@ -83,11 +83,11 @@ public slots:
void enableEdition(EditMode newEditMode = NONE);
private:
- EditMode editMode;
Ui::MainTab ui;
WeightModel *weightModel;
CylindersModel *cylindersModel;
QMap<dive*, NotesBackup> notesBackup;
+ EditMode editMode;
/* since the multi-edition of the equipment is fairly more
* complex than a single item, because it involves a Qt
diff --git a/qt-ui/mainwindow.cpp b/qt-ui/mainwindow.cpp
index 3222d4887..a03104b6c 100644
--- a/qt-ui/mainwindow.cpp
+++ b/qt-ui/mainwindow.cpp
@@ -566,7 +566,6 @@ bool MainWindow::askSaveChanges()
void MainWindow::initialUiSetup()
{
QSettings settings;
- int i;
settings.beginGroup("MainWindow");
QSize sz = settings.value("size", qApp->desktop()->size()).value<QSize>();
resize(sz);
@@ -641,7 +640,6 @@ void MainWindow::readSettings()
void MainWindow::writeSettings()
{
- int i;
QSettings settings;
settings.beginGroup("MainWindow");