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

Unified Diff: chrome/browser/tab_contents/tab_contents.cc

Issue 99203: Second attempt at cleaning up handling of --disable-popup-blocking. I didn't... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 8 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
« no previous file with comments | « chrome/browser/renderer_host/browser_render_process_host.cc ('k') | chrome/browser/unload_uitest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/tab_contents/tab_contents.cc
===================================================================
--- chrome/browser/tab_contents/tab_contents.cc (revision 14859)
+++ chrome/browser/tab_contents/tab_contents.cc (working copy)
@@ -35,6 +35,7 @@
#include "chrome/browser/tab_contents/web_contents.h"
#include "chrome/browser/search_engines/template_url_fetcher.h"
#include "chrome/browser/search_engines/template_url_model.h"
+#include "chrome/common/chrome_switches.h"
#include "chrome/common/l10n_util.h"
#include "chrome/common/notification_service.h"
#include "chrome/common/pref_names.h"
@@ -786,7 +787,9 @@
return;
#if defined(OS_WIN)
- if ((disposition == NEW_POPUP) && !user_gesture) {
+ if ((disposition == NEW_POPUP) && !user_gesture &&
+ !CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kDisablePopupBlocking)) {
// Unrequested popups from normal pages are constrained.
TabContents* popup_owner = this;
TabContents* our_owner = delegate_->GetConstrainingContents(this);
« no previous file with comments | « chrome/browser/renderer_host/browser_render_process_host.cc ('k') | chrome/browser/unload_uitest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698