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

Unified Diff: chrome/browser/instant/instant_controller.cc

Issue 11270042: Add non-member non-mutating methods for common gfx::Rect operations. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/instant/instant_controller.cc
diff --git a/chrome/browser/instant/instant_controller.cc b/chrome/browser/instant/instant_controller.cc
index 7329aa06958d9691d93bf97ce5c45fdae48e5f8e..73510e52e0e2cbfd56d1f2305aeac7d52c7a21de 100644
--- a/chrome/browser/instant/instant_controller.cc
+++ b/chrome/browser/instant/instant_controller.cc
@@ -738,8 +738,7 @@ void InstantController::SendBoundsToPage() {
last_omnibox_bounds_ = omnibox_bounds_;
gfx::Rect preview_bounds = browser_->GetInstantBounds();
- gfx::Rect intersection = omnibox_bounds_;
- intersection.Intersect(preview_bounds);
+ gfx::Rect intersection = gfx::Intersection(omnibox_bounds_, preview_bounds);
// Translate into window coordinates.
if (!intersection.IsEmpty()) {

Powered by Google App Engine
This is Rietveld 408576698