changeset 591:c06a9e8e2748 with-dependencies

Merge from default branch
author Chris Cannam
date Tue, 23 Jul 2013 16:12:50 +0100
parents 7a6fd7150f2d (current diff) 09c8195c371d (diff)
children 20ffffe5563a
files .hgsubstate main/main.cpp
diffstat 4 files changed, 27 insertions(+), 9 deletions(-) [+]
line wrap: on
line diff
--- a/.hgsubstate	Tue Jul 23 16:12:08 2013 +0100
+++ b/.hgsubstate	Tue Jul 23 16:12:50 2013 +0100
@@ -1,5 +1,5 @@
 7096c7de2d4c327de5e028c33036f146a1884706 dataquay
 619f715526df43e23b2b9b50715e825941572352 sv-dependency-builds
-8cb01cd2441d1009fce5c1234ecbe033ce45484a svapp
-bb7ea947c60d7ae76d3a608479f69a6308facd55 svcore
-77fa3fdbfc7e2b9f96eac6524d48294fb47760c3 svgui
+868db2bf6a694ab766cbf73b6b9c2a84907387d5 svapp
+420ade1cb6da314a5717637d902238b713ebc4b0 svcore
+0aea4b9e4c3dca9c42f9181748bdfde924a8574f svgui
--- a/deploy/osx/Info.plist	Tue Jul 23 16:12:08 2013 +0100
+++ b/deploy/osx/Info.plist	Tue Jul 23 16:12:50 2013 +0100
@@ -14,7 +14,6 @@
 	<string>org.sonicvisualiser.SonicVisualiser</string>
 	<key>CFBundleShortVersionString</key>
 	<string>SV_VERSION</string>
-	<key>CFBundleDocumentTypes</key>
 
 	<!-- enable HiDPI -->
 	<key>NSPrincipalClass</key>
@@ -22,6 +21,8 @@
 	<key>NSHighResolutionCapable</key>
 	<string>True</string>
 
+	<key>CFBundleDocumentTypes</key>
+
 	<array>
 		<!-- we are an 'editor' of SV files -->
 		<dict>
--- a/main/MainWindow.cpp	Tue Jul 23 16:12:08 2013 +0100
+++ b/main/MainWindow.cpp	Tue Jul 23 16:12:50 2013 +0100
@@ -375,6 +375,11 @@
 void
 MainWindow::goFullScreen()
 {
+    if (m_viewManager->getZoomWheelsEnabled()) {
+        // The wheels seem to end up in the wrong place in full-screen mode
+        toggleZoomWheels();
+    }
+
     QWidget *ps = m_mainScroll->takeWidget();
     ps->setParent(0);
 
@@ -409,6 +414,7 @@
         if (sc) delete sc;
     }
 
+    m_paneStack->showNormal();
     m_mainScroll->setWidget(m_paneStack);
 }
 
--- a/main/main.cpp	Tue Jul 23 16:12:08 2013 +0100
+++ b/main/main.cpp	Tue Jul 23 16:12:50 2013 +0100
@@ -172,16 +172,21 @@
 */
 
 static QMutex cleanupMutex;
+static bool cleanedUp = false;
 
 static void
 signalHandler(int /* signal */)
 {
     // Avoid this happening more than once across threads
 
+    std::cerr << "signalHandler: cleaning up and exiting" << std::endl;
     cleanupMutex.lock();
-    std::cerr << "signalHandler: cleaning up and exiting" << std::endl;
-    TempDirectory::getInstance()->cleanup();
-    exit(0); // without releasing mutex
+    if (!cleanedUp) {
+        TempDirectory::getInstance()->cleanup();
+        cleanedUp = true;
+    }
+    cleanupMutex.unlock();
+    exit(0);
 }
 
 class SVApplication : public QApplication
@@ -422,8 +427,12 @@
 
     cleanupMutex.lock();
 
-    TransformFactory::deleteInstance();
-    TempDirectory::getInstance()->cleanup();
+    if (!cleanedUp) {
+        TransformFactory::deleteInstance();
+        TempDirectory::getInstance()->cleanup();
+        cleanedUp = true;
+    }
+
     application.releaseMainWindow();
 
 #ifdef HAVE_FFTW3F
@@ -447,6 +456,8 @@
 
     cleanupMutex.unlock();
 
+    cleanupMutex.unlock();
+
     return rv;
 }