Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / chrome / browser / ui / cocoa / passwords / account_avatar_fetcher_manager.h
blob92f3321dd004af6b57fa00c188f0f113bc5a540f
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 CHROME_BROWSER_UI_COCOA_PASSWORDS_ACCOUNT_AVATAR_FETCHER_MANAGER_H_
6 #define CHROME_BROWSER_UI_COCOA_PASSWORDS_ACCOUNT_AVATAR_FETCHER_MANAGER_H_
8 #include <Cocoa/Cocoa.h>
10 #include "base/memory/ref_counted.h"
11 #include "base/memory/scoped_vector.h"
12 #include "net/url_request/url_request_context_getter.h"
14 class AccountAvatarFetcherBridge;
15 @class CredentialItemView;
16 class GURL;
18 // Handles retrieving avatar images for credential items.
19 @interface AccountAvatarFetcherManager : NSObject {
20 ScopedVector<AccountAvatarFetcherBridge> bridges_;
21 scoped_refptr<net::URLRequestContextGetter> requestContext_;
24 // Initializes a manager with the specified request context.
25 - (id)initWithRequestContext:
26 (scoped_refptr<net::URLRequestContextGetter>)requestContext;
28 // Retrieves the image located at |avatarURL| and updates |view| if successful.
29 - (void)fetchAvatar:(const GURL&)avatarURL forView:(CredentialItemView*)view;
31 @end
33 #endif // CHROME_BROWSER_UI_COCOA_PASSWORDS_ACCOUNT_AVATAR_FETCHER_MANAGER_H_