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

Side by Side Diff: remoting/client/plugin/chromoting_instance.cc

Issue 8116021: Switch remoting/protocol to new callbacks (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: - Created 9 years, 2 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
« no previous file with comments | « remoting/client/chromoting_client.cc ('k') | remoting/host/chromoting_host.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/plugin/chromoting_instance.h" 5 #include "remoting/client/plugin/chromoting_instance.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after
311 } 311 }
312 312
313 protocol::LocalLoginCredentials* credentials = 313 protocol::LocalLoginCredentials* credentials =
314 new protocol::LocalLoginCredentials(); 314 new protocol::LocalLoginCredentials();
315 credentials->set_type(protocol::PASSWORD); 315 credentials->set_type(protocol::PASSWORD);
316 credentials->set_username(username); 316 credentials->set_username(username);
317 credentials->set_credential(password.data(), password.length()); 317 credentials->set_credential(password.data(), password.length());
318 318
319 host_connection_->host_stub()->BeginSessionRequest( 319 host_connection_->host_stub()->BeginSessionRequest(
320 credentials, 320 credentials,
321 new DeleteTask<protocol::LocalLoginCredentials>(credentials)); 321 base::Bind(&DeletePointer<protocol::LocalLoginCredentials>, credentials));
322 } 322 }
323 323
324 void ChromotingInstance::SetScaleToFit(bool scale_to_fit) { 324 void ChromotingInstance::SetScaleToFit(bool scale_to_fit) {
325 DCHECK(plugin_message_loop_->BelongsToCurrentThread()); 325 DCHECK(plugin_message_loop_->BelongsToCurrentThread());
326 326
327 if (scale_to_fit == scale_to_fit_) 327 if (scale_to_fit == scale_to_fit_)
328 return; 328 return;
329 329
330 scale_to_fit_ = scale_to_fit; 330 scale_to_fit_ = scale_to_fit;
331 if (scale_to_fit) { 331 if (scale_to_fit) {
(...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after
519 initial_policy_received_ = true; 519 initial_policy_received_ = true;
520 enable_client_nat_traversal_ = traversal_policy; 520 enable_client_nat_traversal_ = traversal_policy;
521 521
522 if (!delayed_connect_.is_null()) { 522 if (!delayed_connect_.is_null()) {
523 thread_proxy_->PostTask(FROM_HERE, delayed_connect_); 523 thread_proxy_->PostTask(FROM_HERE, delayed_connect_);
524 delayed_connect_.Reset(); 524 delayed_connect_.Reset();
525 } 525 }
526 } 526 }
527 527
528 } // namespace remoting 528 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/client/chromoting_client.cc ('k') | remoting/host/chromoting_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698