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

Unified Diff: chrome/browser/ui/ash/chrome_shell_delegate.h

Issue 1416313004: arc-bridge: Start ArcBridgeService on session start (Closed) Base URL: https://chromium.googlesource.com/a/chromium/src.git@master
Patch Set: Moved all ARC-related initialization to ChromeShellDelegate Created 5 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/ash/chrome_shell_delegate.h
diff --git a/chrome/browser/ui/ash/chrome_shell_delegate.h b/chrome/browser/ui/ash/chrome_shell_delegate.h
index e069b716c781e133de0fe778e1012b8bc8453b99..fdb281b3917ba9eb30f4ffa61d8dcfd89d5bf578 100644
--- a/chrome/browser/ui/ash/chrome_shell_delegate.h
+++ b/chrome/browser/ui/ash/chrome_shell_delegate.h
@@ -17,6 +17,10 @@
#include "content/public/browser/notification_observer.h"
#include "content/public/browser/notification_registrar.h"
+#if defined(OS_CHROMEOS)
+#include "ash/shell_observer.h"
+#endif
+
class Browser;
namespace ash {
@@ -103,6 +107,22 @@ class ChromeShellDelegate : public ash::ShellDelegate,
#if defined(OS_CHROMEOS)
scoped_ptr<chromeos::DisplayConfigurationObserver>
display_configuration_observer_;
+
+ // An Observer to track session state and start/stop ARC accordingly.
+ class ArcSessionObserver : public ash::ShellObserver {
oshima 2015/11/11 22:07:38 move the class definition in .cc file.
Luis Héctor Chávez 2015/11/11 22:11:12 I tried to do that, but if I put it in chrome_shel
oshima 2015/11/11 22:55:30 you can do this chrome_shell_delegate.h: class C
Luis Héctor Chávez 2015/11/11 23:41:07 That's what I tried. Compilation fails in chrome_s
oshima 2015/11/12 19:09:51 I see. Too bad given that this will soon be chrome
sky 2015/11/12 22:06:53 Move this above other fields. That is, keep all fi
Luis Héctor Chávez 2015/11/12 22:21:38 Done.
+ public:
+ ArcSessionObserver();
+ ~ArcSessionObserver() override;
+
+ // ash::ShellObserver overrides:
+ void OnLoginStateChanged(ash::user::LoginStatus status) override;
+
+ private:
+ DISALLOW_COPY_AND_ASSIGN(ArcSessionObserver);
+ };
+
+ // An Observer to track session state and start/stop ARC accordingly.
+ scoped_ptr<ArcSessionObserver> arc_session_observer_;
#endif
DISALLOW_COPY_AND_ASSIGN(ChromeShellDelegate);

Powered by Google App Engine
This is Rietveld 408576698