Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7149 in orxonox.OLD for branches


Ignore:
Timestamp:
Feb 16, 2006, 12:51:42 AM (19 years ago)
Author:
bensch
Message:

qt_gui:more gui work

Location:
branches/qt_gui/src/lib/gui/qt_gui
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • branches/qt_gui/src/lib/gui/qt_gui/Makefile.am

    r7142 r7149  
    1414libORXqtgui_a_SOURCES = \
    1515                gui_saveable.cc \
     16                \
    1617                qt_gui.cc
    1718
    18 noinst_HEADERS=
     19noinst_HEADERS= \
     20                gui_saveable.h \
     21                \
     22                qt_gui.h
    1923
    2024EXTRA_DIST =
  • branches/qt_gui/src/lib/gui/qt_gui/gui_saveable.cc

    r7143 r7149  
    4040
    4141
    42 GuiGroup::GuiGroup(const std::string& name)
     42GuiGroup::GuiGroup(const char* groupName)
    4343{
    44 
     44  this->setName(groupName);
    4545}
    4646
  • branches/qt_gui/src/lib/gui/qt_gui/gui_saveable.h

    r7145 r7149  
    1010#include "multi_type.h"
    1111#include <list>
    12 #include <string>
    1312
    1413// FORWARD DECLARATION
     
    1615
    1716//! A class for ...
    18 class GuiSaveable : virtual public BaseObject {
     17class GuiSaveable : virtual public BaseObject
     18{
    1919
    20  public:
     20public:
     21
    2122
    2223protected:
     
    2728  virtual const MultiType& save() = 0;
    2829
    29  private:
    30    MultiType       value;
     30protected:
     31  MultiType       value;
    3132};
    3233
    3334
    34 class GuiGroup
     35
     36class GuiGroup : virtual public BaseObject
    3537{
    36   public:
    37     GuiGroup(const std::string& name);
    38     ~GuiGroup();
     38public:
     39  GuiGroup(const char* name);
     40  ~GuiGroup();
    3941
    40   private:
     42  void addSaveable(GuiSaveable* saveable);
    4143
     44private:
     45  std::list<GuiSaveable*>     saveables;
    4246};
    4347
  • branches/qt_gui/src/lib/gui/qt_gui/qt_gui.cc

    r7140 r7149  
    1010
    1111   ### File Specific:
    12    main-programmer: ...
     12   main-programmer: Benjamin Grauer
    1313   co-programmer: ...
    1414*/
  • branches/qt_gui/src/lib/gui/qt_gui/qt_gui.h

    r7142 r7149  
    88
    99#include "base_object.h"
     10#include "gui_saveable.h"
     11#include <list>
     12
     13// grouping
     14#include <qgroupbox.h>
     15#include <qprogressbar.h>
     16#include <qlabel.h>
     17
     18// events
    1019#include <qpushbutton.h>
     20
     21// options
    1122#include <qcheckbox.h>
    1223#include <qslider.h>
     24#include <qlineedit.h>
    1325
    1426
     27class QtGuiWidget : virtual public BaseObject
     28{
     29  public:
     30};
     31
     32
     33class QtGuiContainer
     34{
     35public:
     36  virtual bool pack(QtGuiWidget* widget) = 0;
     37
     38protected:
     39  QtGuiContainer();
     40  ~QtGuiContainer();
     41
     42private:
     43
     44};
     45
     46
     47class QtGuiBox : public QtGuiContainer
     48{
     49public:
     50  typedef enum Orientation
     51  {
     52    horizontal,
     53    vertical
     54  };
     55
     56public:
     57  QtGuiBox(Orientation orientation);
     58  ~QtGuiBox();
     59
     60  virtual bool pack(QtGuiWidget* widget);
     61
     62private:
     63  std::list<QtGuiWidget*>   children;
     64
     65};
     66
     67class QtGuiGroupBox : public QtGuiContainer, public GuiGroup
     68{
     69public:
     70  QtGuiGroupBox(const char* groupName);
     71  ~QtGuiGroupBox();
     72
     73  virtual bool pack(QtGuiWidget* widget);
     74
     75private:
     76  QtGuiWidget*              child;
     77};
     78
     79
     80class QtGuiCheckBox : public QtGuiWidget, public GuiSaveable
     81{
     82public:
     83  QtGuiCheckBox(const char* name, bool defaultValue = false);
     84  ~QtGuiCheckBox();
     85
     86  //slot
     87
     88private:
     89
     90};
    1591
    1692
Note: See TracChangeset for help on using the changeset viewer.