Bug 132830 - DataDetector UI doesn't update with resize
Summary: DataDetector UI doesn't update with resize
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Brent Fulgham
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2014-05-12 11:53 PDT by Brent Fulgham
Modified: 2014-05-12 17:30 PDT (History)
0 users

See Also:


Attachments
Patch (4.91 KB, patch)
2014-05-12 11:59 PDT, Brent Fulgham
no flags Details | Formatted Diff | Diff
Patch (5.96 KB, patch)
2014-05-12 16:49 PDT, Brent Fulgham
simon.fraser: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Brent Fulgham 2014-05-12 11:53:50 PDT
The DataDetector UI decorations on the page do not move with the elements they represent as the page is resized.
Comment 1 Brent Fulgham 2014-05-12 11:55:59 PDT
<rdar://problem/16871179>
Comment 2 Brent Fulgham 2014-05-12 11:59:40 PDT
Created attachment 231311 [details]
Patch
Comment 3 Simon Fraser (smfr) 2014-05-12 12:01:18 PDT
Comment on attachment 231311 [details]
Patch

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

> Source/WebCore/page/FrameView.cpp:559
> +#if ENABLE(TELEPHONE_NUMBER_DETECTION) && !PLATFORM(IOS)
> +    if (m_frame)
> +        m_frame->editor().contentsResized();
> +#endif

You should wire this up to any layout, not just resizing.
Comment 4 Brent Fulgham 2014-05-12 16:49:49 PDT
Created attachment 231340 [details]
Patch
Comment 5 Simon Fraser (smfr) 2014-05-12 16:52:01 PDT
Comment on attachment 231340 [details]
Patch

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

> Source/WebCore/page/FrameView.cpp:2753
>      frame().selection().setCaretRectNeedsUpdate();
>      frame().selection().updateAndRevealSelection();
> +    frame().selection().updateDataDetectorsForSelection();

Maybe selection can have a layoutDidChange() function that does these three things?
Comment 6 Brent Fulgham 2014-05-12 17:30:00 PDT
Committed r168664: <http://trac.webkit.org/changeset/168664>