diff -r 55406ce7446e -r 31ff9aabd506 main.cpp --- a/main.cpp Mon Mar 18 18:29:02 2013 +0200 +++ b/main.cpp Tue Mar 19 15:29:42 2013 +0200 @@ -1,3 +1,21 @@ +/* + * LDForge: LDraw parts authoring CAD + * Copyright (C) 2013 Santeri `arezey` Piippo + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ + #include #include "gui.h" #include "file.h" @@ -6,9 +24,10 @@ #include "config.h" vector g_LoadedFiles; -OpenFile* g_CurrentFile = NULL; -ForgeWindow* g_qWindow = NULL; +OpenFile* g_CurrentFile = nullptr; +ForgeWindow* g_qWindow = nullptr; bbox g_BBox; +QApplication* g_qMainApp = nullptr; int main (int dArgC, char* saArgV[]) { // Load or create the configuration @@ -22,7 +41,10 @@ QApplication app (dArgC, saArgV); ForgeWindow* win = new ForgeWindow; + + g_qMainApp = &app; g_qWindow = win; + win->show (); return app.exec (); }