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

Side by Side Diff: chrome/browser/ui/views/location_bar/zoom_bubble_view.cc

Issue 10832282: Replace views::MouseEvent with ui::MouseEvent (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 4 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 "chrome/browser/ui/views/location_bar/zoom_bubble_view.h" 5 #include "chrome/browser/ui/views/location_bar/zoom_bubble_view.h"
6 6
7 #include "chrome/browser/chrome_page_zoom.h" 7 #include "chrome/browser/chrome_page_zoom.h"
8 #include "chrome/browser/ui/tab_contents/tab_contents.h" 8 #include "chrome/browser/ui/tab_contents/tab_contents.h"
9 #include "chrome/browser/ui/zoom/zoom_controller.h" 9 #include "chrome/browser/ui/zoom/zoom_controller.h"
10 #include "grit/generated_resources.h" 10 #include "grit/generated_resources.h"
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 base::TimeDelta::FromMilliseconds(kBubbleCloseDelay), 105 base::TimeDelta::FromMilliseconds(kBubbleCloseDelay),
106 this, 106 this,
107 &ZoomBubbleView::Close); 107 &ZoomBubbleView::Close);
108 } 108 }
109 } 109 }
110 110
111 void ZoomBubbleView::StopTimer() { 111 void ZoomBubbleView::StopTimer() {
112 timer_.Stop(); 112 timer_.Stop();
113 } 113 }
114 114
115 void ZoomBubbleView::OnMouseEntered(const views::MouseEvent& event) { 115 void ZoomBubbleView::OnMouseEntered(const ui::MouseEvent& event) {
116 StopTimer(); 116 StopTimer();
117 } 117 }
118 118
119 void ZoomBubbleView::OnMouseExited(const views::MouseEvent& event) { 119 void ZoomBubbleView::OnMouseExited(const ui::MouseEvent& event) {
120 StartTimerIfNecessary(); 120 StartTimerIfNecessary();
121 } 121 }
122 122
123 void ZoomBubbleView::ButtonPressed(views::Button* sender, 123 void ZoomBubbleView::ButtonPressed(views::Button* sender,
124 const ui::Event& event) { 124 const ui::Event& event) {
125 chrome_page_zoom::Zoom(tab_contents_->web_contents(), 125 chrome_page_zoom::Zoom(tab_contents_->web_contents(),
126 content::PAGE_ZOOM_RESET); 126 content::PAGE_ZOOM_RESET);
127 } 127 }
128 128
129 void ZoomBubbleView::Init() { 129 void ZoomBubbleView::Init() {
(...skipping 21 matching lines...) Expand all
151 // Compensate for some built-in padding in the zoom image. 151 // Compensate for some built-in padding in the zoom image.
152 gfx::Rect rect(BubbleDelegateView::GetAnchorRect()); 152 gfx::Rect rect(BubbleDelegateView::GetAnchorRect());
153 rect.Inset(0, anchor_view() ? 5 : 0); 153 rect.Inset(0, anchor_view() ? 5 : 0);
154 return rect; 154 return rect;
155 } 155 }
156 156
157 void ZoomBubbleView::WindowClosing() { 157 void ZoomBubbleView::WindowClosing() {
158 DCHECK(zoom_bubble_ == this); 158 DCHECK(zoom_bubble_ == this);
159 zoom_bubble_ = NULL; 159 zoom_bubble_ = NULL;
160 } 160 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/location_bar/zoom_bubble_view.h ('k') | chrome/browser/ui/views/location_bar/zoom_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698