[Tizen] Implement WebViewLite interface 91/148291/4 accepted/tizen/4.0/unified/20170913.003402 submit/tizen_4.0/20170908.031457
authorgloryj.kim <gloryj.kim@samsung.com>
Fri, 23 Jun 2017 11:02:33 +0000 (20:02 +0900)
committergloryj.kim <gloryj.kim@samsung.com>
Fri, 8 Sep 2017 05:22:56 +0000 (14:22 +0900)
Change-Id: I28ab2d00b9f0a302dbe01e525c3b910d93795e99
Signed-off-by: gloryj.kim <gloryj.kim@samsung.com>
automated-tests/src/dali-toolkit/CMakeLists.txt
automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-web-view-lite.cpp [new file with mode: 0644]
automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-web-view-lite.h [new file with mode: 0644]
build/tizen/dali-toolkit/Makefile.am
dali-toolkit/devel-api/controls/web-view-lite/web-view-lite.cpp [new file with mode: 0644]
dali-toolkit/devel-api/controls/web-view-lite/web-view-lite.h [new file with mode: 0644]
dali-toolkit/devel-api/file.list
dali-toolkit/internal/controls/web-view-lite/web-view-lite-impl.cpp [new file with mode: 0644]
dali-toolkit/internal/controls/web-view-lite/web-view-lite-impl.h [new file with mode: 0644]
dali-toolkit/internal/file.list

index d3b5bba50023352d1bdb0da21bcc24bbbd8a3bc2..7c757ead4644f64e39adcab067dc3ecf7dfa298a 100755 (executable)
@@ -85,6 +85,7 @@ LIST(APPEND TC_SOURCES
    dali-toolkit-test-utils/toolkit-native-image-source.cpp
    dali-toolkit-test-utils/toolkit-video-player.cpp
    dali-toolkit-test-utils/toolkit-trigger-event-factory.cpp
+   dali-toolkit-test-utils/toolkit-web-view-lite.cpp
    dali-toolkit-test-utils/dali-test-suite-utils.cpp
    dali-toolkit-test-utils/dummy-control.cpp
    dali-toolkit-test-utils/mesh-builder.cpp
diff --git a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-web-view-lite.cpp b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-web-view-lite.cpp
new file mode 100644 (file)
index 0000000..be0611d
--- /dev/null
@@ -0,0 +1,125 @@
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+// CLASS HEADER
+#include "toolkit-web-view-lite.h"
+
+namespace Dali
+{
+
+namespace Internal
+{
+
+namespace Adaptor
+{
+
+class WebViewLite: public Dali::BaseObject
+{
+public:
+
+  WebViewLite()
+  {
+  }
+
+public:
+  Dali::WebEngineLitePlugin::WebEngineLiteSignalType mFinishedSignal;
+
+private:
+};
+
+inline WebViewLite& GetImplementation( Dali::WebEngineLite& webViewLite )
+{
+  DALI_ASSERT_ALWAYS(webViewLite && "WebViewLite handle is empty");
+  BaseObject& handle = webViewLite.GetBaseObject();
+  return static_cast< Internal::Adaptor::WebEngineLite& >( handle );
+}
+
+inline const WebViewLite& GetImplementation( const Dali::WebEngineLite& webViewLite )
+{
+  DALI_ASSERT_ALWAYS(webViewLite && "WebViewLite handle is empty");
+  const BaseObject& handle = webViewLite.GetBaseObject();
+  return static_cast< const Internal::Adaptor::WebEngineLite& >( handle );
+}
+
+} // namespace Adaptor
+
+} // namespace Internal
+
+
+/********************************************************************************/
+/*********************************  PUBLIC CLASS  *******************************/
+/********************************************************************************/
+
+WebViewLite::WebViewLite()
+{
+}
+
+WebViewLite::WebViewLite( Internal::Adaptor::WebEngineLite* internal )
+: BaseHandle( internal )
+{
+}
+
+WebViewLite::~WebViewLite()
+{
+}
+
+WebViewLite WebViewLite::New()
+{
+  Internal::Adaptor::WebEngineLite* webViewLite = new Internal::Adaptor::WebEngineLite();
+
+  return WebViewLite( webViewLite );
+}
+
+WebViewLite::WebViewLite( const WebViewLite& webViewLite )
+: BaseHandle( webViewLite )
+{
+}
+
+WebViewLite& WebViewLite::operator=( const WebViewLite& webViewLite )
+{
+  BaseHandle::operator=( webViewLite );
+  return *this;
+}
+
+WebViewLite WebViewLite::DownCast( BaseHandle handle )
+{
+  WebViewLite webViewLite;
+  return webViewLite;
+}
+
+void WebViewLite::CreateInstance(int width, int height, int windowX, int windowY, const std::sting& locale, const std::string& timezoneID)
+{
+  Internal::Adaptor::GetImplementation( *this ).CreateInstance(width, height, windowX, windowY, locale, timezoneID);
+}
+
+void WebViewLite::DestroyInstance()
+{
+  Internal::Adaptor::GetImplementation( *this ).DestroyInstance();
+}
+
+void WebViewLite::LoadHtml(const std::string& path)
+{
+  return Internal::Adaptor::GetImplementation( *this ).LoadHtml(path);
+}
+
+Dali::WebEngineLitePlugin::WebEngineLiteSignalType& WebViewLite::FinishedSignal()
+{
+  return Internal::Adaptor::GetImplementation( *this ).mFinishedSignal;
+}
+
+} // namespace Dali;
+
diff --git a/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-web-view-lite.h b/automated-tests/src/dali-toolkit/dali-toolkit-test-utils/toolkit-web-view-lite.h
new file mode 100644 (file)
index 0000000..9969e3d
--- /dev/null
@@ -0,0 +1,75 @@
+#ifndef __DALI_TOOLKIT_WEBVIEWLITE_H__
+#define __DALI_TOOLKIT_WEBVIEWLITE_H__
+
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+// EXTERNAL INCLUDES
+#include <dali/public-api/object/base-handle.h>
+#include <dali/public-api/object/base-object.h>
+
+#include <dali/devel-api/adaptor-framework/web-engine-lite-plugin.h>
+
+namespace Dali
+{
+
+namespace Internal
+{
+
+namespace Adaptor
+{
+
+class WebViewLite;
+}
+}
+
+/**
+ * @brief WebViewLite class is used for Web.
+ */
+class WebViewLite: public BaseHandle
+{
+public:
+
+  WebViewLite();
+
+  ~WebViewLite();
+
+  static WebViewLite New();
+
+  WebViewLite( const WebViewLite& webViewLite );
+
+  WebViewLite& operator=( const WebViewLite& webViewLite );
+
+  static WebViewLite DownCast( BaseHandle handle );
+
+  void CreateInstance(int width, int height, int windowX, int windowY, const std::string& locale, const std::string& timezoneID);
+
+  void DestroyInstance();
+
+  void LoadHtml(const std::string& path);
+
+  Dali::WebEngineLitePlugin::WebEngineLiteSignalType& FinishedSignal();
+
+private:
+
+  WebViewLite( Internal::Adaptor::WebEngineLite* internal );
+
+};
+
+} // namespace Dali;
+
+#endif
index c2f73c3a643ef6d2f147a0be39159f270c6502b6..ef35d5efa9e3ee9e576129aabf2c272eaa00369e 100644 (file)
@@ -123,6 +123,7 @@ develapitransitioneffectsdir =  $(develapidir)/transition-effects
 develapitoolbardir =            $(develapicontrolsdir)/tool-bar
 develapitooltipdir =            $(develapicontrolsdir)/tooltip
 develapitextselectionpopupdir = $(develapicontrolsdir)/text-controls
+develapiwebviewlitedir =        $(develapicontrolsdir)/web-view-lite
 develapivisualfactorydir =      $(develapidir)/visual-factory
 develapivisualsdir =            $(develapidir)/visuals
 
@@ -156,6 +157,7 @@ develapitoolbar_HEADERS =           $(devel_api_tool_bar_header_files)
 develapitooltip_HEADERS =           $(devel_api_tooltip_header_files)
 develapitransitioneffects_HEADERS = $(devel_api_transition_effects_header_files)
 develapitextselectionpopup_HEADERS = $(devel_api_text_controls_header_files)
+develapiwebviewlite_HEADERS =       $(devel_api_web_view_lite_header_files)
 
 # public api source
 publicapidir =                     $(topleveldir)/public-api
diff --git a/dali-toolkit/devel-api/controls/web-view-lite/web-view-lite.cpp b/dali-toolkit/devel-api/controls/web-view-lite/web-view-lite.cpp
new file mode 100644 (file)
index 0000000..feaf80b
--- /dev/null
@@ -0,0 +1,96 @@
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+// CLASS HEADER
+#include <dali-toolkit/devel-api/controls/web-view-lite/web-view-lite.h>
+
+// INTERNAL INCLUDES
+#include <dali-toolkit/internal/controls/web-view-lite/web-view-lite-impl.h>
+
+namespace Dali
+{
+
+namespace Toolkit
+{
+
+WebViewLite::WebViewLite()
+{
+}
+
+WebViewLite::WebViewLite( const WebViewLite& webViewLite )
+: Control( webViewLite )
+{
+}
+
+WebViewLite& WebViewLite::operator=( const WebViewLite& webViewLite )
+{
+  if( &webViewLite != this )
+  {
+    Control::operator=( webViewLite );
+  }
+
+  return *this;
+}
+
+WebViewLite::~WebViewLite()
+{
+}
+
+WebViewLite WebViewLite::New()
+{
+  return Internal::WebViewLite::New();
+}
+
+WebViewLite WebViewLite::DownCast( BaseHandle handle )
+{
+  return Control::DownCast< WebViewLite, Internal::WebViewLite >( handle );
+}
+
+void WebViewLite::CreateInstance(int width, int height, int windowX, int windowY, const std::string& locale, const std::string& timezoneID)
+{
+  Dali::Toolkit::GetImpl( *this ).CreateInstance(width, height, windowX, windowY, locale, timezoneID);
+}
+
+void WebViewLite::DestroyInstance()
+{
+  Dali::Toolkit::GetImpl( *this ).DestroyInstance();
+}
+
+void WebViewLite::LoadHtml(const std::string& path)
+{
+  Dali::Toolkit::GetImpl( *this ).LoadHtml(path);
+}
+
+WebViewLite::WebViewLiteSignalType& WebViewLite::FinishedSignal()
+{
+  return Dali::Toolkit::GetImpl( *this ).FinishedSignal();
+}
+
+WebViewLite::WebViewLite( Internal::WebViewLite& implementation )
+: Control( implementation )
+{
+}
+
+WebViewLite::WebViewLite( Dali::Internal::CustomActor* internal )
+: Control( internal )
+{
+  VerifyCustomActorPointer< Internal::WebViewLite >( internal );
+}
+
+} // namespace Toolkit
+
+} // namespace Dali
diff --git a/dali-toolkit/devel-api/controls/web-view-lite/web-view-lite.h b/dali-toolkit/devel-api/controls/web-view-lite/web-view-lite.h
new file mode 100644 (file)
index 0000000..7f2cbae
--- /dev/null
@@ -0,0 +1,149 @@
+#ifndef __DALI_TOOLKIT_WEB_VIEW_LITE_H__
+#define __DALI_TOOLKIT_WEB_VIEW_LITE_H__
+
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+// INTERNAL INCLUDES
+#include <dali-toolkit/public-api/controls/control.h>
+
+namespace Dali
+{
+
+namespace Toolkit
+{
+
+namespace Internal DALI_INTERNAL
+{
+  class WebViewLite;
+} // namespace Internal
+
+class DALI_IMPORT_API WebViewLite: public Control
+{
+public:
+
+  typedef Signal< void (WebViewLite&) > WebViewLiteSignalType;
+
+public:
+
+  /**
+   * @brief Creates an initialized WebViewLite.
+   *
+   * @return A handle to a newly allocated Dali WebViewLite
+   *
+   * @note WebViewLite will not display anything
+   */
+  static WebViewLite New();
+
+  /**
+   * @brief Creates an uninitialized WebViewLite.
+   */
+  WebViewLite();
+
+  /**
+   * @brief Destructor.
+   *
+   * This is non-virtual since derived Handel types must not contain data or virtual methods.
+   */
+  ~WebViewLite();
+
+  /*
+   * @brief Copy constructor.
+   *
+   * @param[in] webViewLite WebViewLite to copy. The copied WebViewLite will point at the same implementation
+   */
+  WebViewLite( const WebViewLite& webViewLite );
+
+  /**
+   * @brief Assignment operator.
+   *
+   * @param[in] webViewLite The WebViewLite to assign from
+   * @return The updated WebViewLite
+   */
+  WebViewLite& operator=( const WebViewLite& webViewLite );
+
+  /**
+   * @brief Downcasts a handle to WebViewLite handle.
+   *
+   * If handle points to a WebViewLite, the downcast produces valid handle.
+   * If not, the returned handle is left uninitialized.
+   *
+   * @param[in] handle Handle to an object
+   * @return Handle to a WebViewLite or an uninitialized handle
+   */
+  static WebViewLite DownCast( BaseHandle handle );
+
+  /**
+   * @brief Creates an internal web view instance (e.g. minimized web engine instance)
+   *
+   * @param [in] width The width of Web
+   * @param [in] height The height of Web
+   * @param [in] windowX The x position of window
+   * @param [in] windowY The y position of window
+   * @param [in] locale The locale of Web
+   * @param [in] timezoneID The timezoneID of Web
+   */
+  void CreateInstance(int width, int height, int windowX, int windowY, const std::string& locale, const std::string& timezoneID);
+
+  /**
+   * @brief Destroys an internal web view instance (e.g. minimized web engine instance)
+   */
+  void DestroyInstance();
+
+  /**
+   * @brief Loads a html file
+   *
+   * @param [in] path The path of Web
+   */
+  void LoadHtml(const std::string& path);
+
+  /**
+   * @brief Connects to this signal to be notified when a web view is finished.
+   *
+   * @return A signal object to connect with
+   */
+  WebViewLiteSignalType& FinishedSignal();
+
+public: // Not intended for application developers
+
+  /// @cond internal
+  /**
+   * @brief Creates a handle using the Toolkit::Internal implementation.
+   *
+   * @param[in] implementation The WebViewLite implementation
+   */
+  DALI_INTERNAL WebViewLite( Internal::WebViewLite& implementation );
+
+  /**
+   * @brief Allows the creation of this WebViewLite from an Internal::CustomActor pointer.
+   *
+   * @param[in] internal A pointer to the internal CustomActor
+   */
+  DALI_INTERNAL WebViewLite( Dali::Internal::CustomActor* internal );
+  /// @endcond
+
+};
+
+/**
+ * @}
+ */
+
+} // namespace Toolkit
+
+} // namespace Dali
+
+#endif // __DALI_TOOLKIT_WEB_VIEW_LITE_H__
index 7f4308b8842242c382fce6fbcd1bce387fb6c1b1..4ebb3398338a566ba386db27fdc8c120af21d03b 100644 (file)
@@ -25,6 +25,7 @@ devel_api_src_files = \
   $(devel_api_src_dir)/controls/text-controls/text-selection-toolbar.cpp \
   $(devel_api_src_dir)/controls/text-controls/text-editor-devel.cpp \
   $(devel_api_src_dir)/controls/tool-bar/tool-bar.cpp \
+  $(devel_api_src_dir)/controls/web-view-lite/web-view-lite.cpp \
   $(devel_api_src_dir)/focus-manager/keyinput-focus-manager.cpp \
   $(devel_api_src_dir)/focus-manager/keyboard-focus-manager-devel.cpp \
   $(devel_api_src_dir)/image-loader/async-image-loader-devel.cpp \
@@ -162,3 +163,6 @@ devel_api_transition_effects_header_files = \
 
 devel_api_gaussian_blur_view_header_files = \
   $(devel_api_src_dir)/controls/gaussian-blur-view/gaussian-blur-view.h
+
+devel_api_web_view_lite_header_files = \
+  $(devel_api_src_dir)/controls/web-view-lite/web-view-lite.h
\ No newline at end of file
diff --git a/dali-toolkit/internal/controls/web-view-lite/web-view-lite-impl.cpp b/dali-toolkit/internal/controls/web-view-lite/web-view-lite-impl.cpp
new file mode 100644 (file)
index 0000000..4aff712
--- /dev/null
@@ -0,0 +1,133 @@
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+// CLASS HEADER
+#include "web-view-lite-impl.h"
+
+// EXTERNAL INCLUDES
+#include <cstring>
+#include <dali/public-api/object/type-registry.h>
+#include <dali/public-api/object/type-registry-helper.h>
+#include <dali/integration-api/adaptors/adaptor.h>
+
+// INTERNAL INCLUDES
+#include <dali-toolkit/devel-api/controls/web-view-lite/web-view-lite.h>
+
+namespace Dali
+{
+
+namespace Toolkit
+{
+
+namespace Internal
+{
+
+namespace
+{
+
+BaseHandle Create()
+{
+  return Toolkit::WebViewLite::New();
+}
+
+DALI_TYPE_REGISTRATION_BEGIN( Toolkit::WebViewLite, Toolkit::Control, Create );
+
+DALI_SIGNAL_REGISTRATION( Toolkit, WebViewLite, "finished", FINISHED_SIGNAL )
+
+DALI_TYPE_REGISTRATION_END()
+
+} // anonymous namepsace
+
+WebViewLite::WebViewLite()
+: Control( ControlBehaviour( ACTOR_BEHAVIOUR_DEFAULT | DISABLE_STYLE_CHANGE_SIGNALS ) )
+{
+  mWebViewLite = Dali::WebEngineLite::New();
+}
+
+WebViewLite::~WebViewLite()
+{
+}
+
+Toolkit::WebViewLite WebViewLite::New()
+{
+  WebViewLite* impl = new WebViewLite();
+  Toolkit::WebViewLite handle = Toolkit::WebViewLite( *impl );
+
+  impl->Initialize();
+
+  return handle;
+}
+
+void WebViewLite::OnInitialize()
+{
+  mWebViewLite.FinishedSignal().Connect( this, &WebViewLite::EmitFinishedSignal );
+}
+
+void WebViewLite::CreateInstance(int width, int height, int windowX, int windowY, const std::string& locale, const std::string& timezoneID)
+{
+  mWebViewLite.CreateInstance(width, height, windowX, windowY, locale, timezoneID);
+}
+
+void WebViewLite::DestroyInstance()
+{
+  mWebViewLite.DestroyInstance();
+}
+
+void WebViewLite::LoadHtml(const std::string& path)
+{
+  mWebViewLite.LoadHtml(path);
+}
+
+Dali::Toolkit::WebViewLite::WebViewLiteSignalType& WebViewLite::FinishedSignal()
+{
+  return mFinishedSignal;
+}
+
+void WebViewLite::EmitFinishedSignal()
+{
+  if ( !mFinishedSignal.Empty() )
+  {
+    Dali::Toolkit::WebViewLite handle( GetOwner() );
+    mFinishedSignal.Emit( handle );
+  }
+}
+
+bool WebViewLite::DoConnectSignal( BaseObject* object, ConnectionTrackerInterface* tracker, const std::string& signalName, FunctorDelegate* functor )
+{
+  Dali::BaseHandle handle( object );
+
+  bool connected( true );
+  Toolkit::WebViewLite webViewLite = Toolkit::WebViewLite::DownCast( handle );
+
+  if( 0 == strcmp( signalName.c_str(), FINISHED_SIGNAL ) )
+  {
+    webViewLite.FinishedSignal().Connect( tracker, functor );
+  }
+  else
+  {
+    // signalName does not match any signal
+    connected = false;
+  }
+
+  return connected;
+}
+
+} // namespace Internal
+
+} // namespace Toolkit
+
+} // namespace Dali
diff --git a/dali-toolkit/internal/controls/web-view-lite/web-view-lite-impl.h b/dali-toolkit/internal/controls/web-view-lite/web-view-lite-impl.h
new file mode 100644 (file)
index 0000000..8fccfa8
--- /dev/null
@@ -0,0 +1,122 @@
+#ifndef DALI_TOOLKIT_INTERNAL_WEB_VIEW_LITE_H
+#define DALI_TOOLKIT_INTERNAL_WEB_VIEW_LITE_H
+
+/*
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+// EXTERNAL INCLUDES
+#include <dali/devel-api/adaptor-framework/web-engine-lite.h>
+
+// INTERNAL INCLUDES
+#include <dali-toolkit/internal/visuals/image/image-visual.h>
+#include <dali-toolkit/public-api/controls/control-impl.h>
+#include <dali-toolkit/devel-api/controls/web-view-lite/web-view-lite.h>
+
+namespace Dali
+{
+
+namespace Toolkit
+{
+
+class WebViewLite;
+
+namespace Internal
+{
+
+class WebViewLite: public Control
+{
+protected:
+
+  WebViewLite();
+
+  virtual ~WebViewLite();
+
+public:
+
+  /**
+   * @copydoc Toolkit::WebViewLite::New()
+   */
+  static Toolkit::WebViewLite New();
+
+  /**
+   * @copydoc Dali::Toolkit::WebViewLite::CreateInstance()
+   */
+  void CreateInstance(int width, int height, int windowX, int windowY, const std::string& locale, const std::string& timezoneID);
+
+  /**
+   * @copydoc Dali::Toolkit::WebViewLite::DestroyInstance()
+   */
+  void DestroyInstance();
+
+  /**
+   * @copydoc Dali::Toolkit::WebViewLite::LoadHtml()
+   */
+  void LoadHtml(const std::string& path);
+
+ /**
+   * @copydoc Dali::Toolkit::WebViewLite::FinishedSignal()
+   */
+  Dali::Toolkit::WebViewLite::WebViewLiteSignalType& FinishedSignal();
+
+  /**
+   * @brief Emit the finished signal
+   */
+  void EmitFinishedSignal();
+
+  static bool DoConnectSignal( BaseObject* object, ConnectionTrackerInterface* tracker, const std::string& signalName, FunctorDelegate* functor );
+
+private: // From Control
+
+  /**
+   * @copydoc Toolkit::Control::OnInitialize()
+   */
+  virtual void OnInitialize();
+
+private:
+
+  // Undefined
+  WebViewLite( const WebViewLite& webViewLite );
+
+  WebViewLite& operator=( const WebViewLite& webViewLite );
+
+private:
+
+  Dali::WebEngineLite mWebViewLite;
+  Dali::Toolkit::WebViewLite::WebViewLiteSignalType mFinishedSignal;
+};
+
+} // namespace Internal
+
+inline Toolkit::Internal::WebViewLite& GetImpl( Toolkit::WebViewLite& handle )
+{
+  DALI_ASSERT_ALWAYS( handle );
+  Dali::RefObject& impl = handle.GetImplementation();
+  return static_cast< Toolkit::Internal::WebViewLite& >( impl );
+}
+
+inline const Toolkit::Internal::WebViewLite& GetImpl( const Toolkit::WebViewLite& handle )
+{
+  DALI_ASSERT_ALWAYS( handle );
+  const Dali::RefObject& impl = handle.GetImplementation();
+  return static_cast< const Toolkit::Internal::WebViewLite& >( impl );
+}
+
+} // namespace Toolkit
+
+} // namespace Dali
+
+#endif // DALI_TOOLKIT_WEB_VIEW_LITE_H
index 9b6809ff37a2a18286905a1dfa377b618618338d..b0512f523fe3c526701b63bbf892cd3ab5cb56c8 100644 (file)
@@ -89,6 +89,7 @@ toolkit_src_files = \
    $(toolkit_src_dir)/controls/tool-bar/tool-bar-impl.cpp \
    $(toolkit_src_dir)/controls/tooltip/tooltip.cpp \
    $(toolkit_src_dir)/controls/video-view/video-view-impl.cpp \
+   $(toolkit_src_dir)/controls/web-view-lite/web-view-lite-impl.cpp \
    $(toolkit_src_dir)/accessibility-manager/accessibility-manager-impl.cpp \
    \
    $(toolkit_src_dir)/feedback/feedback-style.cpp \