Add Cocoa delegate for logging diagnostic messages. Right now, there is only a WK2 C API client.
Created attachment 244630 [details] Patch
Created attachment 244634 [details] Patch
Unless we really need this code to run in the WebProcess, I would rather we IPC this over to the UIProcess and do it there.
Created attachment 244751 [details] Patch
Created attachment 244777 [details] Patch
Sam, could you please take another look? I updated the patch now that diagnostic messages go through the UIProcess.
Comment on attachment 244777 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=244777&action=review > Source/WebKit2/UIProcess/API/Cocoa/_WKDiagnosticLoggingDelegate.h:38 > +- (void)_webView:(WKWebView *)webView logDiagnosticMessage:(NSString *)message inDescription:(NSString *)description; > +- (void)_webView:(WKWebView *)webView logDiagnosticMessageWithResult:(NSString *)message inDescription:(NSString *)description inResult:(WKDiagnosticLoggingResultType)result; > +- (void)_webView:(WKWebView *)webView logDiagnosticMessageWithValue:(NSString *)message inDescription:(NSString *)description inValue:(NSString *) value; I think these read a little weird, especially the "inDescription" and "inValue" parts.
Created attachment 244796 [details] Patch
(In reply to comment #7) > Comment on attachment 244777 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=244777&action=review > > > Source/WebKit2/UIProcess/API/Cocoa/_WKDiagnosticLoggingDelegate.h:38 > > +- (void)_webView:(WKWebView *)webView logDiagnosticMessage:(NSString *)message inDescription:(NSString *)description; > > +- (void)_webView:(WKWebView *)webView logDiagnosticMessageWithResult:(NSString *)message inDescription:(NSString *)description inResult:(WKDiagnosticLoggingResultType)result; > > +- (void)_webView:(WKWebView *)webView logDiagnosticMessageWithValue:(NSString *)message inDescription:(NSString *)description inValue:(NSString *) value; > > I think these read a little weird, especially the "inDescription" and > "inValue" parts. Ok, I am really not familiar with ObjC and its conventions. I switched to description/value/result instead of inDescription/inValue/inResult. Let me know if you have other suggestions so that these read better.
Comment on attachment 244796 [details] Patch Clearing flags on attachment: 244796 Committed r178630: <http://trac.webkit.org/changeset/178630>
All reviewed patches have been landed. Closing bug.