[]( const std::string& arg ) {
}
);
+ view.SetTtsFocus(true);
DALI_TEST_CHECK( view );
Dali::Toolkit::GetImpl(*this).RegisterGeolocationPermissionCallback(callback);
}
+void WebView::SetTtsFocus(bool focused)
+{
+ Dali::Toolkit::GetImpl(*this).SetTtsFocus(focused);
+}
+
WebView::WebViewPageLoadSignalType& WebView::PageLoadStartedSignal()
{
return Dali::Toolkit::GetImpl(*this).PageLoadStartedSignal();
void RegisterGeolocationPermissionCallback(Dali::WebEnginePlugin::GeolocationPermissionCallback callback);
/**
+ * @brief Set or unset TTS focus of the webview.
+ * @param[in] focused True if it is gained, false lost.
+ * @return true if succeeded, false otherwise.
+ * @note It only works when the webview does not have keyinput focus. If it has keyinput focus, the TTS focus is set automatically.
+ */
+ void SetTtsFocus(bool focused);
+
+ /**
* @brief Connect to this signal to be notified when page loading is started.
*
* @return A signal object to connect with
}
}
+void WebView::SetTtsFocus(bool focused)
+{
+ if(mWebEngine && !HasKeyInputFocus())
+ {
+ mWebEngine.SetFocus(focused);
+ }
+}
+
void WebView::UpdateDisplayArea(Dali::PropertyNotification& /*source*/)
{
if(!mWebEngine)
void RegisterGeolocationPermissionCallback(Dali::WebEnginePlugin::GeolocationPermissionCallback callback);
/**
+ * @copydoc Dali::Toolkit::WebView::SetTtsFocus()
+ */
+ void SetTtsFocus(bool focused);
+
+ /**
* @copydoc Dali::Toolkit::WebView::PageLoadStartedSignal()
*/
Dali::Toolkit::WebView::WebViewPageLoadSignalType& PageLoadStartedSignal();