Add an environment variable for long press gesture
[platform/core/uifw/dali-core.git] / dali / integration-api / input-options.cpp
1 #include "input-options.h"
2
3 #include <dali/internal/event/common/thread-local-storage.h>
4 #include <dali/internal/event/events/gesture-event-processor.h>
5
6 using Dali::Internal::GestureEventProcessor;
7 using Dali::Internal::ThreadLocalStorage;
8
9 namespace Dali
10 {
11
12 namespace Integration
13 {
14
15 void SetPanGesturePredictionMode( int mode )
16 {
17   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
18   eventProcessor.SetPanGesturePredictionMode(mode);
19 }
20
21 void SetPanGesturePredictionAmount( unsigned int amount )
22 {
23   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
24   eventProcessor.SetPanGesturePredictionAmount(amount);
25 }
26
27 void SetPanGestureMaximumPredictionAmount( unsigned int amount )
28 {
29   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
30   eventProcessor.SetPanGestureMaximumPredictionAmount(amount);
31 }
32
33 void SetPanGestureMinimumPredictionAmount( unsigned int amount )
34 {
35   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
36   eventProcessor.SetPanGestureMinimumPredictionAmount(amount);
37 }
38
39 void SetPanGesturePredictionAmountAdjustment( unsigned int amount )
40 {
41   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
42   eventProcessor.SetPanGesturePredictionAmountAdjustment(amount);
43 }
44
45 void SetPanGestureSmoothingMode( int mode )
46 {
47   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
48   eventProcessor.SetPanGestureSmoothingMode(mode);
49 }
50
51 void SetPanGestureSmoothingAmount( float amount )
52 {
53   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
54   eventProcessor.SetPanGestureSmoothingAmount(amount);
55 }
56
57 void SetPanGestureUseActualTimes( bool value )
58 {
59   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
60   eventProcessor.SetPanGestureUseActualTimes( value );
61 }
62
63 void SetPanGestureInterpolationTimeRange( int value )
64 {
65   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
66   eventProcessor.SetPanGestureInterpolationTimeRange( value );
67 }
68
69 void SetPanGestureScalarOnlyPredictionEnabled( bool value )
70 {
71   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
72   eventProcessor.SetPanGestureScalarOnlyPredictionEnabled( value );
73 }
74
75 void SetPanGestureTwoPointPredictionEnabled( bool value )
76 {
77   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
78   eventProcessor.SetPanGestureTwoPointPredictionEnabled( value );
79 }
80
81 void SetPanGestureTwoPointInterpolatePastTime( int value )
82 {
83   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
84   eventProcessor.SetPanGestureTwoPointInterpolatePastTime( value );
85 }
86
87 void SetPanGestureTwoPointVelocityBias( float value )
88 {
89   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
90   eventProcessor.SetPanGestureTwoPointVelocityBias( value );
91 }
92
93 void SetPanGestureTwoPointAccelerationBias( float value )
94 {
95   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
96   eventProcessor.SetPanGestureTwoPointAccelerationBias( value );
97 }
98
99 void SetPanGestureMultitapSmoothingRange( int value )
100 {
101   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
102   eventProcessor.SetPanGestureMultitapSmoothingRange( value );
103 }
104
105 void SetPanGestureMinimumDistance( int value )
106 {
107   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
108   eventProcessor.SetPanGestureMinimumDistance( value );
109 }
110
111 void SetPanGestureMinimumPanEvents( int value )
112 {
113   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
114   eventProcessor.SetPanGestureMinimumPanEvents( value );
115 }
116
117 void SetPinchGestureMinimumDistance( float value )
118 {
119   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
120   eventProcessor.SetPinchGestureMinimumDistance( value );
121 }
122
123 void SetLongPressMinimumHoldingTime( unsigned int value )
124 {
125   GestureEventProcessor& eventProcessor = ThreadLocalStorage::Get().GetGestureEventProcessor();
126   eventProcessor.SetLongPressMinimumHoldingTime( value );
127 }
128
129
130 } // namespace Integration
131
132 } // namespace Dali