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

Side by Side Diff: remoting/client/chromoting_client.cc

Issue 7008003: Wire in OAuth2 support into non-sandboxed connections in libjingle. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "remoting/client/chromoting_client.h" 5 #include "remoting/client/chromoting_client.h"
6 6
7 #include "base/message_loop.h" 7 #include "base/message_loop.h"
8 #include "remoting/base/tracer.h" 8 #include "remoting/base/tracer.h"
9 #include "remoting/client/chromoting_view.h" 9 #include "remoting/client/chromoting_view.h"
10 #include "remoting/client/client_context.h" 10 #include "remoting/client/client_context.h"
(...skipping 30 matching lines...) Expand all
41 } 41 }
42 42
43 void ChromotingClient::Start() { 43 void ChromotingClient::Start() {
44 if (message_loop() != MessageLoop::current()) { 44 if (message_loop() != MessageLoop::current()) {
45 message_loop()->PostTask( 45 message_loop()->PostTask(
46 FROM_HERE, 46 FROM_HERE,
47 NewRunnableMethod(this, &ChromotingClient::Start)); 47 NewRunnableMethod(this, &ChromotingClient::Start));
48 return; 48 return;
49 } 49 }
50 50
51 connection_->Connect(config_.username, config_.auth_token, config_.host_jid, 51 connection_->Connect(config_.username, config_.auth_token,
52 config_.auth_service, config_.host_jid,
52 config_.nonce, this, this, this); 53 config_.nonce, this, this, this);
53 54
54 if (!view_->Initialize()) { 55 if (!view_->Initialize()) {
55 ClientDone(); 56 ClientDone();
56 } 57 }
57 } 58 }
58 59
59 void ChromotingClient::StartSandboxed(scoped_refptr<XmppProxy> xmpp_proxy, 60 void ChromotingClient::StartSandboxed(scoped_refptr<XmppProxy> xmpp_proxy,
60 const std::string& your_jid, 61 const std::string& your_jid,
61 const std::string& host_jid) { 62 const std::string& host_jid) {
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
305 if (msg->success()) { 306 if (msg->success()) {
306 connection_->OnClientAuthenticated(); 307 connection_->OnClientAuthenticated();
307 } 308 }
308 309
309 view_->UpdateLoginStatus(msg->success(), msg->error_info()); 310 view_->UpdateLoginStatus(msg->success(), msg->error_info());
310 done->Run(); 311 done->Run();
311 delete done; 312 delete done;
312 } 313 }
313 314
314 } // namespace remoting 315 } // namespace remoting
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698