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

Unified Diff: components/proximity_auth/webui/proximity_auth_webui_handler.h

Issue 1302313004: Replace ProximityAuthUIDelegate with ProximityAuthClient. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@proximity_auth_client
Patch Set: fixes Created 5 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: components/proximity_auth/webui/proximity_auth_webui_handler.h
diff --git a/components/proximity_auth/webui/proximity_auth_webui_handler.h b/components/proximity_auth/webui/proximity_auth_webui_handler.h
index ff983f07c362128ab71c9f0a63ea3c0cc6e29bd7..007495b4087a7e7ebcf4c1cce011e1b978d51661 100644
--- a/components/proximity_auth/webui/proximity_auth_webui_handler.h
+++ b/components/proximity_auth/webui/proximity_auth_webui_handler.h
@@ -15,7 +15,7 @@
#include "components/proximity_auth/cryptauth/cryptauth_enrollment_manager.h"
#include "components/proximity_auth/cryptauth/cryptauth_gcm_manager.h"
#include "components/proximity_auth/logging/log_buffer.h"
-#include "components/proximity_auth/webui/proximity_auth_ui_delegate.h"
+#include "components/proximity_auth/proximity_auth_client.h"
#include "content/public/browser/web_ui_message_handler.h"
namespace base {
@@ -47,8 +47,9 @@ class ProximityAuthWebUIHandler : public content::WebUIMessageHandler,
public ConnectionObserver,
public ClientObserver {
public:
- // |delegate| is not owned and must outlive this instance.
- explicit ProximityAuthWebUIHandler(ProximityAuthUIDelegate* delegate);
+ // |client_| is not owned and must outlive this instance.
+ explicit ProximityAuthWebUIHandler(
+ ProximityAuthClient* proximity_auth_client);
~ProximityAuthWebUIHandler() override;
// content::WebUIMessageHandler:
@@ -153,7 +154,7 @@ class ProximityAuthWebUIHandler : public content::WebUIMessageHandler,
scoped_ptr<base::ListValue> GetUnlockKeysList();
// The delegate used to fetch dependencies. Must outlive this instance.
- ProximityAuthUIDelegate* delegate_;
+ ProximityAuthClient* proximity_auth_client_;
// Creates CryptAuth client instances to make API calls.
scoped_ptr<CryptAuthClientFactory> cryptauth_client_factory_;
@@ -164,12 +165,9 @@ class ProximityAuthWebUIHandler : public content::WebUIMessageHandler,
// The flow for getting a list of reachable phones.
scoped_ptr<ReachablePhoneFlow> reachable_phone_flow_;
- // Member variables related to CryptAuth debugging.
- // TODO(tengs): These members are temporarily used for development.
- scoped_ptr<PrefService> pref_service;
- scoped_ptr<CryptAuthGCMManager> gcm_manager_;
- scoped_ptr<CryptAuthEnrollmentManager> enrollment_manager_;
- scoped_ptr<CryptAuthDeviceManager> device_manager_;
+ // True if we get a message from the loaded WebContents to know that it is
+ // initialized, and we can inject JavaScript.
+ bool web_contents_initialized_;
// Member variables for connecting to and authenticating the remote device.
// TODO(tengs): Support multiple simultaenous connections.

Powered by Google App Engine
This is Rietveld 408576698