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

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

Issue 6811025: Change status button menu implementation from Menu2 to MenuItemView. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Changed refcount guard to use OS_CHROMEOS. Created 9 years, 8 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) 2006-2008 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_NETWORK_MENU_BUTTON_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_STATUS_NETWORK_MENU_BUTTON_H_
6 #define CHROME_BROWSER_CHROMEOS_STATUS_NETWORK_MENU_BUTTON_H_ 6 #define CHROME_BROWSER_CHROMEOS_STATUS_NETWORK_MENU_BUTTON_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
11 #include "base/timer.h" 11 #include "base/timer.h"
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
61 // NetworkLibrary::NetworkManagerObserver implementation. 61 // NetworkLibrary::NetworkManagerObserver implementation.
62 virtual void OnNetworkManagerChanged(NetworkLibrary* cros); 62 virtual void OnNetworkManagerChanged(NetworkLibrary* cros);
63 // NetworkLibrary::NetworkObserver implementation. 63 // NetworkLibrary::NetworkObserver implementation.
64 virtual void OnNetworkChanged(NetworkLibrary* cros, const Network* network); 64 virtual void OnNetworkChanged(NetworkLibrary* cros, const Network* network);
65 // NetworkLibrary::CellularDataPlanObserver implementation. 65 // NetworkLibrary::CellularDataPlanObserver implementation.
66 virtual void OnCellularDataPlanChanged(NetworkLibrary* cros); 66 virtual void OnCellularDataPlanChanged(NetworkLibrary* cros);
67 67
68 protected: 68 protected:
69 // NetworkMenu implementation: 69 // NetworkMenu implementation:
70 virtual bool IsBrowserMode() const; 70 virtual bool IsBrowserMode() const;
71 virtual views::MenuButton* GetMenuButton() { return this; }
71 virtual gfx::NativeWindow GetNativeWindow() const; 72 virtual gfx::NativeWindow GetNativeWindow() const;
72 virtual void OpenButtonOptions(); 73 virtual void OpenButtonOptions();
73 virtual bool ShouldOpenButtonOptions() const; 74 virtual bool ShouldOpenButtonOptions() const;
74 75
75 private: 76 private:
76 // Sets the icon and the badge. 77 // Sets the icon and the badge.
77 void SetIconAndBadge(const SkBitmap* icon, const SkBitmap* badge); 78 void SetIconAndBadge(const SkBitmap* icon, const SkBitmap* badge);
78 // Sets the icon only. Keep the previous badge. 79 // Sets the icon only. Keep the previous badge.
79 void SetIconOnly(const SkBitmap* icon); 80 void SetIconOnly(const SkBitmap* icon);
80 // Sets the badge only. Keep the previous icon. 81 // Sets the badge only. Keep the previous icon.
(...skipping 22 matching lines...) Expand all
103 // If any network is currently active, this is the service path of the one 104 // If any network is currently active, this is the service path of the one
104 // whose status is displayed in the network menu button. 105 // whose status is displayed in the network menu button.
105 std::string active_network_; 106 std::string active_network_;
106 107
107 DISALLOW_COPY_AND_ASSIGN(NetworkMenuButton); 108 DISALLOW_COPY_AND_ASSIGN(NetworkMenuButton);
108 }; 109 };
109 110
110 } // namespace chromeos 111 } // namespace chromeos
111 112
112 #endif // CHROME_BROWSER_CHROMEOS_STATUS_NETWORK_MENU_BUTTON_H_ 113 #endif // CHROME_BROWSER_CHROMEOS_STATUS_NETWORK_MENU_BUTTON_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698