My Project
D:/source/c++/Programme/sally/sally/sallyAPI/NumberSelector.h
Go to the documentation of this file.
00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 
00020 
00021 
00022 
00023 
00024 
00025 
00026 
00027 
00028 #pragma once
00029 #include "Define.h"
00030 #include "Form.h"
00031 #include "Edit.h"
00032 #include "Button.h"
00033 
00034 namespace SallyAPI
00035 {
00036         namespace GUI
00037         {
00046 
00047                 class DLL_API_SALLY CNumberSelector :
00048                         public SallyAPI::GUI::CForm
00049                 {
00050                 private:
00051                         SallyAPI::GUI::CEdit*   m_pEdit;
00052                         SallyAPI::GUI::CButton* m_pButtonUp;
00053                         SallyAPI::GUI::CButton* m_pButtonDown;
00054 
00055                         float   m_fStartTime;
00056                         int             m_iMaxValue;
00057                         int             m_iMinValue;
00058                         int             m_iSteps;
00059                         bool    m_iStepProcessed;
00060 
00061                         virtual std::string GetText();
00062                         virtual void SetText(const std::string& text);
00063 
00064                         void OnCommandEditChanged();
00065                         void OnCommandButtonUp(int step);
00066                         void OnCommandButtonDown(int step);
00067                 public:
00068                         CNumberSelector(SallyAPI::GUI::CGUIBaseObject* parent, int x, int y, int width, int controlId = 0);
00069                         virtual ~CNumberSelector();
00070 
00071                         virtual void SendMessageToParent(SallyAPI::GUI::CGUIBaseObject* reporter, int reporterId, int messageId, SallyAPI::GUI::SendMessage::CParameterBase* messageParameter = NULL);
00072                         virtual void Enable(bool enable);
00073                         virtual void Timer(float timeDelta);
00074 
00075                         void SetValue(int value);
00076                         int GetValue();
00077 
00078                         int GetMinValue();
00079                         int GetMaxValue();
00080                         int GetSteps();
00081                         void SetMinValue(int value);
00082                         void SetMaxValue(int value);
00083                         void SetSteps(int value);
00084                 };
00085         }
00086 }
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines