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

Unified Diff: extensions/browser/app_window/app_web_contents_helper.cc

Issue 2248873002: Convert WindowOpenDisposition to an enum class. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix weird formatting in recent_tabs_sub_menu_model.cc Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: extensions/browser/app_window/app_web_contents_helper.cc
diff --git a/extensions/browser/app_window/app_web_contents_helper.cc b/extensions/browser/app_window/app_web_contents_helper.cc
index c3fe085c53b00ee41876f245b7de1bf4758724f3..2a64ce7439c4b187908274f400525ae7303352dc 100644
--- a/extensions/browser/app_window/app_web_contents_helper.cc
+++ b/extensions/browser/app_window/app_web_contents_helper.cc
@@ -45,7 +45,7 @@ content::WebContents* AppWebContentsHelper::OpenURLFromTab(
// navigations, which we don't want to allow.
// TOOD(mihaip): Can we check for user gestures instead?
WindowOpenDisposition disposition = params.disposition;
- if (disposition == CURRENT_TAB) {
+ if (disposition == WindowOpenDisposition::CURRENT_TAB) {
web_contents_->GetMainFrame()->AddMessageToConsole(
content::CONSOLE_MESSAGE_LEVEL_ERROR,
base::StringPrintf(
@@ -55,7 +55,8 @@ content::WebContents* AppWebContentsHelper::OpenURLFromTab(
}
// These dispositions aren't really navigations.
- if (disposition == SAVE_TO_DISK || disposition == IGNORE_ACTION)
+ if (disposition == WindowOpenDisposition::SAVE_TO_DISK ||
+ disposition == WindowOpenDisposition::IGNORE_ACTION)
return NULL;
content::WebContents* contents =

Powered by Google App Engine
This is Rietveld 408576698