Add callbacks for form repost decision and frame rendering.
[platform/core/uifw/dali-toolkit.git] / dali-toolkit / internal / controls / web-view / web-view-impl.h
old mode 100644 (file)
new mode 100755 (executable)
index 9abfd49..24eda62
@@ -199,7 +199,7 @@ public:
   void ClearHistory();
 
   /**
-   * @brief Clears all tiles resources of Web.
+   * @copydoc Dali::Toolkit::WebView::ClearAllTilesResources()
    */
   void ClearAllTilesResources();
 
@@ -233,6 +233,16 @@ public:
    */
   Dali::Toolkit::WebView::WebViewUrlChangedSignalType& UrlChangedSignal();
 
+  /**
+   * @copydoc Dali::Toolkit::WebView::FormRepostDecisionSignal()
+   */
+  Dali::Toolkit::WebView::WebViewFormRepostDecisionSignalType& FormRepostDecisionSignal();
+
+  /**
+   * @copydoc Dali::Toolkit::WebView::FrameRenderedSignal()
+   */
+  Dali::Toolkit::WebView::WebViewFrameRenderedSignalType& FrameRenderedSignal();
+
 public: // Properties
   /**
    * @brief Called when a property of an object of this type is set.
@@ -336,6 +346,38 @@ private:
   std::string GetTitle() const;
 
   /**
+   * @brief Sets the background color of web page.
+   * @param[in] color The value of background color.
+   */
+  void SetDocumentBackgroundColor(Dali::Vector4 color);
+
+  /**
+   * @brief Clears tiles when hidden.
+   *
+   * @param[in] cleared Whether tiles are cleared or not
+   */
+  void ClearTilesWhenHidden(bool cleared);
+
+  /**
+   * @brief Sets multiplier of cover area of tile.
+   *
+   * @param[in] multiplier The multiplier of cover area
+   */
+  void SetTileCoverAreaMultiplier(float multiplier);
+
+  /**
+   * @brief Enables cursor by client.
+   * @param[in] enabled Whether cursor is enabled or not.
+   */
+  void EnableCursorByClient(bool enabled);
+
+  /**
+   * @brief Gets the selected text.
+   * @return The selected text
+   */
+  std::string GetSelectedText() const;
+
+  /**
    * @brief Get user agent string.
    * @return The string value of user agent
    */
@@ -440,6 +482,17 @@ private:
    */
   bool OnWheelEvent(Actor actor, const Dali::WheelEvent& wheel);
 
+  /**
+   * @brief Callback function to be called when form repost decision need be checked.
+   * @param[in] decision The new decision for form repost
+   */
+  void OnFormRepostDecision(std::shared_ptr<Dali::WebEngineFormRepostDecision> decision);
+
+  /**
+   * @brief Callback function to be called when frame is rendered.
+   */
+  void OnFrameRendered();
+
 private:
   std::string                 mUrl;
   Dali::Toolkit::Visual::Base mVisual;
@@ -450,6 +503,7 @@ private:
   Dali::Toolkit::WebView::WebViewPageLoadSignalType          mPageLoadInProgressSignal;
   Dali::Toolkit::WebView::WebViewPageLoadSignalType          mPageLoadFinishedSignal;
   Dali::Toolkit::WebView::WebViewPageLoadErrorSignalType     mPageLoadErrorSignal;
+  Dali::Toolkit::WebView::WebViewUrlChangedSignalType        mUrlChangedSignal;
   Dali::Toolkit::WebView::WebViewScrollEdgeReachedSignalType mScrollEdgeReachedSignal;
 
   std::unique_ptr<Dali::Toolkit::WebContext>         mWebContext;
@@ -463,9 +517,11 @@ private:
   Dali::PropertyNotification                          mScaleUpdateNotification;
   bool                                                mVideoHoleEnabled;
   Dali::Rect<int>                                     mWebViewArea;
-  Dali::Toolkit::WebView::WebViewUrlChangedSignalType mUrlChangedSignal;
   bool                                                mMouseEventsEnabled;
   bool                                                mKeyEventsEnabled;
+
+  Dali::Toolkit::WebView::WebViewFormRepostDecisionSignalType mFormRepostDecisionSignal;
+  Dali::Toolkit::WebView::WebViewFrameRenderedSignalType      mFrameRenderedSignal;
 };
 
 } // namespace Internal