Don't preload rarely seen large images
[chromium-blink-merge.git] / components / proximity_auth / webui / proximity_auth_ui_delegate.h
blob6de61e790f5c48041d7dc8e3261c4b5057d6c6b9
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef COMPONENTS_PROXIMITY_AUTH_WEBUI_PROXIMITY_AUTH_UI_DELEGATE_H_
6 #define COMPONENTS_PROXIMITY_AUTH_WEBUI_PROXIMITY_AUTH_UI_DELEGATE_H_
8 #include "base/memory/scoped_ptr.h"
9 #include "components/proximity_auth/cryptauth/proto/cryptauth_api.pb.h"
11 class PrefService;
13 namespace proximity_auth {
15 class CryptAuthClientFactory;
16 class SecureMessageDelegate;
18 // A delegate used by the chrome://proximity-auth WebUI, used to get
19 // implmentations with dependencies on chrome.
20 class ProximityAuthUIDelegate {
21 public:
22 virtual ~ProximityAuthUIDelegate() {}
24 // Returns the PrefService used by the profile.
25 virtual PrefService* GetPrefService() = 0;
27 // Returns the SecureMessageDelegate used by the system.
28 virtual scoped_ptr<SecureMessageDelegate> CreateSecureMessageDelegate() = 0;
30 // Constructs the CryptAuthClientFactory that can be used for API requests.
31 virtual scoped_ptr<CryptAuthClientFactory> CreateCryptAuthClientFactory() = 0;
33 // Constructs the DeviceClassifier message that is sent to CryptAuth for all
34 // API requests.
35 virtual cryptauth::DeviceClassifier GetDeviceClassifier() = 0;
38 } // namespace proximity_auth
40 #endif // COMPONENTS_PROXIMITY_AUTH_WEBUI_PROXIMITY_AUTH_UI_DELEGATE_H_