Changeset 8437 in orxonox.OLD for branches/gui/src
- Timestamp:
- Jun 15, 2006, 1:30:18 AM (18 years ago)
- Location:
- branches/gui/src/lib/gui/gl
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/gui/src/lib/gui/gl/glgui_button.cc
r8435 r8437 55 55 56 56 this->_label.setFont("fonts/final_frontier.ttf", 20); 57 this-> setFrontColor(Color(1, 0, 0, 1.0));57 this->_label.setColor(this->frontColor()); 58 58 59 59 this->_label.setParent2D(this); -
branches/gui/src/lib/gui/gl/glgui_inputline.cc
r8435 r8437 51 51 this->_text.setRelCoor2D(4,4); 52 52 this->_text.setFont("fonts/final_frontier.ttf", 20); 53 this->_text.setColor(this->frontColor()); 53 54 this->_text.setVisibility(false); 54 55 this->resize(); -
branches/gui/src/lib/gui/gl/glgui_slider.cc
r8421 r8437 228 228 void GLGuiSlider::tick(float dt) 229 229 { 230 GLGuiWidget::tick(dt); 230 231 } 231 232 -
branches/gui/src/lib/gui/gl/glgui_widget.cc
r8435 r8437 69 69 this->setVisibility(GLGUI_WIDGET_DEFAULT_VISIBLE); 70 70 71 this->_backMat.setDiffuse (1.0, 0.5, 0.4);71 this->_backMat.setDiffuseColor(Color(1.0, 0.5, 0.4, 1.0)); 72 72 this->_backMat.setDiffuseMap("gui_element_background.png"); 73 this->_frontColor .setColor(1.0, 0.0, 0.0);74 _toFrontColor = NULL;73 this->_frontColor = Color(1.0, 0.0, 0.0); 74 this->_toFrontColor = NULL; 75 75 76 76 … … 121 121 } 122 122 123 void GLGuiWidget::setFrontColor(const Color& frontColor) 124 { 125 if (!this->_toFrontColor) 123 void GLGuiWidget::setFrontColor(const Color& frontColor, bool instantaniously) 124 { 125 if (instantaniously) 126 { 127 this->_frontColor = frontColor; 128 if (this->_toFrontColor != NULL) 129 { 130 delete this->_toFrontColor; 131 this->_toFrontColor = NULL; 132 } 133 } 134 else if (!this->_toFrontColor) 126 135 this->_toFrontColor = new Color(frontColor); 127 136 else … … 214 223 215 224 void GLGuiWidget::destroyed() 216 { 217 };225 {} 226 ; 218 227 219 228 -
branches/gui/src/lib/gui/gl/glgui_widget.h
r8435 r8437 92 92 const Rect2D& backRect() const { return this->_backRect; }; 93 93 94 void setFrontColor(const Color& frontColor );94 void setFrontColor(const Color& frontColor, bool instantaniously = false); 95 95 const Color& frontColor() const { return this->_frontColor; }; 96 96
Note: See TracChangeset
for help on using the changeset viewer.