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

Side by Side Diff: chrome/browser/chromeos/status/status_area_button.h

Issue 8638016: Add OVERRIDE to chrome/browser/chromeos/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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) 2011 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 #ifndef CHROME_BROWSER_CHROMEOS_STATUS_STATUS_AREA_BUTTON_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_STATUS_STATUS_AREA_BUTTON_H_
6 #define CHROME_BROWSER_CHROMEOS_STATUS_STATUS_AREA_BUTTON_H_ 6 #define CHROME_BROWSER_CHROMEOS_STATUS_STATUS_AREA_BUTTON_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/compiler_specific.h"
9 #include "base/string16.h" 10 #include "base/string16.h"
10 #include "views/controls/button/menu_button.h" 11 #include "views/controls/button/menu_button.h"
11 #include "views/controls/menu/view_menu_delegate.h" 12 #include "views/controls/menu/view_menu_delegate.h"
12 13
13 namespace gfx { 14 namespace gfx {
14 class Font; 15 class Font;
15 } 16 }
16 17
17 // Button to be used to represent status and allow menus to be popped up. 18 // Button to be used to represent status and allow menus to be popped up.
18 // Shows current button state by drawing a border around the current icon. 19 // Shows current button state by drawing a border around the current icon.
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 // Handle visibility changes (e.g. resize the status area). 51 // Handle visibility changes (e.g. resize the status area).
51 virtual void ButtonVisibilityChanged(views::View* button_view) = 0; 52 virtual void ButtonVisibilityChanged(views::View* button_view) = 0;
52 53
53 protected: 54 protected:
54 virtual ~Delegate() {} 55 virtual ~Delegate() {}
55 }; 56 };
56 57
57 StatusAreaButton(Delegate* button_delegate, 58 StatusAreaButton(Delegate* button_delegate,
58 views::ViewMenuDelegate* menu_delegate); 59 views::ViewMenuDelegate* menu_delegate);
59 virtual ~StatusAreaButton() {} 60 virtual ~StatusAreaButton() {}
60 virtual void PaintButton(gfx::Canvas* canvas, PaintButtonMode mode); 61 virtual void PaintButton(gfx::Canvas* canvas, PaintButtonMode mode) OVERRIDE;
61 62
62 // Overrides TextButton's SetText to clear max text size before seting new 63 // Overrides TextButton's SetText to clear max text size before seting new
63 // text content so that the button size would fit the new text size. 64 // text content so that the button size would fit the new text size.
64 virtual void SetText(const string16& text); 65 virtual void SetText(const string16& text) OVERRIDE;
65 66
66 // views::MenuButton overrides. 67 // views::MenuButton overrides.
67 virtual bool Activate() OVERRIDE; 68 virtual bool Activate() OVERRIDE;
68 69
69 // View overrides. 70 // View overrides.
70 virtual gfx::Size GetPreferredSize() OVERRIDE; 71 virtual gfx::Size GetPreferredSize() OVERRIDE;
71 virtual gfx::Insets GetInsets() const OVERRIDE; 72 virtual gfx::Insets GetInsets() const OVERRIDE;
72 virtual void OnThemeChanged() OVERRIDE; 73 virtual void OnThemeChanged() OVERRIDE;
73 virtual void SetVisible(bool visible) OVERRIDE; 74 virtual void SetVisible(bool visible) OVERRIDE;
74 virtual bool HitTest(const gfx::Point& l) const OVERRIDE; 75 virtual bool HitTest(const gfx::Point& l) const OVERRIDE;
(...skipping 23 matching lines...) Expand all
98 99
99 private: 100 private:
100 void UpdateTextStyle(); 101 void UpdateTextStyle();
101 102
102 Delegate* delegate_; 103 Delegate* delegate_;
103 104
104 DISALLOW_COPY_AND_ASSIGN(StatusAreaButton); 105 DISALLOW_COPY_AND_ASSIGN(StatusAreaButton);
105 }; 106 };
106 107
107 #endif // CHROME_BROWSER_CHROMEOS_STATUS_STATUS_AREA_BUTTON_H_ 108 #endif // CHROME_BROWSER_CHROMEOS_STATUS_STATUS_AREA_BUTTON_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698