Remove APIs deprecated in Tizen 3.0
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / public-api / controls / buttons / button.cpp
1 /*
2  * Copyright (c) 2019 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-toolkit/public-api/controls/buttons/button.h>
20
21 // EXTERNAL INCLUDES
22 #include <dali/integration-api/debug.h>
23 #include <dali/public-api/object/property-map.h>
24 #include <dali/public-api/images/resource-image.h>
25
26 // INTERNAL INCLUDES
27 #include <dali-toolkit/internal/controls/buttons/button-impl.h>
28 #include <dali-toolkit/public-api/controls/image-view/image-view.h>
29 #include <dali-toolkit/public-api/visuals/text-visual-properties.h>
30
31 namespace Dali
32 {
33
34 namespace Toolkit
35 {
36
37 Button::Button()
38 {}
39
40 Button::Button( const Button& button )
41 : Control( button )
42 {
43 }
44
45 Button& Button::operator=( const Button& button )
46 {
47   if( &button != this )
48   {
49     Control::operator=( button );
50   }
51   return *this;
52 }
53
54 Button::~Button()
55 {
56 }
57
58 Button Button::DownCast( BaseHandle handle )
59 {
60   return Control::DownCast<Button, Internal::Button>(handle);
61 }
62
63 Button::ButtonSignalType& Button::PressedSignal()
64 {
65   return Dali::Toolkit::GetImplementation( *this ).PressedSignal();
66 }
67
68 Button::ButtonSignalType& Button::ReleasedSignal()
69 {
70   return Dali::Toolkit::GetImplementation( *this ).ReleasedSignal();
71 }
72
73 Button::ButtonSignalType& Button::ClickedSignal()
74 {
75   return Dali::Toolkit::GetImplementation( *this ).ClickedSignal();
76 }
77
78 Button::ButtonSignalType& Button::StateChangedSignal()
79 {
80   return Dali::Toolkit::GetImplementation( *this ).StateChangedSignal();
81 }
82
83 Button::Button( Internal::Button& implementation )
84 : Control( implementation )
85 {
86 }
87
88 Button::Button( Dali::Internal::CustomActor* internal )
89 : Control( internal )
90 {
91   VerifyCustomActorPointer<Internal::Button>(internal);
92 }
93
94 } // namespace Toolkit
95
96 } // namespace Dali