MyGUI  3.2.1
MyGUI_ControllerEdgeHide.h
Go to the documentation of this file.
00001 /*
00002  * This source file is part of MyGUI. For the latest info, see http://mygui.info/
00003  * Distributed under the MIT License
00004  * (See accompanying file COPYING.MIT or copy at http://opensource.org/licenses/MIT)
00005  */
00006 
00007 #ifndef __MYGUI_CONTROLLER_EDGE_HIDE_H__
00008 #define __MYGUI_CONTROLLER_EDGE_HIDE_H__
00009 
00010 #include "MyGUI_Prerequest.h"
00011 #include "MyGUI_WidgetDefines.h"
00012 #include "MyGUI_ControllerItem.h"
00013 #include "MyGUI_Types.h"
00014 
00015 namespace MyGUI
00016 {
00017 
00024     class MYGUI_EXPORT ControllerEdgeHide :
00025         public ControllerItem
00026     {
00027         MYGUI_RTTI_DERIVED( ControllerEdgeHide )
00028 
00029     public:
00030         ControllerEdgeHide();
00031         virtual ~ControllerEdgeHide();
00032 
00036         void setTime(float _value);
00037 
00041         void setRemainPixels(int _value);
00042 
00046         void setShadowSize(int _value);
00047 
00048         virtual void setProperty(const std::string& _key, const std::string& _value);
00049 
00050     private:
00051         bool addTime(Widget* _widget, float _time);
00052         void prepareItem(Widget* _widget);
00053 
00054         void recalculateTime(Widget* _widget);
00055 
00056         float mTime;
00057         int mRemainPixels;
00058         int mShadowSize;
00059         float mElapsedTime;
00060         // for checking if widget was moved
00061         MyGUI::IntCoord mLastCoord;
00062     };
00063 
00064 } // namespace MyGUI
00065 
00066 #endif // __MYGUI_CONTROLLER_EDGE_HIDE_H__