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

Side by Side Diff: ios/web/web_state/web_state_impl.h

Issue 2693043003: Revert of Use IOSImageDataFetcherWrapper for favicon (Closed)
Patch Set: Created 3 years, 10 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
« no previous file with comments | « ios/web/web_state/DEPS ('k') | ios/web/web_state/web_state_impl.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 IOS_WEB_WEB_STATE_WEB_STATE_IMPL_H_ 5 #ifndef IOS_WEB_WEB_STATE_WEB_STATE_IMPL_H_
6 #define IOS_WEB_WEB_STATE_WEB_STATE_IMPL_H_ 6 #define IOS_WEB_WEB_STATE_WEB_STATE_IMPL_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 25 matching lines...) Expand all
36 } 36 }
37 37
38 namespace web { 38 namespace web {
39 39
40 class BrowserState; 40 class BrowserState;
41 struct ContextMenuParams; 41 struct ContextMenuParams;
42 struct Credential; 42 struct Credential;
43 struct FaviconURL; 43 struct FaviconURL;
44 struct LoadCommittedDetails; 44 struct LoadCommittedDetails;
45 class NavigationManager; 45 class NavigationManager;
46 class ImageDataFetcher;
46 class WebInterstitialImpl; 47 class WebInterstitialImpl;
47 class WebStateFacadeDelegate; 48 class WebStateFacadeDelegate;
48 class WebStatePolicyDecider; 49 class WebStatePolicyDecider;
49 class WebUIIOS; 50 class WebUIIOS;
50 51
51 // Implementation of WebState. 52 // Implementation of WebState.
52 // Generally mirrors //content's WebContents implementation. 53 // Generally mirrors //content's WebContents implementation.
53 // General notes on expected WebStateImpl ownership patterns: 54 // General notes on expected WebStateImpl ownership patterns:
54 // - Outside of tests, WebStateImpls are created 55 // - Outside of tests, WebStateImpls are created
55 // (a) By @Tab, when creating a new Tab. 56 // (a) By @Tab, when creating a new Tab.
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
219 GURL GetCurrentURL(URLVerificationTrustLevel* trust_level) const override; 220 GURL GetCurrentURL(URLVerificationTrustLevel* trust_level) const override;
220 void ShowTransientContentView(CRWContentView* content_view) override; 221 void ShowTransientContentView(CRWContentView* content_view) override;
221 bool IsShowingWebInterstitial() const override; 222 bool IsShowingWebInterstitial() const override;
222 WebInterstitial* GetWebInterstitial() const override; 223 WebInterstitial* GetWebInterstitial() const override;
223 void OnPasswordInputShownOnHttp() override; 224 void OnPasswordInputShownOnHttp() override;
224 void OnCreditCardInputShownOnHttp() override; 225 void OnCreditCardInputShownOnHttp() override;
225 void AddScriptCommandCallback(const ScriptCommandCallback& callback, 226 void AddScriptCommandCallback(const ScriptCommandCallback& callback,
226 const std::string& command_prefix) override; 227 const std::string& command_prefix) override;
227 void RemoveScriptCommandCallback(const std::string& command_prefix) override; 228 void RemoveScriptCommandCallback(const std::string& command_prefix) override;
228 id<CRWWebViewProxy> GetWebViewProxy() const override; 229 id<CRWWebViewProxy> GetWebViewProxy() const override;
230 int DownloadImage(const GURL& url,
231 bool is_favicon,
232 uint32_t max_bitmap_size,
233 bool bypass_cache,
234 const ImageDownloadCallback& callback) override;
229 service_manager::InterfaceRegistry* GetMojoInterfaceRegistry() override; 235 service_manager::InterfaceRegistry* GetMojoInterfaceRegistry() override;
230 base::WeakPtr<WebState> AsWeakPtr() override; 236 base::WeakPtr<WebState> AsWeakPtr() override;
231 237
232 // Adds |interstitial|'s view to the web controller's content view. 238 // Adds |interstitial|'s view to the web controller's content view.
233 void ShowWebInterstitial(WebInterstitialImpl* interstitial); 239 void ShowWebInterstitial(WebInterstitialImpl* interstitial);
234 240
235 // Called to dismiss the currently-displayed transient content view. 241 // Called to dismiss the currently-displayed transient content view.
236 void ClearTransientContentView(); 242 void ClearTransientContentView();
237 243
238 // Notifies the delegate that the load progress was updated. 244 // Notifies the delegate that the load progress was updated.
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
342 std::map<std::string, ScriptCommandCallback> script_command_callbacks_; 348 std::map<std::string, ScriptCommandCallback> script_command_callbacks_;
343 349
344 // Member variables should appear before the WeakPtrFactory<> to ensure that 350 // Member variables should appear before the WeakPtrFactory<> to ensure that
345 // any WeakPtrs to WebStateImpl are invalidated before its member variable's 351 // any WeakPtrs to WebStateImpl are invalidated before its member variable's
346 // destructors are executed, rendering them invalid. 352 // destructors are executed, rendering them invalid.
347 base::WeakPtrFactory<WebState> weak_factory_; 353 base::WeakPtrFactory<WebState> weak_factory_;
348 354
349 // Mojo interface registry for this WebState. 355 // Mojo interface registry for this WebState.
350 std::unique_ptr<service_manager::InterfaceRegistry> mojo_interface_registry_; 356 std::unique_ptr<service_manager::InterfaceRegistry> mojo_interface_registry_;
351 357
358 // Image Fetcher used to images.
359 std::unique_ptr<ImageDataFetcher> image_fetcher_;
360
352 DISALLOW_COPY_AND_ASSIGN(WebStateImpl); 361 DISALLOW_COPY_AND_ASSIGN(WebStateImpl);
353 }; 362 };
354 363
355 } // namespace web 364 } // namespace web
356 365
357 #endif // IOS_WEB_WEB_STATE_WEB_STATE_IMPL_H_ 366 #endif // IOS_WEB_WEB_STATE_WEB_STATE_IMPL_H_
OLDNEW
« no previous file with comments | « ios/web/web_state/DEPS ('k') | ios/web/web_state/web_state_impl.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698