<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[166801] trunk/Source/WebKit2</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/166801">166801</a></dd>
<dt>Author</dt> <dd>andersca@apple.com</dd>
<dt>Date</dt> <dd>2014-04-04 15:03:22 -0700 (Fri, 04 Apr 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>More documentation
https://bugs.webkit.org/show_bug.cgi?id=131238

Reviewed by Sam Weinig.

* UIProcess/API/Cocoa/WKNavigation.h:
* UIProcess/API/Cocoa/WKNavigationDelegate.h:
* UIProcess/API/Cocoa/WKPreferences.h:
* UIProcess/API/Cocoa/WKWebViewConfiguration.h:</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebKit2ChangeLog">trunk/Source/WebKit2/ChangeLog</a></li>
<li><a href="#trunkSourceWebKit2UIProcessAPICocoaWKNavigationh">trunk/Source/WebKit2/UIProcess/API/Cocoa/WKNavigation.h</a></li>
<li><a href="#trunkSourceWebKit2UIProcessAPICocoaWKNavigationDelegateh">trunk/Source/WebKit2/UIProcess/API/Cocoa/WKNavigationDelegate.h</a></li>
<li><a href="#trunkSourceWebKit2UIProcessAPICocoaWKPreferencesh">trunk/Source/WebKit2/UIProcess/API/Cocoa/WKPreferences.h</a></li>
<li><a href="#trunkSourceWebKit2UIProcessAPICocoaWKWebViewConfigurationh">trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewConfiguration.h</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebKit2ChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/ChangeLog (166800 => 166801)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/ChangeLog        2014-04-04 20:34:23 UTC (rev 166800)
+++ trunk/Source/WebKit2/ChangeLog        2014-04-04 22:03:22 UTC (rev 166801)
</span><span class="lines">@@ -1,3 +1,15 @@
</span><ins>+2014-04-04  Anders Carlsson  &lt;andersca@apple.com&gt;
+
+        More documentation
+        https://bugs.webkit.org/show_bug.cgi?id=131238
+
+        Reviewed by Sam Weinig.
+
+        * UIProcess/API/Cocoa/WKNavigation.h:
+        * UIProcess/API/Cocoa/WKNavigationDelegate.h:
+        * UIProcess/API/Cocoa/WKPreferences.h:
+        * UIProcess/API/Cocoa/WKWebViewConfiguration.h:
+
</ins><span class="cx"> 2014-04-04  Raphael Kubo da Costa  &lt;raphael.kubo.da.costa@intel.com&gt;
</span><span class="cx"> 
</span><span class="cx">         [GTK][CMake] Use a stricter check for the HAVE_GTK_UNIX_PRINTING define
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessAPICocoaWKNavigationh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKNavigation.h (166800 => 166801)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKNavigation.h        2014-04-04 20:34:23 UTC (rev 166800)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKNavigation.h        2014-04-04 22:03:22 UTC (rev 166801)
</span><span class="lines">@@ -28,12 +28,26 @@
</span><span class="cx"> 
</span><span class="cx"> #if WK_API_ENABLED
</span><span class="cx"> 
</span><ins>+/*! WKNavigation objects are returned from  the @link WKWebView @/link load methods and are passed to the 
+ @link WKNavigationDelegate @/link methods, and can be used to track page loads from start to finish.
+ */
</ins><span class="cx"> WK_API_CLASS
</span><span class="cx"> @interface WKNavigation : NSObject
</span><span class="cx"> 
</span><ins>+/*! @abstract The initial NSURLRequest used to perform the navigation.
+ */
</ins><span class="cx"> @property (nonatomic, readonly) NSURLRequest *initialRequest;
</span><ins>+
+/*! @abstract The current request of the navigation. This request may be different from the request returned by initialRequest if server side redirects have happened.
+ */
</ins><span class="cx"> @property (nonatomic, readonly) NSURLRequest *request;
</span><ins>+
+/* @abstract The NSURLResponse for the navigation or nil if no response has been received yet.
+ */
</ins><span class="cx"> @property (nonatomic, readonly) NSURLResponse *response;
</span><ins>+
+/* @abstract The page load error if the page failed to load, nil otherwise.
+ */
</ins><span class="cx"> @property (nonatomic, readonly) NSError *error;
</span><span class="cx"> 
</span><span class="cx"> @end
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessAPICocoaWKNavigationDelegateh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKNavigationDelegate.h (166800 => 166801)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKNavigationDelegate.h        2014-04-04 20:34:23 UTC (rev 166800)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKNavigationDelegate.h        2014-04-04 22:03:22 UTC (rev 166801)
</span><span class="lines">@@ -33,6 +33,11 @@
</span><span class="cx"> @class WKNavigationResponse;
</span><span class="cx"> @class WKWebView;
</span><span class="cx"> 
</span><ins>+/*! @enum WKNavigationActionPolicy
+ @abstract the policy to pass back to the decision handler in webView:decidePolicyForNavigationAction:decisionHandler:.
+ @constant WKNavigationActionPolicyCancel   Cancel the navigation.
+ @constant WKNavigationActionPolicyAllow    Allow the navigation to continue.
+ */
</ins><span class="cx"> typedef NS_ENUM(NSInteger, WKNavigationActionPolicy) {
</span><span class="cx">     WKNavigationActionPolicyCancel,
</span><span class="cx">     WKNavigationActionPolicyAllow,
</span><span class="lines">@@ -45,6 +50,11 @@
</span><span class="cx"> // FIXME: Remove this.
</span><span class="cx"> typedef WKNavigationActionPolicy WKNavigationPolicyDecision;
</span><span class="cx"> 
</span><ins>+/*! @enum WKNavigationResponsePolicy
+ @abstract the policy to pass back to the decision handler in webView:decidePolicyForNavigationResponse:decisionHandler:.
+ @constant WKNavigationResponsePolicyCancel   Cancel the navigation.
+ @constant WKNavigationResponsePolicyAllow    Allow the navigation to continue.
+ */
</ins><span class="cx"> typedef NS_ENUM(NSInteger, WKNavigationResponsePolicy) {
</span><span class="cx">     WKNavigationResponsePolicyCancel,
</span><span class="cx">     WKNavigationResponsePolicyAllow,
</span><span class="lines">@@ -57,19 +67,63 @@
</span><span class="cx"> // FIXME: Remove this.
</span><span class="cx"> typedef WKNavigationResponsePolicy WKNavigationResponsePolicyDecision;
</span><span class="cx"> 
</span><ins>+/*! A class that conforms to WKNavigationDelegate can provide methods for deciding load policy for main frame and subframe loads
+ and track load progress for main frame loads.
+ */
</ins><span class="cx"> @protocol WKNavigationDelegate &lt;NSObject&gt;
</span><span class="cx"> 
</span><span class="cx"> @optional
</span><span class="cx"> 
</span><ins>+/*! @abstract Decides whether a navigation should be allowed or not.
+ @param webView The WKWebView invoking the delegate method.
+ @param navigationAction A description of the action that triggered the navigation request.
+ @param decisionHandler The decision handler that should be called to allow or cancel the load.
+ */
</ins><span class="cx"> - (void)webView:(WKWebView *)webView decidePolicyForNavigationAction:(WKNavigationAction *)navigationAction decisionHandler:(void (^)(WKNavigationActionPolicy))decisionHandler;
</span><ins>+
+/*! @abstract Decides whether a navigation should be allowed or cancelled once its response is known.
+ @param webView The WKWebView invoking the delegate method.
+ @param navigationResponse A description of the navigation response.
+ @param decisionHandler The decision handler that should be call to allow or cancel the load.
+ */
</ins><span class="cx"> - (void)webView:(WKWebView *)webView decidePolicyForNavigationResponse:(WKNavigationResponse *)navigationResponse decisionHandler:(void (^)(WKNavigationResponsePolicy))decisionHandler;
</span><span class="cx"> 
</span><ins>+/*! @abstract Invoked when a main frame page load starts.
+ @param webView The WKWebView invoking the delegate method.
+ @param navigation The navigation.
+ */
</ins><span class="cx"> - (void)webView:(WKWebView *)webView didStartProvisionalNavigation:(WKNavigation *)navigation;
</span><ins>+
+/*! @abstract Invoked when a server redirect is received for the main frame.
+ @param webView The WKWebView invoking the delegate method.
+ @param navigation The navigation.
+ */
</ins><span class="cx"> - (void)webView:(WKWebView *)webView didReceiveServerRedirectForProvisionalNavigation:(WKNavigation *)navigation;
</span><span class="cx"> 
</span><ins>+/*! @abstract Invoked if an error occurs when starting to load data for the main frame.
+ @param webView The WKWebView invoking the delegate method.
+ @param navigation The navigation.
+ @param error Specifies the type of error that occurred during the load.
+ */
</ins><span class="cx"> - (void)webView:(WKWebView *)webView didFailProvisionalNavigation:(WKNavigation *)navigation withError:(NSError *)error;
</span><ins>+
+/*! @abstract Invoked when content starts arriving for the main frame.
+ @param webView The WKWebView invoking the delegate method.
+ @param navigation The navigation.
+ */
</ins><span class="cx"> - (void)webView:(WKWebView *)webView didCommitNavigation:(WKNavigation *)navigation;
</span><ins>+
+/*! @abstract Invoked when a main frame load completes.
+ @param webView The WKWebView invoking the delegate method.
+ @param navigation The navigation.
+ */
</ins><span class="cx"> - (void)webView:(WKWebView *)webView didFinishNavigation:(WKNavigation *)navigation;
</span><ins>+
+/*! @abstract Invoked if an error occurs loading a committed main frame page load.
+ @param webView The WKWebView invoking the delegate method.
+ @param navigation The navigation.
+ @param error Specifies the type of error that occurred during the load.
+ */
</ins><span class="cx"> - (void)webView:(WKWebView *)webView didFailNavigation:(WKNavigation *)navigation withError:(NSError *)error;
</span><span class="cx"> 
</span><span class="cx"> @end
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessAPICocoaWKPreferencesh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKPreferences.h (166800 => 166801)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKPreferences.h        2014-04-04 20:34:23 UTC (rev 166800)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKPreferences.h        2014-04-04 22:03:22 UTC (rev 166801)
</span><span class="lines">@@ -32,27 +32,61 @@
</span><span class="cx"> 
</span><span class="cx"> #if WK_API_ENABLED
</span><span class="cx"> 
</span><ins>+/*! WKPreferences encapsulates the preferences you can change for one or more WKWebViews. 
+ A @link WKWebView @/link can specify which WKPreferences object it uses through its @link WKWebViewConfiguration @/link.
+ */
</ins><span class="cx"> WK_API_CLASS
</span><span class="cx"> @interface WKPreferences : NSObject
</span><span class="cx"> 
</span><ins>+/*! @abstract Returns an initialized WKPreferences object.
+ @param userDefaultsKeyPrefix The user defaults key prefix.
+ @discussion If the userDefaultsKeyPrefix argument is non-nil, it is is prepended to the keys used to store preferences 
+ in the user defaults database. If the argument is nil, the preferences object won't save anything to the user defaults database.
+ */
</ins><span class="cx"> - (instancetype)initWithUserDefaultsKeyPrefix:(NSString *)userDefaultsKeyPrefix WK_DESIGNATED_INITIALIZER;
</span><span class="cx"> 
</span><ins>+/*! @abstract The user defaults key prefix
+ */
</ins><span class="cx"> @property (nonatomic, readonly) NSString *userDefaultsKeyPrefix;
</span><span class="cx"> 
</span><ins>+/*! @abstract The minimum font size in points.
+ */
</ins><span class="cx"> @property (nonatomic) CGFloat minimumFontSize;
</span><span class="cx"> 
</span><ins>+/*! @abstract Whether JavaScript is enabled.
+ */
</ins><span class="cx"> @property (nonatomic, getter=isJavaScriptEnabled) BOOL javaScriptEnabled;
</span><ins>+
+/*! @abstract Whether JavaScript can open windows without user interaction.
+ */
</ins><span class="cx"> @property (nonatomic) BOOL javaScriptCanOpenWindowsAutomatically;
</span><ins>+
+/*! @abstract Whether the WKWebView suppresses content rendering until it is fully loaded into memory.
+ */
</ins><span class="cx"> @property (nonatomic) BOOL suppressesIncrementalRendering;
</span><span class="cx"> 
</span><span class="cx"> #if TARGET_OS_IPHONE
</span><ins>+/*! @abstract Whether HTML5 videos play inline or use the native full-screen controller.
+ */
</ins><span class="cx"> @property (nonatomic) BOOL allowsInlineMediaPlayback;
</span><ins>+
+/*! @abstract Whether HTML5 videos can play automatically or require the user to start playing them.
+ */
</ins><span class="cx"> @property (nonatomic) BOOL mediaPlaybackRequiresUserAction;
</span><ins>+
+/*! @abstract Whether AirPlay is allowed.
+ */
</ins><span class="cx"> @property (nonatomic) BOOL mediaPlaybackAllowsAirPlay;
</span><ins>+
</ins><span class="cx"> #endif
</span><span class="cx"> 
</span><span class="cx"> #if !TARGET_OS_IPHONE
</span><ins>+/*! @abstract Whether Java is enabled.
+ */
</ins><span class="cx"> @property (nonatomic, getter=isJavaEnabled) BOOL javaEnabled;
</span><ins>+
+/*! abstract Whether plug-ins are enabled.
+ */
</ins><span class="cx"> @property (nonatomic, getter=arePlugInsEnabled) BOOL plugInsEnabled;
</span><span class="cx"> #endif
</span><span class="cx"> 
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessAPICocoaWKWebViewConfigurationh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewConfiguration.h (166800 => 166801)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewConfiguration.h        2014-04-04 20:34:23 UTC (rev 166800)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewConfiguration.h        2014-04-04 22:03:22 UTC (rev 166801)
</span><span class="lines">@@ -54,7 +54,6 @@
</span><span class="cx"> */
</span><span class="cx"> @property (nonatomic, strong) WKPreferences *preferences;
</span><span class="cx"> 
</span><del>-
</del><span class="cx"> /*! @abstract The user content controller that should be used by web views created with this configuration.
</span><span class="cx">  @discussion When this property is set to nil, a unique user content controller object will be created for each
</span><span class="cx">  @link WKWebView @/link initialized with the configuration.
</span></span></pre>
</div>
</div>

</body>
</html>