Bug 153390 - Web Inspector: Reduce unnecessary forced layouts in TimelineRuler
Summary: Web Inspector: Reduce unnecessary forced layouts in TimelineRuler
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (show other bugs)
Version: WebKit Nightly Build
Hardware: All All
: P2 Normal
Assignee: Joseph Pecoraro
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2016-01-22 21:18 PST by Joseph Pecoraro
Modified: 2016-01-22 22:47 PST (History)
8 users (show)

See Also:


Attachments
[PATCH] Proposed Fix (7.94 KB, patch)
2016-01-22 21:23 PST, Joseph Pecoraro
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Joseph Pecoraro 2016-01-22 21:18:18 PST
* SUMMARY
Reduce unnecessary forced layouts in TimelineRuler

TimelineRuler is potentially forcing a synchronous layout (element.clientWidth) every time it does a layout. This is unnecessary expensive, and in some cases this causes the entire inspector process to hang while it draws/layout/draw/layout repeatedly.

The only reason the TimelineRuler would need its clientWidth is to calculate the width of the element. So this value can be updated only when the ruler is resized.
Comment 1 Radar WebKit Bug Importer 2016-01-22 21:18:32 PST
<rdar://problem/24312241>
Comment 2 Joseph Pecoraro 2016-01-22 21:23:31 PST
Created attachment 269639 [details]
[PATCH] Proposed Fix
Comment 3 WebKit Commit Bot 2016-01-22 22:47:08 PST
Comment on attachment 269639 [details]
[PATCH] Proposed Fix

Clearing flags on attachment: 269639

Committed r195504: <http://trac.webkit.org/changeset/195504>
Comment 4 WebKit Commit Bot 2016-01-22 22:47:12 PST
All reviewed patches have been landed.  Closing bug.