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

Side by Side Diff: chrome/browser/views/location_bar/star_view.cc

Issue 3354005: Re-lands 58186: (Closed)
Patch Set: Created 10 years, 3 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
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/views/location_bar/star_view.h" 5 #include "chrome/browser/views/location_bar/star_view.h"
6 6
7 #include "app/l10n_util.h" 7 #include "app/l10n_util.h"
8 #include "app/resource_bundle.h" 8 #include "app/resource_bundle.h"
9 #include "chrome/app/chrome_dll_resource.h" 9 #include "chrome/app/chrome_dll_resource.h"
10 #include "chrome/browser/command_updater.h" 10 #include "chrome/browser/command_updater.h"
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 // for buttons. 52 // for buttons.
53 return true; 53 return true;
54 } 54 }
55 55
56 void StarView::OnMouseReleased(const views::MouseEvent& event, bool canceled) { 56 void StarView::OnMouseReleased(const views::MouseEvent& event, bool canceled) {
57 if (!canceled && HitTest(event.location())) 57 if (!canceled && HitTest(event.location()))
58 command_updater_->ExecuteCommand(IDC_BOOKMARK_PAGE); 58 command_updater_->ExecuteCommand(IDC_BOOKMARK_PAGE);
59 } 59 }
60 60
61 bool StarView::OnKeyPressed(const views::KeyEvent& e) { 61 bool StarView::OnKeyPressed(const views::KeyEvent& e) {
62 if (e.GetKeyCode() == base::VKEY_SPACE || 62 if (e.GetKeyCode() == app::VKEY_SPACE ||
63 e.GetKeyCode() == base::VKEY_RETURN) { 63 e.GetKeyCode() == app::VKEY_RETURN) {
64 command_updater_->ExecuteCommand(IDC_BOOKMARK_PAGE); 64 command_updater_->ExecuteCommand(IDC_BOOKMARK_PAGE);
65 return true; 65 return true;
66 } 66 }
67 return false; 67 return false;
68 } 68 }
69 69
70 void StarView::InfoBubbleClosing(InfoBubble* info_bubble, 70 void StarView::InfoBubbleClosing(InfoBubble* info_bubble,
71 bool closed_by_escape) { 71 bool closed_by_escape) {
72 } 72 }
73 73
74 bool StarView::CloseOnEscape() { 74 bool StarView::CloseOnEscape() {
75 return true; 75 return true;
76 } 76 }
OLDNEW
« no previous file with comments | « chrome/browser/views/location_bar/page_action_image_view.cc ('k') | chrome/browser/views/options/cookies_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698