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

Side by Side Diff: chrome/browser/ui/views/global_error_bubble_view.cc

Issue 10827271: Replace views::Event with ui::Event. (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/global_error_bubble_view.h" 5 #include "chrome/browser/ui/views/global_error_bubble_view.h"
6 6
7 #include "base/utf_string_conversions.h" 7 #include "base/utf_string_conversions.h"
8 #include "chrome/browser/ui/global_error/global_error.h" 8 #include "chrome/browser/ui/global_error/global_error.h"
9 #include "chrome/browser/ui/global_error/global_error_service.h" 9 #include "chrome/browser/ui/global_error/global_error_service.h"
10 #include "chrome/browser/ui/global_error/global_error_service_factory.h" 10 #include "chrome/browser/ui/global_error/global_error_service_factory.h"
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 GlobalErrorBubbleView::~GlobalErrorBubbleView() { 145 GlobalErrorBubbleView::~GlobalErrorBubbleView() {
146 } 146 }
147 147
148 gfx::Rect GlobalErrorBubbleView::GetAnchorRect() { 148 gfx::Rect GlobalErrorBubbleView::GetAnchorRect() {
149 gfx::Rect rect(views::BubbleDelegateView::GetAnchorRect()); 149 gfx::Rect rect(views::BubbleDelegateView::GetAnchorRect());
150 rect.Inset(0, anchor_view() ? kAnchorVerticalInset : 0); 150 rect.Inset(0, anchor_view() ? kAnchorVerticalInset : 0);
151 return rect; 151 return rect;
152 } 152 }
153 153
154 void GlobalErrorBubbleView::ButtonPressed(views::Button* sender, 154 void GlobalErrorBubbleView::ButtonPressed(views::Button* sender,
155 const views::Event& event) { 155 const ui::Event& event) {
156 if (error_) { 156 if (error_) {
157 if (sender->tag() == TAG_ACCEPT_BUTTON) 157 if (sender->tag() == TAG_ACCEPT_BUTTON)
158 error_->BubbleViewAcceptButtonPressed(browser_); 158 error_->BubbleViewAcceptButtonPressed(browser_);
159 else if (sender->tag() == TAG_CANCEL_BUTTON) 159 else if (sender->tag() == TAG_CANCEL_BUTTON)
160 error_->BubbleViewCancelButtonPressed(browser_); 160 error_->BubbleViewCancelButtonPressed(browser_);
161 else 161 else
162 NOTREACHED(); 162 NOTREACHED();
163 } 163 }
164 GetWidget()->Close(); 164 GetWidget()->Close();
165 } 165 }
166 166
167 void GlobalErrorBubbleView::WindowClosing() { 167 void GlobalErrorBubbleView::WindowClosing() {
168 if (error_) 168 if (error_)
169 error_->BubbleViewDidClose(browser_); 169 error_->BubbleViewDidClose(browser_);
170 } 170 }
171 171
172 void GlobalErrorBubbleView::CloseBubbleView() { 172 void GlobalErrorBubbleView::CloseBubbleView() {
173 GetWidget()->Close(); 173 GetWidget()->Close();
174 } 174 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/global_error_bubble_view.h ('k') | chrome/browser/ui/views/hung_renderer_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698