- Timestamp:
- May 24, 2008, 5:35:34 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/network/src/orxonox/hud/BarOverlayElement.h
r1410 r1411 26 26 */ 27 27 28 #ifndef _BAR_H__ 29 #define _BAR_H__ 28 30 29 #ifndef _BarOverlayElement_H__ 30 #define _BarOverlayElement_H__ 31 32 #include "OrxonoxPrereqs.h" 33 31 #include <OgrePanelOverlayElement.h> 34 32 #include <OgrePrerequisites.h> 35 #include <OgrePanelOverlayElement.h>33 #include "../OrxonoxPrereqs.h" 36 34 37 35 namespace orxonox … … 40 38 { 41 39 private: 42 bool autoColor_; // whether bar changes color automatically43 float value_; // progress of bar44 int color_;45 int left_;46 int top_;47 int width_;48 int height_;49 int windowW_, windowH_;50 Ogre::Real leftRel_;51 Ogre::Real topRel_;52 Ogre::Real dimRel_;53 Ogre::OverlayManager* om; // our overlay manager54 Ogre::OverlayContainer* container_; // our parent container to attach to55 Ogre::OverlayContainer* background_;56 Ogre::String name_;40 bool autoColor_; // whether bar changes color automatically 41 float value_; // progress of bar 42 int color_; 43 int left_; 44 int top_; 45 int width_; 46 int height_; 47 int windowW_, windowH_; 48 Ogre::Real leftRel_; 49 Ogre::Real topRel_; 50 Ogre::Real dimRel_; 51 Ogre::OverlayManager* om; // our overlay manager 52 Ogre::OverlayContainer* container_; // our parent container to attach to 53 Ogre::OverlayContainer* background_; 54 Ogre::String name_; 57 55 58 56 public: 59 bool left2Right;60 static const int RED = 0; // predefined colors61 static const int YELLOW = 1;62 static const int GREEN = 2;57 bool left2Right; 58 static const int RED = 0; // predefined colors 59 static const int YELLOW = 1; 60 static const int GREEN = 2; 63 61 64 BarOverlayElement(const Ogre::String& name);65 virtual ~BarOverlayElement();66 void init(Real leftRel, Real topRel, Real dimRel, Ogre::OverlayContainer* container);67 void resize();68 void setValue(float value);69 void setColor(int color);70 float getValue();71 int getBarColor();62 BarOverlayElement(const Ogre::String& name); 63 virtual ~BarOverlayElement(); 64 void init(Real leftRel, Real topRel, Real dimRel, Ogre::OverlayContainer* container); 65 void resize(); 66 void setValue(float value); 67 void setColor(int color); 68 float getValue(); 69 int getBarColor(); 72 70 }; 73 71 } 72 #endif 74 73 75 #endif /* _BarOverlayElement_H__ */ 74
Note: See TracChangeset
for help on using the changeset viewer.