X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali%2Fdevel-api%2Fadaptor-framework%2Fweb-engine-plugin.h;h=ec8cde06aaa71ff519a86e970abaaf74d22d15a2;hb=3013c2a3987055e65fa574438028cf8fdb0f5683;hp=ad743233dd7717a4f21458e65506cac6a39f7b3e;hpb=883e5ca2296ca93476a9862b2fa5653288166caf;p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git diff --git a/dali/devel-api/adaptor-framework/web-engine-plugin.h b/dali/devel-api/adaptor-framework/web-engine-plugin.h index ad74323..ec8cde0 100755 --- a/dali/devel-api/adaptor-framework/web-engine-plugin.h +++ b/dali/devel-api/adaptor-framework/web-engine-plugin.h @@ -19,12 +19,15 @@ */ // EXTERNAL INCLUDES +#include +#include + +// INTERNAL INCLUDES +#include #include #include #include #include -#include -#include namespace Dali { @@ -39,6 +42,7 @@ class WebEngineContextMenu; class WebEngineContextMenuItem; class WebEngineCookieManager; class WebEngineFormRepostDecision; +class WebEngineHitTest; class WebEngineHttpAuthHandler; class WebEngineLoadError; class WebEnginePolicyDecision; @@ -160,6 +164,11 @@ public: using WebEnginePolicyDecisionSignalType = Signal)>; /** + * @brief Hit test callback called after hit test is created asynchronously. + */ + using WebEngineHitTestCreatedCallback = std::function)>; + + /** * @brief Enumeration for the scroll edge. */ enum class ScrollEdge @@ -204,7 +213,7 @@ public: * @param [in] locale The locale of Web * @param [in] timezoneId The timezoneID of Web */ - virtual void Create(int width, int height, const std::string& locale, const std::string& timezoneId) = 0; + virtual void Create(uint32_t width, uint32_t height, const std::string& locale, const std::string& timezoneId) = 0; /** * @brief Create WebEngine instance. @@ -214,7 +223,7 @@ public: * @param [in] argc The count of application arguments * @param [in] argv The string array of application arguments */ - virtual void Create(int width, int height, int argc, char** argv) = 0; + virtual void Create(uint32_t width, uint32_t height, uint32_t argc, char** argv) = 0; /** * @brief Destroy WebEngine instance. @@ -381,7 +390,7 @@ public: * @param[in] deltaX horizontal offset to scroll * @param[in] deltaY vertical offset to scroll */ - virtual void ScrollBy(int deltaX, int deltaY) = 0; + virtual void ScrollBy(int32_t deltaX, int32_t deltaY) = 0; /** * @brief Scroll edge of view by deltaX and deltaY. @@ -391,12 +400,12 @@ public: * * @return true if succeeded, false otherwise */ - virtual bool ScrollEdgeBy(int deltaX, int deltaY) = 0; + virtual bool ScrollEdgeBy(int32_t deltaX, int32_t deltaY) = 0; /** * @brief Scroll to the specified position of the given view. */ - virtual void SetScrollPosition(int x, int y) = 0; + virtual void SetScrollPosition(int32_t x, int32_t y) = 0; /** * @brief Get the current scroll position of the given view. @@ -490,6 +499,29 @@ public: virtual void JavaScriptPromptReply(const std::string& result) = 0; /** + * @brief Create a new hit test. + * + * @param[in] x the horizontal position to query + * @param[in] y the vertical position to query + * @param[in] mode the mode of hit test + * + * @return a new hit test object. + */ + virtual std::unique_ptr CreateHitTest(int32_t x, int32_t y, Dali::WebEngineHitTest::HitTestMode mode) = 0; + + /** + * @brief create a hit test asynchronously. + * + * @param[in] x the horizontal position to query + * @param[in] y the vertical position to query + * @param[in] mode the mode of hit test + * @param[in] callback The callback function + * + * @return true if succeeded, false otherwise + */ + virtual bool CreateHitTestAsynchronously(int32_t x, int32_t y, Dali::WebEngineHitTest::HitTestMode mode, WebEngineHitTestCreatedCallback callback) = 0; + + /** * @brief Clear the history of Web. */ virtual void ClearHistory() = 0; @@ -516,7 +548,7 @@ public: /** * @brief Set size of Web Page. */ - virtual void SetSize(int width, int height) = 0; + virtual void SetSize(uint32_t width, uint32_t height) = 0; /** * @brief Set background color of web page. @@ -663,7 +695,7 @@ public: * * @return pixel data of screen shot */ - virtual Dali::PixelData GetScreenshot(Dali::Rect viewArea, float scaleFactor) = 0; + virtual Dali::PixelData GetScreenshot(Dali::Rect viewArea, float scaleFactor) = 0; /** * @brief Request to get snapshot of the specified viewArea of page asynchronously. @@ -674,7 +706,7 @@ public: * * @return true if requested successfully, false otherwise */ - virtual bool GetScreenshotAsynchronously(Dali::Rect viewArea, float scaleFactor, ScreenshotCapturedCallback callback) = 0; + virtual bool GetScreenshotAsynchronously(Dali::Rect viewArea, float scaleFactor, ScreenshotCapturedCallback callback) = 0; /** * @brief Asynchronously request to check if there is a video playing in the given view. @@ -696,7 +728,7 @@ public: * @brief Update display area. * @param[in] displayArea The display area need be updated. */ - virtual void UpdateDisplayArea(Dali::Rect displayArea) = 0; + virtual void UpdateDisplayArea(Dali::Rect displayArea) = 0; /** * @brief Enable video hole.