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

Unified Diff: remoting/host/desktop_session_win.h

Issue 12544020: Remote RDP sessions, rather than the console, if curtain-mode is configured. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: remoting/host/desktop_session_win.h
diff --git a/remoting/host/desktop_session_win.h b/remoting/host/desktop_session_win.h
index 976da9e08d02c906bffdad38d190dca6af07d687..58631c23910ae8c8bc2e61d3cd9abd03df19eb16 100644
--- a/remoting/host/desktop_session_win.h
+++ b/remoting/host/desktop_session_win.h
@@ -5,93 +5,24 @@
#ifndef REMOTING_HOST_DESKTOP_SESSION_WIN_H_
#define REMOTING_HOST_DESKTOP_SESSION_WIN_H_
-#include "base/files/file_path.h"
#include "base/memory/ref_counted.h"
#include "base/memory/scoped_ptr.h"
-#include "base/win/scoped_handle.h"
-#include "ipc/ipc_platform_file.h"
-#include "remoting/host/desktop_session.h"
-#include "remoting/host/win/wts_terminal_observer.h"
-#include "remoting/host/worker_process_ipc_delegate.h"
-
-namespace tracked_objects {
-class Location;
-} // namespace tracked_objects
namespace remoting {
class AutoThreadTaskRunner;
class DaemonProcess;
+class DesktopSession;
struct DesktopSessionParams;
-class SasInjector;
-class WorkerProcessLauncher;
-class WtsTerminalMonitor;
-// DesktopSession implementation which attaches to the host's physical console.
-// Receives IPC messages from the desktop process, running in the console
-// session, via |WorkerProcessIpcDelegate|, and monitors console session
-// attach/detach events via |WtsConsoleObserer|.
-// TODO(alexeypa): replace |WtsTerminalObserver| with an interface capable of
-// monitoring both the console and RDP connections. See http://crbug.com/137696.
-class DesktopSessionWin
- : public DesktopSession,
- public WorkerProcessIpcDelegate,
- public WtsTerminalObserver {
- public:
- // Passes the owning |daemon_process|, a unique identifier of the desktop
- // session |id| and the interface for monitoring console session attach/detach
- // events. Both |daemon_process| and |monitor| must outlive |this|.
- DesktopSessionWin(
- scoped_refptr<AutoThreadTaskRunner> main_task_runner,
+// Creates a desktop session instance.
+scoped_ptr<DesktopSession> CreateDesktopSessionWin(
+ scoped_refptr<AutoThreadTaskRunner> caller_task_runner,
Wez 2013/03/12 01:21:11 I think it's cleaner to keep separate CreateForCon
alexeypa (please no reviews) 2013/03/12 20:21:15 Done.
scoped_refptr<AutoThreadTaskRunner> io_task_runner,
DaemonProcess* daemon_process,
int id,
const DesktopSessionParams& params,
- bool virtual_terminal,
- WtsTerminalMonitor* monitor);
- virtual ~DesktopSessionWin();
-
- // WorkerProcessIpcDelegate implementation.
- virtual void OnChannelConnected(int32 peer_pid) OVERRIDE;
- virtual bool OnMessageReceived(const IPC::Message& message) OVERRIDE;
- virtual void OnPermanentError() OVERRIDE;
-
- // WtsTerminalObserver implementation.
- virtual void OnSessionAttached(uint32 session_id) OVERRIDE;
- virtual void OnSessionDetached() OVERRIDE;
-
- private:
- // ChromotingDesktopDaemonMsg_DesktopAttached handler.
- void OnDesktopSessionAgentAttached(IPC::PlatformFileForTransit desktop_pipe);
-
- // ChromotingDesktopDaemonMsg_InjectSas handler.
- void OnInjectSas();
-
- // Restarts the desktop process.
- void RestartDesktopProcess(const tracked_objects::Location& location);
-
- // Task runner on which public methods of this class should be called.
- scoped_refptr<AutoThreadTaskRunner> main_task_runner_;
-
- // Message loop used by the IPC channel.
- scoped_refptr<AutoThreadTaskRunner> io_task_runner_;
-
- // Contains the full path to the desktop binary.
- base::FilePath desktop_binary_;
-
- // Handle of the desktop process.
- base::win::ScopedHandle desktop_process_;
-
- // Launches and monitors the desktop process.
- scoped_ptr<WorkerProcessLauncher> launcher_;
-
- // Pointer used to unsubscribe from session attach and detach events.
- WtsTerminalMonitor* monitor_;
-
- scoped_ptr<SasInjector> sas_injector_;
-
- DISALLOW_COPY_AND_ASSIGN(DesktopSessionWin);
-};
+ bool virtual_terminal);
} // namespace remoting

Powered by Google App Engine
This is Rietveld 408576698