Hacky window-on-top fix for OS X.
authorCarl Hetherington <cth@carlh.net>
Sat, 27 Aug 2016 23:05:35 +0000 (00:05 +0100)
committerCarl Hetherington <cth@carlh.net>
Sat, 27 Aug 2016 23:05:35 +0000 (00:05 +0100)
src/wx/audio_dialog.cc
src/wx/timeline_dialog.cc
src/wx/video_waveform_dialog.cc

index b0867823ea4455986b6638b87655e2fb0373f179..ab591143cad9c2649dae75f27ad4610b41235177 100644 (file)
@@ -49,7 +49,14 @@ AudioDialog::AudioDialog (wxWindow* parent, shared_ptr<Film> film, shared_ptr<Co
                _("Audio"),
                wxDefaultPosition,
                wxSize (640, 512),
+#ifdef DCPOMATIC_OSX
+               /* I can't get wxFRAME_FLOAT_ON_PARENT to work on OS X, and although wxSTAY_ON_TOP keeps
+                  the window above all others (and not just our own) it's better than nothing for now.
+               */
+               wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER | wxFULL_REPAINT_ON_RESIZE | wxSTAY_ON_TOP
+#else
                wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER | wxFULL_REPAINT_ON_RESIZE | wxFRAME_FLOAT_ON_PARENT
+#endif
                )
        , _film (film)
        , _content (content)
index 76a2c45e61e33a092d7b7e2b2df84b584f5355b2..e050c27d97acb1b88915c647d6fd9595facee1a1 100644 (file)
@@ -38,7 +38,14 @@ TimelineDialog::TimelineDialog (ContentPanel* cp, shared_ptr<Film> film)
                _("Timeline"),
                wxDefaultPosition,
                wxSize (640, 512),
+#ifdef DCPOMATIC_OSX
+               /* I can't get wxFRAME_FLOAT_ON_PARENT to work on OS X, and although wxSTAY_ON_TOP keeps
+                  the window above all others (and not just our own) it's better than nothing for now.
+               */
+               wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER | wxFULL_REPAINT_ON_RESIZE | wxSTAY_ON_TOP
+#else
                wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER | wxFULL_REPAINT_ON_RESIZE | wxFRAME_FLOAT_ON_PARENT
+#endif
                )
        , _film (film)
        , _timeline (this, cp, film)
index 412ebf8bb7482a67625ae084a256220ee10fb706..1fd96ea0b2800e012478e478f3f0618c29d76d92 100644 (file)
@@ -36,7 +36,14 @@ VideoWaveformDialog::VideoWaveformDialog (wxWindow* parent, weak_ptr<const Film>
                _("Video Waveform"),
                wxDefaultPosition,
                wxSize (640, 512),
+#ifdef DCPOMATIC_OSX
+               /* I can't get wxFRAME_FLOAT_ON_PARENT to work on OS X, and although wxSTAY_ON_TOP keeps
+                  the window above all others (and not just our own) it's better than nothing for now.
+               */
+               wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER | wxFULL_REPAINT_ON_RESIZE | wxSTAY_ON_TOP
+#else
                wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER | wxFULL_REPAINT_ON_RESIZE | wxFRAME_FLOAT_ON_PARENT
+#endif
                )
        , _viewer (viewer)
 {