Tidy up code to report failures to load config in the UI.
[dcpomatic.git] / src / wx / wx_util.h
index aa3dc60dba7bf5aafe12d8b460d5c7b911464316..fb1a3a001ecd6064467ea3bd97347ac435beb52b 100644 (file)
 #define DCPOMATIC_WX_UTIL_H
 
 
+#include "lib/config.h"
 #include "lib/dcpomatic_time.h"
-#include "lib/warnings.h"
-DCPOMATIC_DISABLE_WARNINGS
-#include <wx/wx.h>
-DCPOMATIC_ENABLE_WARNINGS
+#include <dcp/warnings.h>
+LIBDCP_DISABLE_WARNINGS
 #include <wx/gbsizer.h>
-#include <boost/thread.hpp>
+#include <wx/wx.h>
+LIBDCP_ENABLE_WARNINGS
 #include <boost/signals2.hpp>
+#include <boost/thread.hpp>
 
 
 class FilePickerCtrl;
@@ -119,7 +120,10 @@ extern bool display_progress (wxString title, wxString task);
 extern bool report_errors_from_last_job (wxWindow* parent);
 extern wxString bitmap_path (std::string name);
 extern wxSize small_button_size (wxWindow* parent, wxString text);
-
+extern bool gui_is_dark ();
+extern double dpi_scale_factor (wxWindow* window);
+extern int search_ctrl_height ();
+extern void report_config_load_failure(wxWindow* parent, Config::LoadFailure what);
 
 struct Offset
 {
@@ -156,7 +160,7 @@ extern int wx_get (wxChoice* widget);
 extern int wx_get (wxSpinCtrl* widget);
 extern double wx_get (wxSpinCtrlDouble* widget);
 
-#if defined(__WXMSW__)
+#ifdef DCPOMATIC_WINDOWS
 #define DCPOMATIC_USE_OWN_PICKER
 #endif