drag and drop: implements drag source events
[platform/core/uifw/dali-adaptor.git] / dali / internal / drag-and-drop / generic / drag-and-drop-impl-generic.h
1 #ifndef DALI_INTERNAL_DRAG_AND_DROP_GENERIC_H
2 #define DALI_INTERNAL_DRAG_AND_DROP_GENERIC_H
3
4 /*
5  * Copyright (c) 2022 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 // INTERNAL INCLUDES
22 #include <dali/internal/drag-and-drop/common/drag-and-drop-impl.h>
23
24 namespace Dali
25 {
26 class DragAndDrop;
27
28 namespace Internal
29 {
30 namespace Adaptor
31 {
32
33 /**
34  * DragAndDrop Implementation
35  */
36 class DragAndDropGeneric : public Dali::Internal::Adaptor::DragAndDrop
37 {
38 public:
39   /**
40    * Constructor
41    */
42   DragAndDropGeneric();
43
44   /**
45    * Destructor
46    */
47   ~DragAndDropGeneric() override;
48
49   /**
50    * @copydoc Dali::DragAndDrop::StartDragAndDrop()
51    */
52   bool StartDragAndDrop(Dali::Actor source, Dali::Window shadowWindow, const Dali::DragAndDrop::DragData& data, Dali::DragAndDrop::SourceFunction callback) override;
53
54   /**
55    * @copydoc Dali::DragAndDrop::AddListener()
56    */
57   bool AddListener(Dali::Actor target, Dali::DragAndDrop::DragAndDropFunction callback) override;
58
59   /**
60    * @copydoc Dali::DragAndDrop::RemoveListener()
61    */
62   bool RemoveListener(Dali::Actor target) override;
63
64   /**
65    * @copydoc Dali::DragAndDrop::SendData()
66    */
67   void SendData(void* event) override;
68
69   /**
70    * @copydoc Dali::DragAndDrop::ReceiveData()
71    */
72   void ReceiveData(void* event) override;
73
74   /**
75    * @copydoc Dali::DragAndDrop::CalculateDragEvent()
76    */
77   bool CalculateDragEvent(void* event) override;
78
79   /**
80    * @copydoc Dali::DragAndDrop::CalculateViewRegion()
81    */
82   bool CalculateViewRegion(void* event) override;
83
84 private:
85   DragAndDropGeneric(const DragAndDropGeneric&) = delete;
86   DragAndDropGeneric& operator=(DragAndDropGeneric&) = delete;
87   DragAndDropGeneric(DragAndDropGeneric&&) = delete;
88   DragAndDropGeneric& operator=(DragAndDropGeneric&&) = delete;
89
90 public:
91 }; // class DragAndDropGeneric
92
93 } // namespace Adaptor
94
95 } // namespace Internal
96
97 } // namespace Dali
98
99 #endif // DALI_INTERNAL_DRAG_AND_DROP_GENERIC_H