summaryrefslogtreecommitdiffstats
path: root/src/core/web_contents_delegate_qt.cpp
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@qt.io>2018-02-08 17:31:44 +0100
committerAllan Sandfeld Jensen <allan.jensen@qt.io>2018-03-15 16:52:27 +0000
commit243a2fef90dc3ac846a36738bfe97efba3050dc9 (patch)
tree9a68163527c2795f4c3ef0b11db10cc1a19f6915 /src/core/web_contents_delegate_qt.cpp
parent6b35497375c07c49cca7317a4452acc6adc7a1cd (diff)
Adaptations to form validation
Form validations messages has moved entirely to being done by Blink. Change-Id: I6742c111fc59f0baba75b8b37f5d0ec9ae2fb920 Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> Reviewed-by: Michael BrĂ¼ning <michael.bruning@qt.io>
Diffstat (limited to 'src/core/web_contents_delegate_qt.cpp')
-rw-r--r--src/core/web_contents_delegate_qt.cpp32
1 files changed, 0 insertions, 32 deletions
diff --git a/src/core/web_contents_delegate_qt.cpp b/src/core/web_contents_delegate_qt.cpp
index ed406977f..a88f7665e 100644
--- a/src/core/web_contents_delegate_qt.cpp
+++ b/src/core/web_contents_delegate_qt.cpp
@@ -85,16 +85,6 @@
namespace QtWebEngineCore {
-static gfx::Rect rootViewToScreenRect(content::WebContents *web_contents, const gfx::Rect &anchor_in_root_view)
-{
- RenderWidgetHostViewQt *rwhv = static_cast<RenderWidgetHostViewQt *>(web_contents->GetRenderWidgetHostView());
- if (!rwhv)
- return gfx::Rect();
- content::ScreenInfo screenInfo;
- rwhv->GetScreenInfo(&screenInfo);
- return gfx::ScaleToEnclosingRect(anchor_in_root_view, 1 / screenInfo.device_scale_factor);
-}
-
// Maps the LogSeverity defines in base/logging.h to the web engines message levels.
static WebContentsAdapterClient::JavaScriptConsoleMessageLevel mapToJavascriptConsoleMessageLevel(int32_t messageLevel) {
if (messageLevel < 1)
@@ -602,28 +592,6 @@ void WebContentsDelegateQt::launchExternalURL(const QUrl &url, ui::PageTransitio
}
}
-void WebContentsDelegateQt::ShowValidationMessage(content::WebContents *web_contents, const gfx::Rect &anchor_in_root_view, const base::string16 &main_text, const base::string16 &sub_text)
-{
- gfx::Rect anchor = rootViewToScreenRect(web_contents, anchor_in_root_view);
- if (anchor.IsEmpty())
- return;
- m_viewClient->showValidationMessage(toQt(anchor), toQt(main_text), toQt(sub_text));
-}
-
-void WebContentsDelegateQt::HideValidationMessage(content::WebContents *web_contents)
-{
- Q_UNUSED(web_contents);
- m_viewClient->hideValidationMessage();
-}
-
-void WebContentsDelegateQt::MoveValidationMessage(content::WebContents *web_contents, const gfx::Rect &anchor_in_root_view)
-{
- gfx::Rect anchor = rootViewToScreenRect(web_contents, anchor_in_root_view);
- if (anchor.IsEmpty())
- return;
- m_viewClient->moveValidationMessage(toQt(anchor));
-}
-
void WebContentsDelegateQt::BeforeUnloadFired(content::WebContents *tab, bool proceed, bool *proceed_to_fire_unload)
{
Q_UNUSED(tab);