2 // Open Service Platform
3 // Copyright (c) 2012-2013 Samsung Electronics Co., Ltd.
5 // Licensed under the Flora License, Version 1.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
9 // http://floralicense.org/license/
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an AS IS BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
19 * @file FUiCtrl_FastScroll.h
20 * @brief This is the header file for the _FastScroll class.
22 * This header file contains the declarations of the %_FastScroll class.
25 #ifndef _FUICTRL_INTERNAL_FASTSCROLL_H_
26 #define _FUICTRL_INTERNAL_FASTSCROLL_H_
28 #include "FUi_Control.h"
29 #include "FUiCtrl_IFastScrollListener.h"
30 #include "FUiCtrl_FastScrollPresenter.h"
31 #include "FUiCtrl_FastScrollIndex.h"
32 #include "FUi_IAccessibilityListener.h"
33 #include "FUi_AccessibilityContainer.h"
34 #include "FUi_AccessibilityElement.h"
35 #include "FUi_AccessibilityManager.h"
37 namespace Tizen { namespace Ui { namespace Controls
40 class _OSP_EXPORT_ _FastScroll
41 : public Tizen::Ui::_Control
42 , virtual public Tizen::Base::Runtime::IEventListener
43 , virtual public _IUiEventListener
44 , virtual public _IUiEventPreviewer
47 virtual ~_FastScroll(void);
49 static _FastScroll* CreateFastScrollN(Tizen::Ui::_Control& parentCtrl);
51 result SetIndex(_FastScrollIndex* pIndex);
52 _FastScrollIndex* GetIndex(void) const;
53 result UpdateIndex(void);
55 void EnableFadeEffect(bool enable);
56 bool IsEnabledFadeEffect(void) const;
57 bool IsOnFadeEffect(void) const;
58 result SetScrollVisibility(bool visibility);
59 bool GetScrollVisibility(void) const;
60 void CancelFadeEffect(void);
61 result InitializeAccessibility(void);
62 result AddAccessibilityElement(const Tizen::Ui::_AccessibilityContainer& control, bool onAccessibility);
64 void AddFastScrollEventListener(const Tizen::Ui::Controls::_IUiFastScrollListener& listener);
65 void RemoveFastScrollEventListener(const Tizen::Ui::Controls::_IUiFastScrollListener& listener);
67 void OnParentBoundsChanged(void);
69 virtual result OnAttachedToMainTree(void);
70 virtual void OnDraw(void);
71 virtual bool OnTouchPressed(const _Control& source, const _TouchInfo& touchinfo);
72 virtual bool OnTouchReleased(const _Control& source, const _TouchInfo& touchinfo);
73 virtual bool OnTouchMoved(const _Control& source, const _TouchInfo& touchinfo);
74 virtual bool OnTouchCanceled(const _Control& source, const _TouchInfo& touchinfo);
75 virtual void OnFontChanged(Tizen::Graphics::Font* pFont);
76 virtual void OnFontInfoRequested(unsigned long& style, int& size);
77 virtual Tizen::Ui::Animations::HitTestResult HitTest(const Tizen::Graphics::FloatPoint& point);
80 _FastScroll(const _FastScroll& rhs);
81 _FastScroll& operator =(const _FastScroll& rhs);
84 result Construct(Tizen::Ui::_Control& parentCtrl);
86 void SetPresenter(_FastScrollPresenter& fastScrollPresenter);
87 _FastScrollPresenter& GetPresenter(void) const;
90 _FastScrollPresenter* __pPresenter;
91 Tizen::Ui::_IAccessibilityListener* __pAccessibilityListener;
94 }}} // Tizen::Ui::Controls
96 #endif //_FUICTRL_INTERNAL_FASTSCROLL_H_