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

Side by Side Diff: chrome/browser/blocked_content_container.cc

Issue 3859003: FBTF: Even more ctor/virtual deinlining. (Closed) Base URL: http://git.chromium.org/git/chromium.git
Patch Set: Created 10 years, 2 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "chrome/browser/blocked_content_container.h" 5 #include "chrome/browser/blocked_content_container.h"
6 6
7 #include "chrome/browser/tab_contents/tab_contents.h" 7 #include "chrome/browser/tab_contents/tab_contents.h"
8 #include "gfx/rect.h" 8 #include "gfx/rect.h"
9 9
10 // static 10 // static
(...skipping 13 matching lines...) Expand all
24 TabContents* tab_contents; 24 TabContents* tab_contents;
25 WindowOpenDisposition disposition; 25 WindowOpenDisposition disposition;
26 gfx::Rect bounds; 26 gfx::Rect bounds;
27 bool user_gesture; 27 bool user_gesture;
28 }; 28 };
29 29
30 BlockedContentContainer::BlockedContentContainer(TabContents* owner) 30 BlockedContentContainer::BlockedContentContainer(TabContents* owner)
31 : owner_(owner) { 31 : owner_(owner) {
32 } 32 }
33 33
34 BlockedContentContainer::~BlockedContentContainer() {}
35
34 void BlockedContentContainer::AddTabContents(TabContents* tab_contents, 36 void BlockedContentContainer::AddTabContents(TabContents* tab_contents,
35 WindowOpenDisposition disposition, 37 WindowOpenDisposition disposition,
36 const gfx::Rect& bounds, 38 const gfx::Rect& bounds,
37 bool user_gesture) { 39 bool user_gesture) {
38 if (blocked_contents_.size() == (kImpossibleNumberOfPopups - 1)) { 40 if (blocked_contents_.size() == (kImpossibleNumberOfPopups - 1)) {
39 delete tab_contents; 41 delete tab_contents;
40 LOG(INFO) << "Warning: Renderer is sending more popups to us than should " 42 LOG(INFO) << "Warning: Renderer is sending more popups to us than should "
41 "be possible. Renderer compromised?"; 43 "be possible. Renderer compromised?";
42 return; 44 return;
43 } 45 }
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after
140 // Assume everything added is a popup. This may turn out to be wrong, but 142 // Assume everything added is a popup. This may turn out to be wrong, but
141 // callers don't cache this information so it should be fine if the value ends 143 // callers don't cache this information so it should be fine if the value ends
142 // up changing. 144 // up changing.
143 return true; 145 return true;
144 } 146 }
145 147
146 TabContents* BlockedContentContainer::GetConstrainingContents( 148 TabContents* BlockedContentContainer::GetConstrainingContents(
147 TabContents* source) { 149 TabContents* source) {
148 return owner_; 150 return owner_;
149 } 151 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698