[PATCH] Disable Document Mode for MainTab on MacOSX

subsurface at henrik.synth.no subsurface at henrik.synth.no
Fri Jun 7 03:23:48 PDT 2013


From: Henrik Brautaset Aronsen <subsurface at henrik.synth.no>

Commit c4f06dc536392e31a477e592d30fb946f1499595 introduced Document
Mode on the MainTab QTabWidget. This doesn't look good on MacOSX.

Signed-off-by: Henrik Brautaset Aronsen <subsurface at henrik.synth.no>
---
 qt-ui/maintab.cpp | 6 +++++-
 qt-ui/maintab.ui  | 3 ---
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/qt-ui/maintab.cpp b/qt-ui/maintab.cpp
index b9b5d0a..080ebdf 100644
--- a/qt-ui/maintab.cpp
+++ b/qt-ui/maintab.cpp
@@ -27,7 +27,11 @@ MainTab::MainTab(QWidget *parent) : QTabWidget(parent),
 	ui->weights->setModel(weightModel);
 	ui->diveNotesMessage->hide();
 	ui->diveNotesMessage->setCloseButtonVisible(false);
-
+#ifdef __APPLE__
+	setDocumentMode(false);
+#else
+	setDocumentMode(true);
+#endif
 	// we start out with the fields read-only; once things are
 	// filled from a dive, they are made writeable
 	ui->location->setReadOnly(true);
diff --git a/qt-ui/maintab.ui b/qt-ui/maintab.ui
index 55d4f3a..c05589d 100644
--- a/qt-ui/maintab.ui
+++ b/qt-ui/maintab.ui
@@ -16,9 +16,6 @@
   <property name="currentIndex">
    <number>3</number>
   </property>
-  <property name="documentMode">
-   <bool>true</bool>
-  </property>
   <widget class="QWidget" name="notesTab">
    <attribute name="title">
     <string>Dive Notes</string>
-- 
1.8.2.2



More information about the subsurface mailing list