[Cocoa] WKRemoteObjectCoder doesn’t handle NSRange
https://bugs.webkit.org/show_bug.cgi?id=160589
Reviewed by Tim Horton.
Source/WebKit2:
* Shared/API/Cocoa/WKRemoteObjectCoder.mm:
(encodeInvocationArguments): Encode NSRange by wrapping in an NSValue.
(decodeInvocationArguments): Decode wrapped NSRange.
Tools:
* TestWebKitAPI/Tests/WebKit2Cocoa/RemoteObjectRegistry.h:
(remoteObjectInterface): Fixed a mistake in the set of allowed classes in one of the reply
blocks, which wasn’t caught because the test wasn’t run correctly.
* TestWebKitAPI/Tests/WebKit2Cocoa/RemoteObjectRegistry.mm:
(TEST): Fixed the -selectionAndClickInformationForClickAtPoint:completionHandler: test, and
added a test that sends over an NSRange.
* TestWebKitAPI/Tests/WebKit2Cocoa/RemoteObjectRegistryPlugIn.mm:
(-[RemoteObjectRegistryPlugIn takeRange:completionHandler:]): Added. Calls the completion
handler with the range‘s location and length.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@204188
268f45cc-cd09-0410-ab3c-
d52691b4dbfc