]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mgl/window.cpp
end with fatal error if cannot start MGL
[wxWidgets.git] / src / mgl / window.cpp
index f749bc125181cde32ea47f17a9c967588befa15e..170bf9cb43e55740f5f0799b2b319c0f26d66862 100644 (file)
@@ -476,7 +476,10 @@ void wxWindowMGL::Init()
     // First of all, make sure window manager is up and running. If it is
     // not the case, initialize it in default display mode
     if ( !g_winMng )
-        wxTheApp->SetDisplayMode(wxGetDefaultDisplayMode());
+    {
+        if ( !wxTheApp->SetDisplayMode(wxGetDefaultDisplayMode()) )
+            wxFatalError(_("Cannot initialize display."));
+    }
 
     // generic:
     InitBase();