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

Unified Diff: remoting/host/it2me/it2me_host.h

Issue 1458323002: Simplify It2Me host shutdown (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
« no previous file with comments | « remoting/host/host_mock_objects.h ('k') | remoting/host/it2me/it2me_host.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/host/it2me/it2me_host.h
diff --git a/remoting/host/it2me/it2me_host.h b/remoting/host/it2me/it2me_host.h
index 0b16085590738ba092da60f12d5e1ecbe612ab60..0619dd6f31483cf1be6cadf669e0eb20d8eb27ad 100644
--- a/remoting/host/it2me/it2me_host.h
+++ b/remoting/host/it2me/it2me_host.h
@@ -42,7 +42,6 @@ enum It2MeHostState {
kRequestedAccessCode,
kReceivedAccessCode,
kConnected,
- kDisconnecting,
kError,
kInvalidDomainError
};
@@ -74,8 +73,7 @@ class It2MeHost : public base::RefCountedThreadSafe<It2MeHost>,
// Creates It2Me host structures and starts the host.
virtual void Connect();
- // Disconnects the host, ready for tear-down.
- // Also called internally, from the network thread.
+ // Disconnects and shuts down the host.
virtual void Disconnect();
// TODO (weitaosu): Remove RequestNatPolicy from It2MeHost.
@@ -84,7 +82,7 @@ class It2MeHost : public base::RefCountedThreadSafe<It2MeHost>,
// remoting::HostStatusObserver implementation.
void OnAccessDenied(const std::string& jid) override;
- void OnClientAuthenticated(const std::string& jid) override;
+ void OnClientConnected(const std::string& jid) override;
void OnClientDisconnected(const std::string& jid) override;
void SetStateForTesting(It2MeHostState state,
@@ -128,14 +126,6 @@ class It2MeHost : public base::RefCountedThreadSafe<It2MeHost>,
const base::TimeDelta& lifetime,
const std::string& error_message);
- // Shuts down |host_| on the network thread and posts ShutdownOnUiThread()
- // to shut down UI thread resources.
- void ShutdownOnNetworkThread();
-
- // Shuts down |desktop_environment_factory_| and |policy_watcher_| on
- // the UI thread.
- void ShutdownOnUiThread();
-
// Called when initial policies are read, and when they change.
void OnPolicyUpdate(scoped_ptr<base::DictionaryValue> policies);
@@ -146,6 +136,8 @@ class It2MeHost : public base::RefCountedThreadSafe<It2MeHost>,
void UpdateNatPolicy(bool nat_traversal_enabled);
void UpdateHostDomainPolicy(const std::string& host_domain);
+ void Shutdown();
+
// Caller supplied fields.
scoped_ptr<ChromotingHostContext> host_context_;
scoped_refptr<base::SingleThreadTaskRunner> task_runner_;
« no previous file with comments | « remoting/host/host_mock_objects.h ('k') | remoting/host/it2me/it2me_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698