Index: remoting/host/curtain_mode_mac.h |
diff --git a/remoting/host/curtain_mode_mac.h b/remoting/host/curtain_mode_mac.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..9973b14a43dc29290c8b7723711eeb48f8326c06 |
--- /dev/null |
+++ b/remoting/host/curtain_mode_mac.h |
@@ -0,0 +1,41 @@ |
+// Copyright (c) 2012 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef REMOTING_HOST_CURTAIN_MODE_MAC_H_ |
+#define REMOTING_HOST_CURTAIN_MODE_MAC_H_ |
+ |
+#include <Carbon/Carbon.h> |
Lambros
2012/08/08 00:48:29
nit: blank line between C and C++ headers
Jamie
2012/08/08 01:39:43
Done.
|
+#include <string> |
+ |
+#include "base/callback.h" |
+#include "base/compiler_specific.h" |
+#include "remoting/host/host_status_observer.h" |
+ |
+namespace remoting { |
+ |
+class CurtainMode : public HostStatusObserver { |
+ public: |
+ CurtainMode(); |
+ virtual ~CurtainMode(); |
+ |
+ // Set the callback to be invoked when the switched-out remote session is |
+ // switched back to the console. |
+ bool Init(const base::Closure& on_session_activate); |
+ |
+ // Overridden from HostStatusObserver |
+ virtual void OnClientAuthenticated(const std::string& jid) OVERRIDE; |
+ |
+ private: |
+ static OSStatus SessionActivateHandler(EventHandlerCallRef handler, |
+ EventRef event, |
+ void* user_data); |
+ void OnSessionActivate(); |
+ |
+ base::Closure on_session_activate_; |
+ EventHandlerRef event_handler_; |
+}; |
+ |
+} |
+ |
+#endif |