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

Side by Side Diff: ash/system/locale/tray_locale.h

Issue 10443004: Move common notification layout to base class (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 8 years, 7 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
« no previous file with comments | « no previous file | ash/system/locale/tray_locale.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 ASH_SYSTEM_LOCALE_TRAY_LOCALE_H_ 5 #ifndef ASH_SYSTEM_LOCALE_TRAY_LOCALE_H_
6 #define ASH_SYSTEM_LOCALE_TRAY_LOCALE_H_ 6 #define ASH_SYSTEM_LOCALE_TRAY_LOCALE_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
11 #include "ash/system/locale/locale_observer.h" 11 #include "ash/system/locale/locale_observer.h"
12 #include "ash/system/tray/tray_image_item.h" 12 #include "ash/system/tray/system_tray_item.h"
13 13
14 namespace ash { 14 namespace ash {
15 namespace internal { 15 namespace internal {
16 16
17 namespace tray { 17 namespace tray {
18 class LocaleNotificationView; 18 class LocaleNotificationView;
19 } 19 }
20 20
21 class TrayLocale : public TrayImageItem, 21 class TrayLocale : public SystemTrayItem,
22 public LocaleObserver { 22 public LocaleObserver {
23 public: 23 public:
24 TrayLocale(); 24 TrayLocale();
25 virtual ~TrayLocale(); 25 virtual ~TrayLocale();
26 26
27 private: 27 private:
28 // Overridden from TrayImageItem. 28 // Overridden from TrayImageItem.
29 virtual bool GetInitialVisibility() OVERRIDE;
30 virtual views::View* CreateNotificationView( 29 virtual views::View* CreateNotificationView(
31 user::LoginStatus status) OVERRIDE; 30 user::LoginStatus status) OVERRIDE;
32 virtual void DestroyNotificationView() OVERRIDE; 31 virtual void DestroyNotificationView() OVERRIDE;
33 32
34 // Overridden from LocaleObserver. 33 // Overridden from LocaleObserver.
35 virtual void OnLocaleChanged(LocaleObserver::Delegate* delegate, 34 virtual void OnLocaleChanged(LocaleObserver::Delegate* delegate,
36 const std::string& cur_locale, 35 const std::string& cur_locale,
37 const std::string& from_locale, 36 const std::string& from_locale,
38 const std::string& to_locale) OVERRIDE; 37 const std::string& to_locale) OVERRIDE;
39 38
40 tray::LocaleNotificationView* notification_; 39 tray::LocaleNotificationView* notification_;
41 LocaleObserver::Delegate* delegate_; 40 LocaleObserver::Delegate* delegate_;
42 std::string cur_locale_; 41 std::string cur_locale_;
43 std::string from_locale_; 42 std::string from_locale_;
44 std::string to_locale_; 43 std::string to_locale_;
45 44
46 DISALLOW_COPY_AND_ASSIGN(TrayLocale); 45 DISALLOW_COPY_AND_ASSIGN(TrayLocale);
47 }; 46 };
48 47
49 } // namespace internal 48 } // namespace internal
50 } // namespace ash 49 } // namespace ash
51 50
52 #endif // ASH_SYSTEM_LOCALE_TRAY_LOCALE_H_ 51 #endif // ASH_SYSTEM_LOCALE_TRAY_LOCALE_H_
OLDNEW
« no previous file with comments | « no previous file | ash/system/locale/tray_locale.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698