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

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

Issue 15927028: Update remoting/ to use WeakPtr<T>::get() instead of implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/pepper_xmpp_proxy.h" 5 #include "remoting/client/plugin/pepper_xmpp_proxy.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/location.h" 8 #include "base/location.h"
9 #include "base/message_loop_proxy.h" 9 #include "base/message_loop_proxy.h"
10 10
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 send_iq_callback_.Run(request_xml); 44 send_iq_callback_.Run(request_xml);
45 } 45 }
46 46
47 void PepperXmppProxy::OnIq(const std::string& response_xml) { 47 void PepperXmppProxy::OnIq(const std::string& response_xml) {
48 if (!callback_task_runner_->BelongsToCurrentThread()) { 48 if (!callback_task_runner_->BelongsToCurrentThread()) {
49 callback_task_runner_->PostTask( 49 callback_task_runner_->PostTask(
50 FROM_HERE, base::Bind(&PepperXmppProxy::OnIq, this, response_xml)); 50 FROM_HERE, base::Bind(&PepperXmppProxy::OnIq, this, response_xml));
51 return; 51 return;
52 } 52 }
53 53
54 if (callback_) 54 if (callback_.get())
55 callback_->OnIq(response_xml); 55 callback_->OnIq(response_xml);
56 } 56 }
57 57
58 } // namespace remoting 58 } // namespace remoting
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698