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

Side by Side Diff: ui/web_dialogs/web_dialog_web_contents_delegate.cc

Issue 10868116: Pass result of blockage across content API when new tab blocked. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "ui/web_dialogs/web_dialog_web_contents_delegate.h" 5 #include "ui/web_dialogs/web_dialog_web_contents_delegate.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "content/public/browser/web_contents.h" 8 #include "content/public/browser/web_contents.h"
9 9
10 using content::BrowserContext; 10 using content::BrowserContext;
(...skipping 24 matching lines...) Expand all
35 } 35 }
36 36
37 WebContents* WebDialogWebContentsDelegate::OpenURLFromTab( 37 WebContents* WebDialogWebContentsDelegate::OpenURLFromTab(
38 WebContents* source, const OpenURLParams& params) { 38 WebContents* source, const OpenURLParams& params) {
39 return handler_->OpenURLFromTab(browser_context_, source, params); 39 return handler_->OpenURLFromTab(browser_context_, source, params);
40 } 40 }
41 41
42 void WebDialogWebContentsDelegate::AddNewContents( 42 void WebDialogWebContentsDelegate::AddNewContents(
43 WebContents* source, WebContents* new_contents, 43 WebContents* source, WebContents* new_contents,
44 WindowOpenDisposition disposition, const gfx::Rect& initial_pos, 44 WindowOpenDisposition disposition, const gfx::Rect& initial_pos,
45 bool user_gesture) { 45 bool user_gesture,
46 bool* was_blocked) {
46 handler_->AddNewContents(browser_context_, source, new_contents, disposition, 47 handler_->AddNewContents(browser_context_, source, new_contents, disposition,
47 initial_pos, user_gesture); 48 initial_pos, user_gesture);
48 } 49 }
49 50
50 bool WebDialogWebContentsDelegate::IsPopupOrPanel( 51 bool WebDialogWebContentsDelegate::IsPopupOrPanel(
51 const WebContents* source) const { 52 const WebContents* source) const {
52 // This needs to return true so that we are allowed to be resized by our 53 // This needs to return true so that we are allowed to be resized by our
53 // contents. 54 // contents.
54 return true; 55 return true;
55 } 56 }
56 57
57 bool WebDialogWebContentsDelegate::ShouldAddNavigationToHistory( 58 bool WebDialogWebContentsDelegate::ShouldAddNavigationToHistory(
58 const history::HistoryAddPageArgs& add_page_args, 59 const history::HistoryAddPageArgs& add_page_args,
59 content::NavigationType navigation_type) { 60 content::NavigationType navigation_type) {
60 return false; 61 return false;
61 } 62 }
62 63
63 } // namespace ui 64 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698