Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(526)

Side by Side Diff: apps/app_window.cc

Issue 586933002: Re-Revert "[WebModals] New API for browser-scoped popup management." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2125
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « apps/app_window.h ('k') | chrome/browser/chromeos/attestation/platform_verification_dialog.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "apps/app_window.h" 5 #include "apps/app_window.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after
286 286
287 requested_alpha_enabled_ = new_params.alpha_enabled; 287 requested_alpha_enabled_ = new_params.alpha_enabled;
288 288
289 AppsClient* apps_client = AppsClient::Get(); 289 AppsClient* apps_client = AppsClient::Get();
290 native_app_window_.reset( 290 native_app_window_.reset(
291 apps_client->CreateNativeAppWindow(this, new_params)); 291 apps_client->CreateNativeAppWindow(this, new_params));
292 292
293 helper_.reset(new AppWebContentsHelper( 293 helper_.reset(new AppWebContentsHelper(
294 browser_context_, extension_id_, web_contents, app_delegate_.get())); 294 browser_context_, extension_id_, web_contents, app_delegate_.get()));
295 295
296 popup_manager_.reset(
297 new web_modal::PopupManager(GetWebContentsModalDialogHost()));
298 popup_manager_->RegisterWith(web_contents);
299
300 // Prevent the browser process from shutting down while this window exists. 296 // Prevent the browser process from shutting down while this window exists.
301 apps_client->IncrementKeepAliveCount(); 297 apps_client->IncrementKeepAliveCount();
302 UpdateExtensionAppIcon(); 298 UpdateExtensionAppIcon();
303 AppWindowRegistry::Get(browser_context_)->AddAppWindow(this); 299 AppWindowRegistry::Get(browser_context_)->AddAppWindow(this);
304 300
305 if (new_params.hidden) { 301 if (new_params.hidden) {
306 // Although the window starts hidden by default, calling Hide() here 302 // Although the window starts hidden by default, calling Hide() here
307 // notifies observers of the window being hidden. 303 // notifies observers of the window being hidden.
308 Hide(); 304 Hide();
309 } else { 305 } else {
(...skipping 793 matching lines...) Expand 10 before | Expand all | Expand 10 after
1103 region.bounds.x(), 1099 region.bounds.x(),
1104 region.bounds.y(), 1100 region.bounds.y(),
1105 region.bounds.right(), 1101 region.bounds.right(),
1106 region.bounds.bottom(), 1102 region.bounds.bottom(),
1107 region.draggable ? SkRegion::kUnion_Op : SkRegion::kDifference_Op); 1103 region.draggable ? SkRegion::kUnion_Op : SkRegion::kDifference_Op);
1108 } 1104 }
1109 return sk_region; 1105 return sk_region;
1110 } 1106 }
1111 1107
1112 } // namespace apps 1108 } // namespace apps
OLDNEW
« no previous file with comments | « apps/app_window.h ('k') | chrome/browser/chromeos/attestation/platform_verification_dialog.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698