Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/branches/qt_gui/src/lib/gui/qt_gui/qt_gui.cc @ 7495

Last change on this file since 7495 was 7495, checked in by bensch, 18 years ago

added GuiAudio

File size: 1.4 KB
Line 
1/*
2   orxonox - the future of 3D-vertical-scrollers
3
4   Copyright (C) 2004 orx
5
6   This program is free software; you can redistribute it and/or modify
7   it under the terms of the GNU General Public License as published by
8   the Free Software Foundation; either version 2, or (at your option)
9   any later version.
10
11   ### File Specific:
12   main-programmer: Benjamin Grauer
13   co-programmer: ...
14*/
15
16//#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_
17
18#include "qt_gui.h"
19
20#include <qapplication.h>
21#include <qgroupbox.h>
22#include <qlayout.h>
23#include <qtoolbox.h>
24
25#include <qpushbutton.h>
26
27#include "gui_video.h"
28#include "gui_audio.h"
29
30namespace OrxGui
31{
32  QtGui::QtGui(int argc, char** argv)
33  : QApplication(argc, argv)
34  {
35
36    this->mainWindow = new QMainWindow();
37
38
39    QGroupBox* groupBox = new QGroupBox(this->mainWindow);
40    QGridLayout* mainLayout = new QGridLayout(groupBox);
41    {
42      QToolBox* toolBox = new QToolBox(groupBox);
43      {
44
45        toolBox->addItem(new GuiVideo(toolBox), "Video");
46        toolBox->addItem(new GuiAudio(toolBox), "Audio");
47      }
48      mainLayout->addWidget(toolBox,1,1);
49    }
50
51    this->mainWindow->setCentralWidget(groupBox);
52    this->mainWindow->show();
53
54    this->exec();
55
56
57  }
58
59  QtGui::~QtGui()
60  {
61    delete this->mainWindow;
62  }
63
64  void QtGui::startGui()
65  {}
66
67  void QtGui::stopGui()
68  {}
69
70  void QtGui::suspend()
71  {}
72
73    //! Update the Gui.
74  void QtGui::update()
75  {
76    this->processEvents();
77  }
78
79}
Note: See TracBrowser for help on using the repository browser.