Bug 214962 - Web content gets stuck in an inactive state (no cursor updates or text insertion caret) when activating a tab with a thumbnail visible
Summary: Web content gets stuck in an inactive state (no cursor updates or text insert...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Tim Horton
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2020-07-30 02:54 PDT by Tim Horton
Modified: 2020-07-30 11:25 PDT (History)
6 users (show)

See Also:


Attachments
Patch (13.86 KB, patch)
2020-07-30 02:55 PDT, Tim Horton
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Horton 2020-07-30 02:54:47 PDT
Web content gets stuck in an inactive state (no cursor updates or text insertion caret) when activating a tab with a thumbnail visible
Comment 1 Tim Horton 2020-07-30 02:55:05 PDT
Created attachment 405560 [details]
Patch
Comment 2 Tim Horton 2020-07-30 02:55:07 PDT
<rdar://problem/65670984>
Comment 3 Wenson Hsieh 2020-07-30 08:02:48 PDT
Comment on attachment 405560 [details]
Patch

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

> Source/WebKit/UIProcess/Cocoa/WebViewImpl.mm:3859
> +        m_page->activityStateDidChange(WebCore::ActivityState::allFlags());

Nit - is there value in being more specific than `allFlags()` here?
Comment 4 Tim Horton 2020-07-30 11:20:19 PDT
(In reply to Wenson Hsieh from comment #3)
> Comment on attachment 405560 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=405560&action=review
> 
> > Source/WebKit/UIProcess/Cocoa/WebViewImpl.mm:3859
> > +        m_page->activityStateDidChange(WebCore::ActivityState::allFlags());
> 
> Nit - is there value in being more specific than `allFlags()` here?

I don't think so. It's a minor perf hit, but

1) use of WKThumbnailView's window trickles indirectly into *most* of the flags, and
2) I don't want people to have to keep track of #1 in the future when adding new flags.
3) You're already flinging views around, so the perf hit of asking the view and window a few questions is almost certainly negligible.
Comment 5 Tim Horton 2020-07-30 11:20:35 PDT
(We do diffing before doing anything more expensive)
Comment 6 EWS 2020-07-30 11:25:52 PDT
Committed r265091: <https://trac.webkit.org/changeset/265091>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 405560 [details].