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

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 21 matching lines...) Expand all
32 32
33 void WebDialogWebContentsDelegate::Detach() { 33 void WebDialogWebContentsDelegate::Detach() {
34 browser_context_ = NULL; 34 browser_context_ = NULL;
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 bool 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 handler_->AddNewContents(browser_context_, source, new_contents, disposition, 46 return handler_->AddNewContents(browser_context_, source, new_contents,
47 initial_pos, user_gesture); 47 disposition, initial_pos, user_gesture);
48 } 48 }
49 49
50 bool WebDialogWebContentsDelegate::IsPopupOrPanel( 50 bool WebDialogWebContentsDelegate::IsPopupOrPanel(
51 const WebContents* source) const { 51 const WebContents* source) const {
52 // This needs to return true so that we are allowed to be resized by our 52 // This needs to return true so that we are allowed to be resized by our
53 // contents. 53 // contents.
54 return true; 54 return true;
55 } 55 }
56 56
57 bool WebDialogWebContentsDelegate::ShouldAddNavigationToHistory( 57 bool WebDialogWebContentsDelegate::ShouldAddNavigationToHistory(
58 const history::HistoryAddPageArgs& add_page_args, 58 const history::HistoryAddPageArgs& add_page_args,
59 content::NavigationType navigation_type) { 59 content::NavigationType navigation_type) {
60 return false; 60 return false;
61 } 61 }
62 62
63 } // namespace ui 63 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698