Code

Patch from Lubomir Rintel to fix build with Poppler 0.15.1
[inkscape.git] / src / main.cpp
index 78b66d8478766b185c65473e63c70a39e01e919c..eda6d0b03ca9882163bf6ced1d040dca62ff4a84 100644 (file)
@@ -114,7 +114,6 @@ using Inkscape::Extension::Internal::PrintWin32;
 #define bind_textdomain_codeset(p,c)
 #endif
 
-#include "application/application.h"
 #include "main-cmdlineact.h"
 #include "widgets/icon.h"
 #include "ui/widget/panel.h"
@@ -208,7 +207,6 @@ static gboolean sp_query_width = FALSE;
 static gboolean sp_query_height = FALSE;
 static gboolean sp_query_all = FALSE;
 static gchar *sp_query_id = NULL;
-static int sp_new_gui = FALSE;
 static gboolean sp_shell = FALSE;
 static gboolean sp_vacuum_defs = FALSE;
 
@@ -713,10 +711,15 @@ main(int argc, char **argv)
     }
 #endif // WIN32
 
-    /// \todo  Should this be a static object (see inkscape.cpp)?
-    Inkscape::NSApplication::Application app(argc, argv, use_gui, sp_new_gui);
+    int retcode;
 
-    return app.run();
+    if (use_gui) {
+        retcode = sp_main_gui(argc, (const char **) argv);
+    } else {
+        retcode = sp_main_console(argc, (const char **) argv);
+    }
+
+    return retcode;
 }