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

Unified Diff: remoting/host/plugin/daemon_installer_win.h

Issue 10021003: Implemented on-demand installation of the Chromoting Host on Windows. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: The last piece of CR feeback. Rebased. Created 8 years, 8 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
« no previous file with comments | « remoting/host/plugin/daemon_controller_win.cc ('k') | remoting/host/plugin/daemon_installer_win.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/plugin/daemon_installer_win.h
diff --git a/remoting/host/plugin/daemon_installer_win.h b/remoting/host/plugin/daemon_installer_win.h
new file mode 100644
index 0000000000000000000000000000000000000000..aeac8299720b9f14ef3b8966d84f0ecc6b62e4b1
--- /dev/null
+++ b/remoting/host/plugin/daemon_installer_win.h
@@ -0,0 +1,47 @@
+// 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_DAEMON_INSTALLER_WIN_H_
+#define REMOTING_HOST_DAEMON_INSTALLER_WIN_H_
+
+#include <objbase.h>
+
+#include "base/basictypes.h"
+#include "base/callback.h"
+#include "base/memory/scoped_ptr.h"
+#include "remoting/host/plugin/daemon_controller.h"
+
+namespace remoting {
+
+class DaemonInstallerWin {
+ public:
+ typedef base::Callback<void (HRESULT result)> CompletionCallback;
+
+ virtual ~DaemonInstallerWin();
+
+ // Initiates download and installation of the Chromoting Host.
+ virtual void Install() = 0;
+
+ // Creates an instance of the Chromoting Host installer passing the completion
+ // callback to be called when the installation finishes. In case of an error
+ // returns NULL and passed the error code to |done|.
+ static scoped_ptr<DaemonInstallerWin> Create(CompletionCallback done);
+
+ protected:
+ DaemonInstallerWin(const CompletionCallback& done);
+
+ // Invokes the completion callback to report the installation result.
+ void Done(HRESULT result);
+
+ private:
+ // The completion callback that should be called to report the installation
+ // result.
+ CompletionCallback done_;
+
+ DISALLOW_COPY_AND_ASSIGN(DaemonInstallerWin);
+};
+
+} // namespace remoting
+
+#endif // REMOTING_HOST_DAEMON_INSTALLER_WIN_H_
« no previous file with comments | « remoting/host/plugin/daemon_controller_win.cc ('k') | remoting/host/plugin/daemon_installer_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698