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

Side by Side Diff: chrome/browser/ui/views/toolbar/toolbar_view.cc

Issue 2133013002: AcceleratorProvider: Make GetAcceleratorForCommandId const. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix overrides on Mac and Chrome OS. Created 4 years, 5 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/toolbar/toolbar_view.h" 5 #include "chrome/browser/ui/views/toolbar/toolbar_view.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/i18n/number_formatting.h" 10 #include "base/i18n/number_formatting.h"
(...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after
456 #endif 456 #endif
457 default: 457 default:
458 NOTREACHED(); 458 NOTREACHED();
459 } 459 }
460 } 460 }
461 461
462 //////////////////////////////////////////////////////////////////////////////// 462 ////////////////////////////////////////////////////////////////////////////////
463 // ToolbarView, ui::AcceleratorProvider implementation: 463 // ToolbarView, ui::AcceleratorProvider implementation:
464 464
465 bool ToolbarView::GetAcceleratorForCommandId(int command_id, 465 bool ToolbarView::GetAcceleratorForCommandId(int command_id,
466 ui::Accelerator* accelerator) { 466 ui::Accelerator* accelerator) const {
467 return GetWidget()->GetAccelerator(command_id, accelerator); 467 return GetWidget()->GetAccelerator(command_id, accelerator);
468 } 468 }
469 469
470 //////////////////////////////////////////////////////////////////////////////// 470 ////////////////////////////////////////////////////////////////////////////////
471 // ToolbarView, views::View overrides: 471 // ToolbarView, views::View overrides:
472 472
473 gfx::Size ToolbarView::GetPreferredSize() const { 473 gfx::Size ToolbarView::GetPreferredSize() const {
474 return GetSizeInternal(&View::GetPreferredSize); 474 return GetSizeInternal(&View::GetPreferredSize);
475 } 475 }
476 476
(...skipping 320 matching lines...) Expand 10 before | Expand all | Expand 10 after
797 SchedulePaint(); 797 SchedulePaint();
798 } 798 }
799 799
800 int ToolbarView::content_shadow_height() const { 800 int ToolbarView::content_shadow_height() const {
801 #if defined(USE_ASH) 801 #if defined(USE_ASH)
802 return GetLayoutConstant(TOOLBAR_CONTENT_SHADOW_HEIGHT_ASH); 802 return GetLayoutConstant(TOOLBAR_CONTENT_SHADOW_HEIGHT_ASH);
803 #else 803 #else
804 return GetLayoutConstant(TOOLBAR_CONTENT_SHADOW_HEIGHT); 804 return GetLayoutConstant(TOOLBAR_CONTENT_SHADOW_HEIGHT);
805 #endif 805 #endif
806 } 806 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/toolbar/toolbar_view.h ('k') | chrome/browser/ui/views/translate/translate_bubble_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698