The documentation describes setSelectedDOMRange:affinity: with the following, WebKit/ObjC_classic/Classes/WebView.html: Selects the range specified by range in the receiver. If range is nil, clears the selection. However, the method is implemented with this line, [[[range startContainer] _bridge] setSelectedDOMRange:range affinity:selectionAffinity closeTyping:YES]; Where 'range' is the given parameter. If 'range' is nil, this line is a no-op.
See WebKit/WebView.subproj/WebView.m revision 1.287 line 2770 for the actual implementation. Either the documentation needs to be updated, or the method needs to be fixed to adhere to the documentation.
Created attachment 2638 [details] Call deselectText if range is nil
Comment on attachment 2638 [details] Call deselectText if range is nil r=me
Reportere, could you verify this one? If it's fixed for you, mark it as verified please.