diff options
author | David Walter Seikel | 2013-01-13 18:54:10 +1000 |
---|---|---|
committer | David Walter Seikel | 2013-01-13 18:54:10 +1000 |
commit | 959831f4ef5a3e797f576c3de08cd65032c997ad (patch) | |
tree | e7351908be5995f0b325b2ebeaa02d5a34b82583 /libraries/irrlicht-1.8/source/Irrlicht/CGUISpinBox.h | |
parent | Add info about changes to Irrlicht. (diff) | |
download | SledjHamr-959831f4ef5a3e797f576c3de08cd65032c997ad.zip SledjHamr-959831f4ef5a3e797f576c3de08cd65032c997ad.tar.gz SledjHamr-959831f4ef5a3e797f576c3de08cd65032c997ad.tar.bz2 SledjHamr-959831f4ef5a3e797f576c3de08cd65032c997ad.tar.xz |
Remove damned ancient DOS line endings from Irrlicht. Hopefully I did not go overboard.
Diffstat (limited to '')
-rw-r--r-- | libraries/irrlicht-1.8/source/Irrlicht/CGUISpinBox.h | 216 |
1 files changed, 108 insertions, 108 deletions
diff --git a/libraries/irrlicht-1.8/source/Irrlicht/CGUISpinBox.h b/libraries/irrlicht-1.8/source/Irrlicht/CGUISpinBox.h index e487c0b..0f4d0c0 100644 --- a/libraries/irrlicht-1.8/source/Irrlicht/CGUISpinBox.h +++ b/libraries/irrlicht-1.8/source/Irrlicht/CGUISpinBox.h | |||
@@ -1,108 +1,108 @@ | |||
1 | // Copyright (C) 2006-2012 Michael Zeilfelder | 1 | // Copyright (C) 2006-2012 Michael Zeilfelder |
2 | // This file is part of the "Irrlicht Engine". | 2 | // This file is part of the "Irrlicht Engine". |
3 | // For conditions of distribution and use, see copyright notice in irrlicht.h | 3 | // For conditions of distribution and use, see copyright notice in irrlicht.h |
4 | 4 | ||
5 | #ifndef __C_GUI_SPIN_BOX_H_INCLUDED__ | 5 | #ifndef __C_GUI_SPIN_BOX_H_INCLUDED__ |
6 | #define __C_GUI_SPIN_BOX_H_INCLUDED__ | 6 | #define __C_GUI_SPIN_BOX_H_INCLUDED__ |
7 | 7 | ||
8 | #include "IrrCompileConfig.h" | 8 | #include "IrrCompileConfig.h" |
9 | #ifdef _IRR_COMPILE_WITH_GUI_ | 9 | #ifdef _IRR_COMPILE_WITH_GUI_ |
10 | 10 | ||
11 | #include "IGUISpinBox.h" | 11 | #include "IGUISpinBox.h" |
12 | 12 | ||
13 | namespace irr | 13 | namespace irr |
14 | { | 14 | { |
15 | namespace gui | 15 | namespace gui |
16 | { | 16 | { |
17 | class IGUIEditBox; | 17 | class IGUIEditBox; |
18 | class IGUIButton; | 18 | class IGUIButton; |
19 | 19 | ||
20 | class CGUISpinBox : public IGUISpinBox | 20 | class CGUISpinBox : public IGUISpinBox |
21 | { | 21 | { |
22 | public: | 22 | public: |
23 | 23 | ||
24 | //! constructor | 24 | //! constructor |
25 | CGUISpinBox(const wchar_t* text, bool border, IGUIEnvironment* environment, | 25 | CGUISpinBox(const wchar_t* text, bool border, IGUIEnvironment* environment, |
26 | IGUIElement* parent, s32 id, const core::rect<s32>& rectangle); | 26 | IGUIElement* parent, s32 id, const core::rect<s32>& rectangle); |
27 | 27 | ||
28 | //! destructor | 28 | //! destructor |
29 | virtual ~CGUISpinBox(); | 29 | virtual ~CGUISpinBox(); |
30 | 30 | ||
31 | //! Access the edit box used in the spin control | 31 | //! Access the edit box used in the spin control |
32 | /** \param enable: If set to true, the override color, which can be set | 32 | /** \param enable: If set to true, the override color, which can be set |
33 | with IGUIEditBox::setOverrideColor is used, otherwise the | 33 | with IGUIEditBox::setOverrideColor is used, otherwise the |
34 | EGDC_BUTTON_TEXT color of the skin. */ | 34 | EGDC_BUTTON_TEXT color of the skin. */ |
35 | virtual IGUIEditBox* getEditBox() const; | 35 | virtual IGUIEditBox* getEditBox() const; |
36 | 36 | ||
37 | //! set the current value of the spinbox | 37 | //! set the current value of the spinbox |
38 | /** \param val: value to be set in the spinbox */ | 38 | /** \param val: value to be set in the spinbox */ |
39 | virtual void setValue(f32 val); | 39 | virtual void setValue(f32 val); |
40 | 40 | ||
41 | //! Get the current value of the spinbox | 41 | //! Get the current value of the spinbox |
42 | virtual f32 getValue() const; | 42 | virtual f32 getValue() const; |
43 | 43 | ||
44 | //! set the range of values which can be used in the spinbox | 44 | //! set the range of values which can be used in the spinbox |
45 | /** \param min: minimum value | 45 | /** \param min: minimum value |
46 | \param max: maximum value */ | 46 | \param max: maximum value */ |
47 | virtual void setRange(f32 min, f32 max); | 47 | virtual void setRange(f32 min, f32 max); |
48 | 48 | ||
49 | //! get the minimum value which can be used in the spinbox | 49 | //! get the minimum value which can be used in the spinbox |
50 | virtual f32 getMin() const; | 50 | virtual f32 getMin() const; |
51 | 51 | ||
52 | //! get the maximum value which can be used in the spinbox | 52 | //! get the maximum value which can be used in the spinbox |
53 | virtual f32 getMax() const; | 53 | virtual f32 getMax() const; |
54 | 54 | ||
55 | //! step size by which values are changed when pressing the spin buttons | 55 | //! step size by which values are changed when pressing the spin buttons |
56 | /** \param step: stepsize used for value changes when pressing spin buttons */ | 56 | /** \param step: stepsize used for value changes when pressing spin buttons */ |
57 | virtual void setStepSize(f32 step=1.f); | 57 | virtual void setStepSize(f32 step=1.f); |
58 | 58 | ||
59 | //! returns the step size | 59 | //! returns the step size |
60 | virtual f32 getStepSize() const; | 60 | virtual f32 getStepSize() const; |
61 | 61 | ||
62 | //! called if an event happened. | 62 | //! called if an event happened. |
63 | virtual bool OnEvent(const SEvent& event); | 63 | virtual bool OnEvent(const SEvent& event); |
64 | 64 | ||
65 | //! Draws the element and its children. | 65 | //! Draws the element and its children. |
66 | virtual void draw(); | 66 | virtual void draw(); |
67 | 67 | ||
68 | //! Sets the new caption of the element | 68 | //! Sets the new caption of the element |
69 | virtual void setText(const wchar_t* text); | 69 | virtual void setText(const wchar_t* text); |
70 | 70 | ||
71 | //! Returns caption of this element. | 71 | //! Returns caption of this element. |
72 | virtual const wchar_t* getText() const; | 72 | virtual const wchar_t* getText() const; |
73 | 73 | ||
74 | //! Sets the number of decimal places to display. | 74 | //! Sets the number of decimal places to display. |
75 | //! Note that this also rounds the range to the same number of decimal places. | 75 | //! Note that this also rounds the range to the same number of decimal places. |
76 | /** \param places: The number of decimal places to display, use -1 to reset */ | 76 | /** \param places: The number of decimal places to display, use -1 to reset */ |
77 | virtual void setDecimalPlaces(s32 places); | 77 | virtual void setDecimalPlaces(s32 places); |
78 | 78 | ||
79 | //! Writes attributes of the element. | 79 | //! Writes attributes of the element. |
80 | virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options) const; | 80 | virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options) const; |
81 | 81 | ||
82 | //! Reads attributes of the element | 82 | //! Reads attributes of the element |
83 | virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options); | 83 | virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options); |
84 | 84 | ||
85 | protected: | 85 | protected: |
86 | virtual void verifyValueRange(); | 86 | virtual void verifyValueRange(); |
87 | void refreshSprites(); | 87 | void refreshSprites(); |
88 | 88 | ||
89 | IGUIEditBox * EditBox; | 89 | IGUIEditBox * EditBox; |
90 | IGUIButton * ButtonSpinUp; | 90 | IGUIButton * ButtonSpinUp; |
91 | IGUIButton * ButtonSpinDown; | 91 | IGUIButton * ButtonSpinDown; |
92 | video::SColor CurrentIconColor; | 92 | video::SColor CurrentIconColor; |
93 | f32 StepSize; | 93 | f32 StepSize; |
94 | f32 RangeMin; | 94 | f32 RangeMin; |
95 | f32 RangeMax; | 95 | f32 RangeMax; |
96 | 96 | ||
97 | core::stringw FormatString; | 97 | core::stringw FormatString; |
98 | s32 DecimalPlaces; | 98 | s32 DecimalPlaces; |
99 | }; | 99 | }; |
100 | 100 | ||
101 | 101 | ||
102 | } // end namespace gui | 102 | } // end namespace gui |
103 | } // end namespace irr | 103 | } // end namespace irr |
104 | 104 | ||
105 | #endif // _IRR_COMPILE_WITH_GUI_ | 105 | #endif // _IRR_COMPILE_WITH_GUI_ |
106 | 106 | ||
107 | #endif // __C_GUI_SPIN_BOX_H_INCLUDED__ | 107 | #endif // __C_GUI_SPIN_BOX_H_INCLUDED__ |
108 | 108 | ||