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

Side by Side Diff: remoting/client/jni/jni_pairing_secret_fetcher.h

Issue 2142253002: [Remoting Android] Fix GetWeakPtr() calls on multiple threads (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #ifndef REMOTING_CLIENT_JNI_JNI_PAIRING_SECRET_FETCHER_H_ 5 #ifndef REMOTING_CLIENT_JNI_JNI_PAIRING_SECRET_FETCHER_H_
6 #define REMOTING_CLIENT_JNI_JNI_PAIRING_SECRET_FETCHER_H_ 6 #define REMOTING_CLIENT_JNI_JNI_PAIRING_SECRET_FETCHER_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "remoting/protocol/client_authentication_config.h" 10 #include "remoting/protocol/client_authentication_config.h"
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 44
45 ChromotingJniRuntime* jni_runtime_; 45 ChromotingJniRuntime* jni_runtime_;
46 base::WeakPtr<JniClient> jni_client_; 46 base::WeakPtr<JniClient> jni_client_;
47 47
48 std::string host_id_; 48 std::string host_id_;
49 49
50 // Pass this the user's PIN once we have it. To be assigned and accessed on 50 // Pass this the user's PIN once we have it. To be assigned and accessed on
51 // the UI thread, but must be posted to the network thread to call it. 51 // the UI thread, but must be posted to the network thread to call it.
52 protocol::SecretFetchedCallback callback_; 52 protocol::SecretFetchedCallback callback_;
53 53
54 base::WeakPtr<JniPairingSecretFetcher> weak_ptr_;
54 base::WeakPtrFactory<JniPairingSecretFetcher> weak_factory_; 55 base::WeakPtrFactory<JniPairingSecretFetcher> weak_factory_;
55 56
56 DISALLOW_COPY_AND_ASSIGN(JniPairingSecretFetcher); 57 DISALLOW_COPY_AND_ASSIGN(JniPairingSecretFetcher);
57 }; 58 };
58 59
59 } // namespace remoting 60 } // namespace remoting
60 61
61 #endif // REMOTING_CLIENT_JNI_JNI_PAIRING_SECRET_FETCHER_H_ 62 #endif // REMOTING_CLIENT_JNI_JNI_PAIRING_SECRET_FETCHER_H_
OLDNEW
« no previous file with comments | « remoting/client/jni/jni_display_handler.cc ('k') | remoting/client/jni/jni_pairing_secret_fetcher.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698