1 // Copyright 2014 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 IOS_WEB_PUBLIC_WEB_VIEW_CREATION_UTIL_H_
6 #define IOS_WEB_PUBLIC_WEB_VIEW_CREATION_UTIL_H_
8 #import <CoreGraphics/CoreGraphics.h>
15 // Returns true if WKWebView is supported on current OS/platform/arch.
16 bool IsWKWebViewSupported();
18 // Returns a new WKWebView for displaying regular web content.
19 // WKWebViewConfiguration object for resulting web view will be obtained from
20 // the given |browser_state| which must not be null.
21 // The BrowsingDataPartition must be synchronized before this method is called.
22 // Note: Callers are responsible for releasing the returned WKWebView.
23 WKWebView
* CreateWKWebView(CGRect frame
, BrowserState
* browser_state
);
27 #endif // IOS_WEB_PUBLIC_WEB_VIEW_CREATION_UTIL_H_