Revert "[Tizen] Do not substarct outline width in text-controller"
[platform/core/uifw/dali-toolkit.git] / automated-tests / src / dali-toolkit / dali-toolkit-test-utils / toolkit-web-view-lite.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
18 // CLASS HEADER
19 #include "toolkit-web-view-lite.h"
20
21 namespace Dali
22 {
23
24 namespace Internal
25 {
26
27 namespace Adaptor
28 {
29
30 class WebViewLite: public Dali::BaseObject
31 {
32 public:
33
34   WebViewLite()
35   {
36   }
37
38 public:
39   Dali::WebEngineLitePlugin::WebEngineLiteSignalType mFinishedSignal;
40
41 private:
42 };
43
44 inline WebViewLite& GetImplementation( Dali::WebEngineLite& webViewLite )
45 {
46   DALI_ASSERT_ALWAYS(webViewLite && "WebViewLite handle is empty");
47   BaseObject& handle = webViewLite.GetBaseObject();
48   return static_cast< Internal::Adaptor::WebEngineLite& >( handle );
49 }
50
51 inline const WebViewLite& GetImplementation( const Dali::WebEngineLite& webViewLite )
52 {
53   DALI_ASSERT_ALWAYS(webViewLite && "WebViewLite handle is empty");
54   const BaseObject& handle = webViewLite.GetBaseObject();
55   return static_cast< const Internal::Adaptor::WebEngineLite& >( handle );
56 }
57
58 } // namespace Adaptor
59
60 } // namespace Internal
61
62
63 /********************************************************************************/
64 /*********************************  PUBLIC CLASS  *******************************/
65 /********************************************************************************/
66
67 WebViewLite::WebViewLite()
68 {
69 }
70
71 WebViewLite::WebViewLite( Internal::Adaptor::WebEngineLite* internal )
72 : BaseHandle( internal )
73 {
74 }
75
76 WebViewLite::~WebViewLite()
77 {
78 }
79
80 WebViewLite WebViewLite::New()
81 {
82   Internal::Adaptor::WebEngineLite* webViewLite = new Internal::Adaptor::WebEngineLite();
83
84   return WebViewLite( webViewLite );
85 }
86
87 WebViewLite::WebViewLite( const WebViewLite& webViewLite )
88 : BaseHandle( webViewLite )
89 {
90 }
91
92 WebViewLite& WebViewLite::operator=( const WebViewLite& webViewLite )
93 {
94   BaseHandle::operator=( webViewLite );
95   return *this;
96 }
97
98 WebViewLite WebViewLite::DownCast( BaseHandle handle )
99 {
100   WebViewLite webViewLite;
101   return webViewLite;
102 }
103
104 void WebViewLite::CreateInstance(int width, int height, int windowX, int windowY, const std::sting& locale, const std::string& timezoneID)
105 {
106   Internal::Adaptor::GetImplementation( *this ).CreateInstance(width, height, windowX, windowY, locale, timezoneID);
107 }
108
109 void WebViewLite::DestroyInstance()
110 {
111   Internal::Adaptor::GetImplementation( *this ).DestroyInstance();
112 }
113
114 void WebViewLite::LoadHtml(const std::string& path)
115 {
116   return Internal::Adaptor::GetImplementation( *this ).LoadHtml(path);
117 }
118
119 Dali::WebEngineLitePlugin::WebEngineLiteSignalType& WebViewLite::FinishedSignal()
120 {
121   return Internal::Adaptor::GetImplementation( *this ).mFinishedSignal;
122 }
123
124 } // namespace Dali;
125