New lua versions
[ryzomcore.git] / studio / src / plugins / object_viewer / modules.cpp
blob605f484f74071734c92b3cc372df8fcf32da0fa5
1 /*
2 Object Viewer Qt
3 Copyright (C) 2010 Dzmitry Kamiahin <dnk-88@tut.by>
5 This program is free software: you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 3 of the License, or
8 (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program. If not, see <http://www.gnu.org/licenses/>.
20 #include "stdpch.h"
21 #include "modules.h"
23 NLQT::CObjectViewer *Modules::_objectViewer = NULL;
24 NLQT::CMainWindow *Modules::_mainWindow = NULL;
25 NLQT::CParticleEditor *Modules::_particleEditor = NULL;
26 NLQT::CSoundSystem *Modules::_soundSystem = NULL;
27 NLQT::CVegetableEditor *Modules::_vegetableEditor = NULL;
29 void Modules::init()
31 if (_objectViewer == NULL) _objectViewer = new NLQT::CObjectViewer;
32 if (_soundSystem == NULL) _soundSystem = new NLQT::CSoundSystem;
33 if (_particleEditor == NULL) _particleEditor = new NLQT::CParticleEditor;
34 if (_vegetableEditor == NULL) _vegetableEditor = new NLQT::CVegetableEditor;
35 if (_mainWindow == NULL) _mainWindow = new NLQT::CMainWindow;
38 void Modules::release()
40 // delete _mainWindow;
41 _mainWindow = NULL;
42 delete _particleEditor;
43 _particleEditor = NULL;
44 delete _vegetableEditor;
45 _vegetableEditor = NULL;
46 delete _soundSystem;
47 _soundSystem = NULL;
48 delete _objectViewer;
49 _objectViewer = NULL;