diff options
author | wez@chromium.org <wez@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-20 01:01:06 +0000 |
---|---|---|
committer | wez@chromium.org <wez@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-20 01:01:06 +0000 |
commit | 9722cfd1629cc0ecaf0fc4f7f10174ded220afe5 (patch) | |
tree | d7b0268cef79ae78fc7c54b5dfe1ddd1c9fc4927 /remoting/host | |
parent | 8fb0ef0c370115adf24bfae5b79d30f802c9c90f (diff) | |
download | chromium_src-9722cfd1629cc0ecaf0fc4f7f10174ded220afe5.zip chromium_src-9722cfd1629cc0ecaf0fc4f7f10174ded220afe5.tar.gz chromium_src-9722cfd1629cc0ecaf0fc4f7f10174ded220afe5.tar.bz2 |
Move the call to ChromotingHost::Start to the right place.
BUG=
TEST=Run the Remoting WebApp for Sharing. When you click the button it should print an Access Code.
Review URL: http://codereview.chromium.org/7051018
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@86027 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'remoting/host')
-rw-r--r-- | remoting/host/host_plugin.cc | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/remoting/host/host_plugin.cc b/remoting/host/host_plugin.cc index 9568017..ac36cfa 100644 --- a/remoting/host/host_plugin.cc +++ b/remoting/host/host_plugin.cc @@ -429,6 +429,11 @@ bool HostNPScriptObject::Connect(const NPVariant* args, host_config_ = host_config; register_request_ = register_request; + // Start the Host. + // TODO(wez): Attach to the Host for notifications of state changes. + // It currently has no interface for that, though. + host_->Start(NewRunnableMethod(this, &HostNPScriptObject::OnHostShutdown)); + OnStateChanged(kRequestedAccessCode); return true; } @@ -469,12 +474,6 @@ void HostNPScriptObject::OnReceivedSupportID(bool success, access_code_ = support_id + "-" + host_secret_; host_secret_ = std::string(); - // TODO(wez): Attach to the Host for notifications of state changes. - // It currently has no interface for that, though. - - // Start the Host. - host_->Start(NewRunnableMethod(this, &HostNPScriptObject::OnHostShutdown)); - // Let the caller know that life is good. OnStateChanged(kReceivedAccessCode); } |