Merge branch 'devel/master' into tizen
[platform/core/uifw/dali-adaptor.git] / dali / internal / window-system / common / window-event-interface.h
1 #ifndef DALI_INTERNAL_BASE_WINDOW_EVENT_INTERFACE_H
2 #define DALI_INTERNAL_BASE_WINDOW_EVENT_INTERFACE_H
3
4 /*
5  * Copyright (c) 2021 Samsung Electronics Co., Ltd.
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  *
19  */
20
21 // EXTERNAL INCLUDES
22 #include <dali/integration-api/events/key-event-integ.h>
23 #include <dali/integration-api/events/point.h>
24 #include <dali/public-api/events/key-event.h>
25 #include <dali/public-api/events/wheel-event.h>
26
27 namespace Dali
28 {
29 namespace Internal
30 {
31 namespace Adaptor
32 {
33 /**
34  * @brief Abstract interface for handling DALi events received from the native window system
35  *
36  */
37 class WindowEventInterface
38 {
39 public:
40   /**
41    * @brief Touch Event callback
42    * @param[in] point touch point
43    * @param[in] timeStamp time stamp
44    */
45   virtual void TouchEvent(Dali::Integration::Point& point, unsigned long timeStamp) = 0;
46
47   /**
48    * @brief Key Event callback
49    * @param[in] keyEvent key event
50    */
51   virtual void KeyEvent(Dali::Integration::KeyEvent& keyEvent) = 0;
52
53   /**
54    * @brief Wheel Event callback
55    * @param[in] wheelEvent wheel event
56    */
57   virtual void WheelEvent(Dali::WheelEvent& wheelEvent) = 0;
58
59   /**
60    * @brief Window damage callback
61    * @param[in] damageArea Window damage area
62    */
63   virtual void DamageEvent(Dali::Rect<int>& damageArea) = 0;
64
65   /**
66    * @brief Window Focused
67    */
68   virtual void WindowFocusIn() = 0;
69
70   /**
71    * @brief Window lost focus
72    */
73   virtual void WindowFocusOut() = 0;
74
75 protected:
76   /**
77    * @brief Constructor
78    */
79   WindowEventInterface()
80   {
81   }
82
83   /**
84    * Virtual destructor
85    */
86   virtual ~WindowEventInterface()
87   {
88   }
89
90   // Undefined copy constructor.
91   WindowEventInterface(const WindowEventInterface&);
92
93   // Undefined assignment operator.
94   WindowEventInterface& operator=(const WindowEventInterface&);
95 };
96
97 } // namespace Adaptor
98
99 } // namespace Internal
100
101 } // namespace Dali
102
103 #endif // DALI_INTERNAL_BASE_WINDOW_EVENT_INTERFACE_H