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

Side by Side Diff: chrome/browser/ui/ash/system_tray_client.h

Issue 2427823002: cros: Move system tray delegate widget container code to SystemTrayClient (Closed)
Patch Set: cleanup Created 4 years, 2 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_UI_ASH_SYSTEM_TRAY_CLIENT_H_ 5 #ifndef CHROME_BROWSER_UI_ASH_SYSTEM_TRAY_CLIENT_H_
6 #define CHROME_BROWSER_UI_ASH_SYSTEM_TRAY_CLIENT_H_ 6 #define CHROME_BROWSER_UI_ASH_SYSTEM_TRAY_CLIENT_H_
7 7
8 #include "ash/public/interfaces/system_tray.mojom.h" 8 #include "ash/public/interfaces/system_tray.mojom.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "chrome/browser/chromeos/system/system_clock_observer.h" 10 #include "chrome/browser/chromeos/system/system_clock_observer.h"
11 #include "mojo/public/cpp/bindings/binding.h" 11 #include "mojo/public/cpp/bindings/binding.h"
12 12
13 namespace ash {
14 enum class LoginStatus;
15 }
16
13 // Handles method calls delegated back to chrome from ash. Also notifies ash of 17 // Handles method calls delegated back to chrome from ash. Also notifies ash of
14 // relevant state changes in chrome. 18 // relevant state changes in chrome.
15 // TODO: Consider renaming this to SystemTrayClientChromeOS. 19 // TODO: Consider renaming this to SystemTrayClientChromeOS.
16 class SystemTrayClient : public ash::mojom::SystemTrayClient, 20 class SystemTrayClient : public ash::mojom::SystemTrayClient,
17 public chromeos::system::SystemClockObserver { 21 public chromeos::system::SystemClockObserver {
18 public: 22 public:
19 SystemTrayClient(); 23 SystemTrayClient();
20 ~SystemTrayClient() override; 24 ~SystemTrayClient() override;
21 25
22 static SystemTrayClient* Get(); 26 static SystemTrayClient* Get();
23 27
28 // Returns the login state based on the user type, lock screen status, etc.
29 static ash::LoginStatus GetUserLoginStatus();
30
31 // Returns the container id for the parent window for new dialogs. The parent
32 // varies based on the current login and lock screen state.
33 static int GetDialogParentContainerId();
34
24 // ash::mojom::SystemTrayClient: 35 // ash::mojom::SystemTrayClient:
25 void ShowSettings() override; 36 void ShowSettings() override;
26 void ShowDateSettings() override; 37 void ShowDateSettings() override;
27 void ShowDisplaySettings() override; 38 void ShowDisplaySettings() override;
28 void ShowPowerSettings() override; 39 void ShowPowerSettings() override;
29 void ShowChromeSlow() override; 40 void ShowChromeSlow() override;
30 void ShowIMESettings() override; 41 void ShowIMESettings() override;
31 void ShowHelp() override; 42 void ShowHelp() override;
32 void ShowAccessibilityHelp() override; 43 void ShowAccessibilityHelp() override;
33 void ShowAccessibilitySettings() override; 44 void ShowAccessibilitySettings() override;
(...skipping 14 matching lines...) Expand all
48 // Handles errors on the |system_tray_| interface connection. 59 // Handles errors on the |system_tray_| interface connection.
49 void OnClientConnectionError(); 60 void OnClientConnectionError();
50 61
51 // System tray mojo service in ash. 62 // System tray mojo service in ash.
52 ash::mojom::SystemTrayPtr system_tray_; 63 ash::mojom::SystemTrayPtr system_tray_;
53 64
54 DISALLOW_COPY_AND_ASSIGN(SystemTrayClient); 65 DISALLOW_COPY_AND_ASSIGN(SystemTrayClient);
55 }; 66 };
56 67
57 #endif // CHROME_BROWSER_UI_ASH_SYSTEM_TRAY_CLIENT_H_ 68 #endif // CHROME_BROWSER_UI_ASH_SYSTEM_TRAY_CLIENT_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/ash/network_connect_delegate_chromeos.cc ('k') | chrome/browser/ui/ash/system_tray_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698