Bug 212508

Summary: Avoid unnecessary sync IPC messages when togging the callout bar for selections
Product: WebKit Reporter: Megan Gardner <megan_gardner>
Component: New BugsAssignee: Megan Gardner <megan_gardner>
Status: RESOLVED FIXED    
Severity: Normal CC: thorton, webkit-bug-importer, wenson_hsieh
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch for landing none

Description Megan Gardner 2020-05-28 19:22:20 PDT
Avoid unnessecary sync IPC messages when togging the callout bar for selections.
Comment 1 Megan Gardner 2020-05-28 19:26:29 PDT
Created attachment 400537 [details]
Patch
Comment 2 Wenson Hsieh 2020-05-28 19:29:19 PDT
Comment on attachment 400537 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=400537&action=review

> Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm:2566
> +                if (!_page->editorState().selectionIsRange)
> +                    return NO;
> +                if ([self _pointIsInsideSelectionRect:point outBoundingRect:nil])
> +                    return YES;
> +                return NO;

Nit - I would just write this `return [self _pointIsInsideSelectionRect:point outBoundingRect:nil];`.
Comment 3 Wenson Hsieh 2020-05-28 19:30:53 PDT
Comment on attachment 400537 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=400537&action=review

> Source/WebKit/ChangeLog:3
> +        Avoid unnessecary sync IPC messages when togging the callout bar for selections.

Nit - unnecessary
Comment 4 Megan Gardner 2020-05-28 22:07:16 PDT
Created attachment 400547 [details]
Patch for landing
Comment 5 EWS 2020-05-28 22:41:06 PDT
Committed r262280: <https://trac.webkit.org/changeset/262280>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 400547 [details].
Comment 6 Radar WebKit Bug Importer 2020-05-28 22:42:14 PDT
<rdar://problem/63747401>