[dali_2.3.25] Merge branch 'devel/master'
[platform/core/uifw/dali-adaptor.git] / dali / devel-api / adaptor-framework / clipboard.cpp
1 /*
2  * Copyright (c) 2023 Samsung Electronics Co., Ltd.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  *
16  */
17
18 // CLASS HEADER
19 #include <dali/devel-api/adaptor-framework/clipboard.h>
20
21 // INTERNAL INCLUDES
22 #include <dali/internal/clipboard/common/clipboard-impl.h>
23
24 namespace Dali
25 {
26 Clipboard::Clipboard()
27 {
28 }
29
30 Clipboard::~Clipboard()
31 {
32 }
33
34 Clipboard::Clipboard(Internal::Adaptor::Clipboard* impl)
35 : BaseHandle(impl)
36 {
37 }
38
39 Clipboard Clipboard::Get()
40 {
41   return Internal::Adaptor::Clipboard::Get();
42 }
43
44 bool Clipboard::IsAvailable()
45 {
46   return Internal::Adaptor::Clipboard::IsAvailable();
47 }
48
49 Clipboard::DataSentSignalType& Clipboard::DataSentSignal()
50 {
51   return GetImplementation(*this).DataSentSignal();
52 }
53
54 Clipboard::DataReceivedSignalType& Clipboard::DataReceivedSignal()
55 {
56   return GetImplementation(*this).DataReceivedSignal();
57 }
58
59 Clipboard::DataSelectedSignalType& Clipboard::DataSelectedSignal()
60 {
61   return GetImplementation(*this).DataSelectedSignal();
62 }
63
64 bool Clipboard::HasType(const std::string& mimeType)
65 {
66   return GetImplementation(*this).HasType(mimeType);
67 }
68
69 bool Clipboard::SetData(const ClipData& clipData)
70 {
71   return GetImplementation(*this).SetData(clipData);
72 }
73
74 uint32_t Clipboard::GetData(const std::string& mimeType)
75 {
76   return GetImplementation(*this).GetData(mimeType);
77 }
78
79 size_t Clipboard::NumberOfItems()
80 {
81   return GetImplementation(*this).NumberOfItems();
82 }
83
84 void Clipboard::ShowClipboard()
85 {
86   GetImplementation(*this).ShowClipboard();
87 }
88
89 void Clipboard::HideClipboard()
90 {
91   GetImplementation(*this).HideClipboard(false);
92 }
93
94 bool Clipboard::IsVisible() const
95 {
96   return GetImplementation(*this).IsVisible();
97 }
98
99 } // namespace Dali