Ignore generated background windows in GetWebViewIds for affected builds on M33

BUG=

Review URL: https://codereview.chromium.org/148283009

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@247913 0039d316-1c4b-4281-b951-d872f2087c98
parent 7f926755
...@@ -56,7 +56,17 @@ Status ChromeImpl::GetWebViewIds(std::list<std::string>* web_view_ids) { ...@@ -56,7 +56,17 @@ Status ChromeImpl::GetWebViewIds(std::list<std::string>* web_view_ids) {
// Check for newly-opened web views. // Check for newly-opened web views.
for (size_t i = 0; i < views_info.GetSize(); ++i) { for (size_t i = 0; i < views_info.GetSize(); ++i) {
const WebViewInfo& view = views_info.Get(i); const WebViewInfo& view = views_info.Get(i);
if (view.type != WebViewInfo::kPage) if (view.type != WebViewInfo::kPage && view.type != WebViewInfo::kApp)
continue;
// Workaround to ignore generated background pages that are
// being returned as active windows for some builds of Chrome.
// TODO(bustamante): Once Chrome builds < 1755 are no longer
// supported this check can be removed.
int kBuildNumber = GetBuildNo();
if (kBuildNumber > 1704 && kBuildNumber < 1755 &&
view.type == WebViewInfo::kApp &&
view.url.find("_generated_background") != std::string::npos)
continue; continue;
bool found = false; bool found = false;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment