Fixed DGEUF-1841.
[platform/core/uifw/dali-demo.git] / examples / simple-visuals-control / my-control.cpp
1 /*
2  * Copyright (c) 2017 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 // CLASS HEADER
18 #include "my-control.h"
19
20 // INTERNAL INCLUDES
21 #include "my-control-impl.h"
22
23 namespace Demo
24 {
25
26 MyControl::MyControl()
27 {
28 }
29
30 MyControl::MyControl( const MyControl& control )
31 : Control( control )
32 {
33 }
34
35 MyControl& MyControl::operator= ( const MyControl& rhs )
36 {
37   if( &rhs != this )
38   {
39     Control::operator=( rhs );
40   }
41   return *this;
42 }
43
44 MyControl::~MyControl()
45 {
46 }
47
48 MyControl MyControl::New()
49 {
50   MyControl control = Internal::MyControl::New();
51   return control;
52 }
53
54 MyControl MyControl::DownCast( BaseHandle handle )
55 {
56   return Control::DownCast< MyControl, Internal::MyControl > ( handle );
57 }
58
59 MyControl::MyControl( Internal::MyControl& implementation )
60 : Control( implementation )
61 {
62 }
63
64 MyControl::MyControl( Dali::Internal::CustomActor* internal )
65 : Control( internal )
66 {
67   VerifyCustomActorPointer< Internal::MyControl >( internal ) ;
68 }
69
70
71 } //namespace Demo