X-Git-Url: http://review.tizen.org/git/?p=platform%2Fcore%2Fuifw%2Fdali-core.git;a=blobdiff_plain;f=dali%2Finternal%2Fevent%2Fevents%2Ftap-gesture-processor.h;h=df64cb7d45ac01242c52103870469f2a0d9610c2;hp=f391987a18d52521e0cdc2d741240baed03879ac;hb=2ada356619fc41af1f590e9d471352d8ce475a83;hpb=5f65ad090d18807d8c7fefb4795a858f6edf8056 diff --git a/dali/internal/event/events/tap-gesture-processor.h b/dali/internal/event/events/tap-gesture-processor.h index f391987..df64cb7 100644 --- a/dali/internal/event/events/tap-gesture-processor.h +++ b/dali/internal/event/events/tap-gesture-processor.h @@ -1,8 +1,8 @@ -#ifndef __DALI_INTERNAL_TAP_GESTURE_EVENT_PROCESSOR_H__ -#define __DALI_INTERNAL_TAP_GESTURE_EVENT_PROCESSOR_H__ +#ifndef DALI_INTERNAL_TAP_GESTURE_EVENT_PROCESSOR_H +#define DALI_INTERNAL_TAP_GESTURE_EVENT_PROCESSOR_H /* - * Copyright (c) 2014 Samsung Electronics Co., Ltd. + * Copyright (c) 2019 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -26,13 +26,6 @@ namespace Dali { -namespace Integration -{ -class GestureManager; -struct GestureEvent; -struct TapGestureEvent; -} - namespace Internal { @@ -40,6 +33,9 @@ class Scene; class Stage; class Actor; +struct GestureEvent; +struct TapGestureEvent; + /** * Tap Gesture Event Processing: * @@ -47,7 +43,7 @@ class Actor; * - Find the actor that requires a tap where the tap occurred. * - Emit the gesture if the tap gesture event satisfies the detector conditions. */ -class TapGestureProcessor : public GestureProcessor +class TapGestureProcessor : public GestureProcessor, public RecognizerObserver { public: @@ -55,7 +51,7 @@ public: * Create a tap gesture processor. * @param[in] gestureManager The gesture manager. */ - TapGestureProcessor( Integration::GestureManager& gestureManager ); + TapGestureProcessor(); /** * Non-virtual destructor; TapGestureProcessor is not a base class @@ -69,7 +65,7 @@ public: // To be called by GestureEventProcessor * @param[in] scene The scene the tap gesture event occurs in. * @param[in] tapEvent The event that has occurred. */ - void Process( Scene& scene, const Integration::TapGestureEvent& tapEvent); + void Process( Scene& scene, const TapGestureEvent& event); /** * Adds a gesture detector to this gesture processor. @@ -77,7 +73,7 @@ public: // To be called by GestureEventProcessor * gesture with the adaptor. * @param[in] gestureDetector The gesture detector being added. */ - void AddGestureDetector(TapGestureDetector* gestureDetector); + void AddGestureDetector(TapGestureDetector* gestureDetector, Scene& scene); /** * Removes the specified gesture detector from this gesture processor. If, after removing this @@ -126,8 +122,7 @@ private: private: - Integration::GestureManager& mGestureManager; - TapGestureDetectorContainer mGestureDetectors; + TapGestureDetectorContainer mTapGestureDetectors; unsigned int mMinTapsRequired; unsigned int mMaxTapsRequired; @@ -135,7 +130,7 @@ private: unsigned int mMaxTouchesRequired; ActorObserver mCurrentTapActor; ///< Observer for the current gesture actor - const Integration::TapGestureEvent* mCurrentTapEvent; ///< Pointer to current TapEvent, used when calling ProcessAndEmit() + const TapGestureEvent* mCurrentTapEvent; ///< Pointer to current TapEvent, used when calling ProcessAndEmit() bool mPossibleProcessed; ///< Indication of whether we've processed a touch down for this gestuee }; @@ -143,4 +138,4 @@ private: } // namespace Dali -#endif // __DALI_INTERNAL_TAP_GESTURE_EVENT_PROCESSOR_H__ +#endif // DALI_INTERNAL_TAP_GESTURE_EVENT_PROCESSOR_H