OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/views/location_bar/location_icon_view.h" | 5 #include "chrome/browser/ui/views/location_bar/location_icon_view.h" |
6 | 6 |
7 LocationIconView::LocationIconView(const LocationBarView* location_bar) | 7 LocationIconView::LocationIconView(const LocationBarView* location_bar) |
8 : ALLOW_THIS_IN_INITIALIZER_LIST(click_handler_(this, location_bar)) { | 8 : ALLOW_THIS_IN_INITIALIZER_LIST(click_handler_(this, location_bar)) { |
9 } | 9 } |
10 | 10 |
11 LocationIconView::~LocationIconView() { | 11 LocationIconView::~LocationIconView() { |
12 } | 12 } |
13 | 13 |
14 bool LocationIconView::OnMousePressed(const views::MouseEvent& event) { | 14 bool LocationIconView::OnMousePressed(const views::MouseEvent& event) { |
15 // We want to show the dialog on mouse release; that is the standard behavior | 15 // We want to show the dialog on mouse release; that is the standard behavior |
16 // for buttons. | 16 // for buttons. |
17 return true; | 17 return true; |
18 } | 18 } |
19 | 19 |
20 void LocationIconView::OnMouseReleased(const views::MouseEvent& event, | 20 void LocationIconView::OnMouseReleased(const views::MouseEvent& event, |
21 bool canceled) { | 21 bool canceled) { |
22 click_handler_.OnMouseReleased(event, canceled); | 22 click_handler_.OnMouseReleased(event, canceled); |
23 } | 23 } |
OLD | NEW |