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.
18 * @file FUi_TouchTapGestureDetector.h
19 * @brief This is the header file for the %_TouchTapGestureDetector class.
21 * This header file contains the declarations of the %_TouchTapGestureDetector class.
23 #ifndef _FUI_INTERNAL_TOUCH_TAP_GESTURE_DETECTOR_H_
24 #define _FUI_INTERNAL_TOUCH_TAP_GESTURE_DETECTOR_H_
26 #include "FUi_TouchGestureDetector.h"
27 #include "FUi_UiTouchEvent.h"
29 namespace Tizen { namespace Ui
31 class _TouchGestureTimerManager;
34 * @class _TouchTapGestureDetector
39 class _OSP_EXPORT_ _TouchTapGestureDetector
40 : public _TouchGestureDetector
43 _TouchTapGestureDetector(void);
44 virtual ~_TouchTapGestureDetector(void);
46 result SetTapCount(int count);
47 int GetTapCount(void) const;
49 result SetTapInterval(long interval);
50 long GetTapInterval(void) const;
52 result SetTouchCount(int count);
53 int GetTouchCount(void) const;
55 //apply only one touch count
56 result SetMoveAllowance(int allowance);
57 int GetMoveAllowance(void) const;
59 result SetMoveAllowance(float allowance);
60 float GetMoveAllowanceF(void) const;
62 bool IsInBounds(void);
63 void ClearTapInfoList(void);
64 bool IsAllTapped(void);
66 virtual bool OnTouchPressed(const Tizen::Ui::_Control& source, const Tizen::Ui::_TouchInfo& touchinfo);
67 virtual bool OnTouchMoved(const Tizen::Ui::_Control& source, const Tizen::Ui::_TouchInfo& touchinfo);
68 virtual bool OnTouchReleased(const Tizen::Ui::_Control& source, const Tizen::Ui::_TouchInfo& touchinfo);
69 virtual bool OnTouchCanceled(const Tizen::Ui::_Control& source, const Tizen::Ui::_TouchInfo& touchinfo);
72 _TouchTapGestureDetector(const _TouchTapGestureDetector& value);
73 _TouchTapGestureDetector& operator =(const _TouchTapGestureDetector& value);
75 void RemoveTapInfoList(void);
81 float __oneTapMoveAllowance;
82 bool __oneTapIsInBounds;
83 unsigned int __maxPointId;
84 Tizen::Graphics::FloatPoint __oneTapStartPoint;
85 _TouchGestureTimerManager* __pGestureTimerManager;
88 Tizen::Base::Collection::ArrayListT<_TapInfo*>* __pTapInfoList;
89 }; // _TapGestureDetector
93 #endif //_FUI_INTERNAL_TOUCH_TAP_GESTURE_DETECTOR_H_