summaryrefslogtreecommitdiffstats
path: root/src/core/web_contents_adapter.cpp
diff options
context:
space:
mode:
authorAllan Sandfeld Jensen <allan.jensen@theqtcompany.com>2016-07-29 14:09:05 +0200
committerAllan Sandfeld Jensen <allan.jensen@theqtcompany.com>2016-08-02 12:00:57 +0200
commit1a49f193afe1ba54339182a49d891917159f6719 (patch)
tree986cf277193c625c2f61015c7f29c6b403a5eb02 /src/core/web_contents_adapter.cpp
parent47d6b5ce11d1014548ba69df5d7b698381a8343e (diff)
parentfa138d4a76e9e820f01a75771c30dbced8c4e6f3 (diff)
Merge remote-tracking branch 'origin/5.6' into 5.7
Conflicts: src/3rdparty src/core/resources/resources.gyp src/webengine/doc/src/qtwebengine-overview.qdoc src/webenginewidgets/api/qwebenginepage.cpp src/webenginewidgets/api/qwebenginescriptcollection.cpp src/webenginewidgets/api/qwebenginescriptcollection_p.h tests/auto/widgets/qwebenginepage/BLACKLIST And readded newly in 5.6 enabled tests to the BLACKLIST. Change-Id: I4ab1fc54ebfaaf940df81b0d8d6bdd15cae8b7c4
Diffstat (limited to 'src/core/web_contents_adapter.cpp')
-rw-r--r--src/core/web_contents_adapter.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/core/web_contents_adapter.cpp b/src/core/web_contents_adapter.cpp
index 260efc081..bfac6a5b2 100644
--- a/src/core/web_contents_adapter.cpp
+++ b/src/core/web_contents_adapter.cpp
@@ -348,14 +348,14 @@ WebContentsAdapterPrivate::~WebContentsAdapterPrivate()
webContents.reset();
}
-QExplicitlySharedDataPointer<WebContentsAdapter> WebContentsAdapter::createFromSerializedNavigationHistory(QDataStream &input, WebContentsAdapterClient *adapterClient)
+QSharedPointer<WebContentsAdapter> WebContentsAdapter::createFromSerializedNavigationHistory(QDataStream &input, WebContentsAdapterClient *adapterClient)
{
int currentIndex;
std::vector<scoped_ptr<content::NavigationEntry>> entries;
deserializeNavigationHistory(input, &currentIndex, &entries, adapterClient->browserContextAdapter()->browserContext());
if (currentIndex == -1)
- return QExplicitlySharedDataPointer<WebContentsAdapter>();
+ return QSharedPointer<WebContentsAdapter>();
// Unlike WebCore, Chromium only supports Restoring to a new WebContents instance.
content::WebContents* newWebContents = createBlankWebContents(adapterClient, adapterClient->browserContextAdapter()->browserContext());
@@ -373,7 +373,7 @@ QExplicitlySharedDataPointer<WebContentsAdapter> WebContentsAdapter::createFromS
content::ChildProcessSecurityPolicy::GetInstance()->GrantReadFile(id, *file);
}
- return QExplicitlySharedDataPointer<WebContentsAdapter>(new WebContentsAdapter(newWebContents));
+ return QSharedPointer<WebContentsAdapter>::create(newWebContents);
}
WebContentsAdapter::WebContentsAdapter(content::WebContents *webContents)
@@ -835,6 +835,9 @@ void WebContentsAdapter::stopFinding()
{
Q_D(WebContentsAdapter);
d->webContentsDelegate->setLastSearchedString(QString());
+ // Clear any previous selection,
+ // but keep the renderer blue rectangle selection just like Chromium does.
+ d->webContents->Unselect();
d->webContents->StopFinding(content::STOP_FIND_ACTION_KEEP_SELECTION);
}