Changeset 2605 in orxonox.OLD for orxonox/trunk/gui/orxonox_gui.h
- Timestamp:
- Oct 19, 2004, 10:39:44 PM (21 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/gui/orxonox_gui.h
r2595 r2605 39 39 private: 40 40 public: 41 ~Widget (); 42 41 43 Widget* next; //!< next always points to the next Widget in the list. Every Widget has a next one, or has NULL as next 42 44 GtkWidget* widget; //!< widget is the gtk_widget that the specific Object Contains. 43 45 virtual void init(void); 44 46 int is_option; //!< with this Paramenter one can set the IsOption type: -2:Container, -1: Box, 0: not an Option, 1: Bool-option, 2: int-option 45 enum option { containerType = -2, boxType = -1, nothingType = 0, boolType = 1, intType = 2}; //!< defines is_option states 47 /** 48 \briefdefines is_option states 49 */ 50 enum option { containerType = -2, boxType = -1, nothingType = 0, boolType = 1, intType = 2}; 51 char* label; //!< The name of the Widget. Some do display it, Options need it to save; 46 52 void connectSignal (char* event, gint (*signal)(GtkWidget*, GdkEvent*, void *)); 47 53 void connectSignal (char* event, gint (*signal)(GtkWidget*, Widget *)); 48 54 void connectSignal (char* event, void* extObj, gint (*signal)(GtkWidget*, GdkEvent*, void *)); 49 55 void show (); 56 void hide (); 57 void setSize(int width, int height); 50 58 51 59 void walkThrough (void (*function)(Widget*)); … … 55 63 }; 56 64 65 //! This is a Packer Object, which has the ability to Pack other Widgets into itself. 66 class Packer : public Widget 67 { 68 public: 69 Widget* down; //!< this points to the Widget below this. 70 71 void init(void); 72 }; 57 73 58 74 //! This is a Container Class, it can contain one sub-Widget: down. … … 62 78 * The derived classes of Container can be displayed 63 79 */ 64 class Container : public Widget80 class Container : public Packer 65 81 { 66 82 private: 67 83 int borderwidth; 68 84 int policy; 69 char* label; 70 71 public: 72 void init(void); 73 Widget* down; //!< this points to the Widget below this. 85 86 public: 87 void init(void); 74 88 // void setBorderWidth (int borderwidth); 75 89 // virtual void setTitle (char* title) = 0; … … 84 98 class Window : public Container 85 99 { 100 private: 101 bool isOpen; 86 102 public: 87 103 Window (char* windowName); 88 104 Window (void); 89 ~Window ();90 105 void init (); 91 106 … … 105 120 Frame (char* frameName); 106 121 Frame (void); 107 ~Frame ();108 122 void init(void); 109 123 … … 120 134 EventBox (char* eventBoxName); 121 135 EventBox (void); 122 ~EventBox ();123 136 void init(void); 124 137 … … 132 145 * A Box is always filled left->right (horizontally) or up->down (vertically) 133 146 */ 134 class Box : public Widget147 class Box : public Packer 135 148 { 136 149 public: 137 150 Box (void); 138 151 Box (char boxtype); 139 ~Box (void);140 152 void init(char boxtype); 141 153 142 Widget* down; //!< the Lower Widget of a Box.143 154 void fill (Widget* lowerWidget); 144 155 … … 154 165 public: 155 166 Image (char* imgaename); 156 ~Image ();157 167 void init(void); 158 168 }; … … 169 179 170 180 int value; //!< every option has a value either true or false (0,1) or something else like 25 for 25% of the volume 171 char* option_name; //!< options have a name, that can be displayed around them172 181 char* flag_name; //!< options have a flag name that will be appendet if you start the Program from the GUI. 173 182 char* flag_name_short; //!< like flag_name but shorter … … 187 196 public: 188 197 Button (char* buttonname); 189 ~Button (void);190 198 void init(void); 191 199 … … 202 210 public: 203 211 CheckButton (char* buttonname); 204 ~CheckButton (void);205 212 static gint OptionChange (GtkWidget* widget, Widget* checkbutton); 206 213 … … 219 226 public: 220 227 Slider (char* slidername,int start, int end); 221 ~Slider ();222 228 void init(int start, int end); 223 229 … … 239 245 public: 240 246 Menu (char* menuname, ...); 241 ~Menu ();242 247 void init(void); 243 248 … … 255 260 Label (); 256 261 Label (char* text); 257 ~Label ();258 262 void init(void); 259 263
Note: See TracChangeset
for help on using the changeset viewer.