TestRunner.display() needs to have the option to draw the web page without drawing a gray background for the track repaints. A new argument will be added to this function to provide this option but it is optional. If it is not passed, it will behave as it was before the change so the existing tests won't break. The purpose of this change is to make it easy to test the async image decoding. To draw an image asynchronously, TestRunner.display() will be called to start the image decoding. When the image frame is ready, we are going to call TestRunner.notifyDone() which will call TestRunner.display() a second time. This time, the image will be drawn without any further decoding.
Created attachment 308986 [details] Patch
<rdar://problem/31976651>
Maybe we should just rename display() to displayAndTrackRepaints()? There are 175 instances: compositing/clip-change.html: testRunner.display(); compositing/geometry/foreground-offset-change.html: testRunner.display(); compositing/geometry/limit-layer-bounds-transformed-overflow.html: testRunner.display(); compositing/iframes/become-composited-nested-iframes.html: testRunner.display(); compositing/iframes/become-overlapped-iframe.html: testRunner.display(); // Painting has to happen to detect overlap. compositing/iframes/connect-compositing-iframe-delayed.html: testRunner.display(); compositing/iframes/connect-compositing-iframe.html: testRunner.display(); compositing/iframes/connect-compositing-iframe2.html: testRunner.display(); compositing/iframes/connect-compositing-iframe3.html: testRunner.display(); compositing/iframes/enter-compositing-iframe.html: testRunner.display(); compositing/iframes/iframe-content-flipping.html: testRunner.display(); compositing/iframes/iframe-resize.html: testRunner.display(); compositing/iframes/iframe-resize.html: testRunner.display(); compositing/iframes/iframe-size-to-zero.html: testRunner.display(); compositing/iframes/iframe-size-to-zero.html: testRunner.display(); compositing/iframes/iframe-src-change.html: testRunner.display(); // Need to paint for overlap testing. compositing/iframes/invisible-nested-iframe-hide.html: testRunner.display(); compositing/iframes/invisible-nested-iframe-show.html: testRunner.display(); compositing/iframes/leave-compositing-iframe.html: testRunner.display(); compositing/iframes/overlapped-iframe-iframe.html: testRunner.display(); compositing/iframes/overlapped-iframe.html: testRunner.display(); compositing/iframes/overlapped-nested-iframes.html: testRunner.display(); compositing/iframes/repaint-after-losing-scrollbars.html: testRunner.display(); // Paint once with all overflow controls visible. compositing/iframes/resources/fixed-position-subframe.html: testRunner.display(); compositing/iframes/resources/fixed-position-transformed-subframe.html: testRunner.display(); compositing/iframes/resources/scrollgrandchild-inner.html: testRunner.display(); compositing/iframes/scrolling-iframe.html: testRunner.display(); compositing/overflow/content-gains-scrollbars.html: testRunner.display(); // Ensure compositor tree is up to date. compositing/overflow/content-gains-scrollbars.html: testRunner.display(); // Force compositor state to be updated before the container needs any overflow controls compositing/overflow/content-loses-scrollbars.html: testRunner.display(); // Ensure compositor tree is up to date. compositing/overflow/content-loses-scrollbars.html: testRunner.display(); // Force compositor state to be updated before the container needs any overflow controls compositing/overflow/do-not-paint-outline-into-composited-scrolling-contents.html: window.testRunner.display(); compositing/overflow/overflow-scrollbar-layers.html: testRunner.display(); // Ensure compositor tree is up to date. compositing/overflow/paint-neg-z-order-descendants-into-scrolling-contents-layer.html: window.testRunner.display(); compositing/overflow/paint-neg-z-order-descendants-into-scrolling-contents-layer.html: window.testRunner.display(); compositing/overflow/repaint-after-losing-scrollbars.html: testRunner.display(); // Paint once with all overflow controls visible. compositing/patterns/direct-pattern-compositing-add-text-expected.html: testRunner.display(); compositing/patterns/direct-pattern-compositing-add-text.html: testRunner.display(); compositing/patterns/direct-pattern-compositing-change-expected.html: window.testRunner.display(); compositing/patterns/direct-pattern-compositing-change.html: window.testRunner.display(); compositing/patterns/direct-pattern-compositing-load-expected.html: window.testRunner.display(); compositing/patterns/direct-pattern-compositing-load.html: window.testRunner.display(); compositing/plugins/invalidate_rect.html: testRunner.display(); compositing/repaint/iframes/composited-iframe-with-fixed-background-doc-repaint.html: testRunner.display(); // Flush pending compositing repaints. compositing/repaint/iframes/compositing-iframe-scroll-repaint.html: testRunner.display(); // Flush pending compositing repaints. compositing/repaint/iframes/compositing-iframe-with-fixed-background-doc-repaint.html: testRunner.display(); // Flush pending compositing repaints. compositing/repaint/newly-composited-on-scroll.html: testRunner.display(); compositing/repaint/newly-composited-on-scroll.html: testRunner.display(); compositing/repaint/newly-composited-repaint-rect.html: testRunner.display(); compositing/repaint/page-scale-repaint.html: testRunner.display(); compositing/repaint/requires-backing-repaint.html: testRunner.display(); compositing/repaint/transform-style-change.html: testRunner.display(); // Force one composite with preserve-3d compositing/rtl/rtl-overflow-invalidation.html: testRunner.display(); compositing/scroll-painted-composited-content.html: testRunner.display(); compositing/tiling/huge-layer-resize.html: testRunner.display(); compositing/video/video-with-invalid-source.html: testRunner.display(); compositing/video-page-visibility.html: testRunner.display(); compositing/video-page-visibility.html: testRunner.display(); compositing/webgl/webgl-repaint.html: testRunner.display(); compositing/webgl/webgl-repaint.html: testRunner.display(); compositing/webgl/webgl-repaint.html: testRunner.display(); css3/filters/multiple-filters-invalidation.html: testRunner.display(); css3/flexbox/repaint-column-reverse.html: testRunner.display(); css3/flexbox/repaint-during-resize-no-flex.html: testRunner.display(); css3/flexbox/repaint-rtl-column.html: testRunner.display(); css3/flexbox/repaint.html: testRunner.display(); displaylists/canvas-display-list.html: testRunner.display(); displaylists/resources/dump-target-display-list.js: testRunner.display(); displaylists/resources/dump-target-replay-list.js: testRunner.display(); fast/animation/request-animation-frame-detach-element.html: testRunner.display(); fast/animation/request-animation-frame-detach-element2.html: testRunner.display(); fast/animation/request-animation-frame-during-modal.html: ' testRunner.display();' + fast/animation/request-animation-frame-during-modal.html: testRunner.display(); fast/animation/request-animation-frame-iframe.html: testRunner.display(); fast/animation/request-animation-frame-iframe2.html: testRunner.display(); fast/animation/script-tests/request-animation-frame-cancel.js: testRunner.display(); fast/animation/script-tests/request-animation-frame-cancel2.js: testRunner.display(); fast/animation/script-tests/request-animation-frame-disabled.js: testRunner.display(); fast/animation/script-tests/request-animation-frame-prefix.js: testRunner.display(); fast/animation/script-tests/request-animation-frame-prefix.js: testRunner.display(); fast/animation/script-tests/request-animation-frame-time-unit.js: testRunner.display(); fast/animation/script-tests/request-animation-frame-time-unit.js: testRunner.display(); fast/animation/script-tests/request-animation-frame-timestamps-advance.js: testRunner.display(); fast/animation/script-tests/request-animation-frame-timestamps-advance.js: testRunner.display(); fast/animation/script-tests/request-animation-frame-timestamps.js: testRunner.display(); fast/animation/script-tests/request-animation-frame-within-callback.js: testRunner.display(); fast/animation/script-tests/request-animation-frame-within-callback.js: testRunner.display(); fast/animation/script-tests/request-animation-frame.js: testRunner.display(); fast/backgrounds/obscured-background-child-style-change-expected.html: testRunner.display(); fast/backgrounds/obscured-background-child-style-change.html: testRunner.display(); fast/backgrounds/solid-color-context-restore.html: testRunner.display(); fast/canvas/canvas-as-image-incremental-repaint.html: testRunner.display(); fast/canvas/canvas-incremental-repaint-2.html: testRunner.display(); fast/canvas/canvas-incremental-repaint.html: testRunner.display(); fast/canvas/canvas-resize-after-paint.html: testRunner.display(); // Force a composite at normal width/height to ensure we have a compositing layer for the canvas. fast/canvas/resources/repaint.js: testRunner.display(); fast/canvas/script-tests/canvas-imageSmoothingEnabled-repaint.js: testRunner.display(); fast/canvas/webgl/canvas-test.html: testRunner.display(); fast/canvas/webgl/webgl-layer-update.html: testRunner.display(); fast/canvas/webgl/webgl-layer-update.html: testRunner.display(); fast/css/pseudostyle-anonymous-text.html: testRunner.display(); fast/css/relative-positioned-block-crash.html: testRunner.display(); fast/dom/Window/post-message-crash.html: testRunner.display(); fast/dom/Window/web-timing-minimal-performance-now.html: window.testRunner.display(); fast/dynamic/containing-block-change.html: testRunner.display(); fast/dynamic/containing-block-change.html: testRunner.display(); fast/dynamic/layer-no-longer-paginated.html: testRunner.display(); fast/events/touch/gesture/pad-gesture-cancel.js: testRunner.display(); fast/events/touch/gesture/pad-gesture-fling.js: testRunner.display(); fast/events/touch/gesture/pad-gesture-fling.js: testRunner.display(); fast/events/touch/gesture/pad-gesture-fling.js: testRunner.display(); fast/forms/hidden-listbox.html: testRunner.display(); fast/forms/listbox-clip.html: testRunner.display(); fast/frames/inline-object-inside-frameset.html: testRunner.display(); fast/frames/transparent-scrollbar.html: testRunner.display(); fast/frames/transparent-scrollbar.html: testRunner.display(); fast/images/animated-background-image-crash.html: testRunner.display(); fast/layers/add-layer-with-nested-stacking.html: testRunner.display(); fast/layers/inline-dirty-z-order-lists.html: testRunner.display(); fast/layers/layer-content-visibility-change.html: testRunner.display(); fast/layers/nested-layers-1.html: testRunner.display(); fast/layers/nested-layers-2.html: testRunner.display(); fast/layers/nested-layers-3.html: testRunner.display(); fast/layers/nested-layers-4.html: testRunner.display(); fast/layers/remove-layer-with-nested-stacking.html: testRunner.display(); fast/overflow/hidden-scrollbar-resize.html: testRunner.display(); fast/reflections/inline-crash.html: testRunner.display(); fast/repaint/animation-after-layer-scroll.html: testRunner.display(); fast/repaint/animation-after-layer-scroll.html: testRunner.display(); fast/repaint/background-shorthand-with-gradient-and-height-changes.html: window.testRunner.display(); fast/repaint/fixed-child-move-after-scroll.html: testRunner.display(); fast/repaint/fixed-child-of-fixed-move-after-scroll.html: testRunner.display(); fast/repaint/fixed-child-of-transformed-move-after-scroll.html: testRunner.display(); fast/repaint/fixed-move-after-scroll.html: testRunner.display(); fast/repaint/no-animation-outside-viewport-subframe.html: testRunner.display(); fast/repaint/no-animation-outside-viewport-subframe.html: testRunner.display(); fast/repaint/no-animation-outside-viewport.html: testRunner.display(); fast/repaint/obscured-background-no-repaint.html: testRunner.display(); fast/repaint/overflow-hidden-in-overflow-hidden-scrolled.html: testRunner.display(); fast/repaint/renderer-destruction-by-invalidateSelection-crash.html: testRunner.display(); fast/repaint/repaint-during-scroll-with-zoom.html: testRunner.display(); fast/repaint/resources/fixed-move-after-keyboard-scroll-iframe.html: testRunner.display(); fast/repaint/resources/iframe-scroll-repaint-iframe.html: testRunner.display(); fast/repaint/resources/line-flow-with-floats.js: testRunner.display(); fast/repaint/resources/repaint.js: testRunner.display(); fast/repaint/table-overflow-hidden-in-overflow-hidden-scrolled.html: testRunner.display(); fast/replaced/width100percent-textarea.html: testRunner.display(); fast/scrolling/scrollbar-tickmarks-hittest.html: testRunner.display(); fast/table/border-collapsing/cached-69296.html: testRunner.display(); fast/table/border-collapsing/cached-cell-append.html: testRunner.display(); fast/table/border-collapsing/cached-cell-remove.html: testRunner.display(); fast/table/border-collapsing/cached-change-cell-border-color.html: testRunner.display(); fast/table/border-collapsing/cached-change-cell-border-width.html: testRunner.display(); fast/table/border-collapsing/cached-change-cell-sl-border-color.html: testRunner.display(); fast/table/border-collapsing/cached-change-col-border-color.html: testRunner.display(); fast/table/border-collapsing/cached-change-col-border-width.html: testRunner.display(); fast/table/border-collapsing/cached-change-colgroup-border-color.html: testRunner.display(); fast/table/border-collapsing/cached-change-colgroup-border-width.html: testRunner.display(); fast/table/border-collapsing/cached-change-row-border-color.html: testRunner.display(); fast/table/border-collapsing/cached-change-row-border-width.html: testRunner.display(); fast/table/border-collapsing/cached-change-table-border-color.html: testRunner.display(); fast/table/border-collapsing/cached-change-table-border-width.html: testRunner.display(); fast/table/border-collapsing/cached-change-tbody-border-color.html: testRunner.display(); fast/table/border-collapsing/cached-change-tbody-border-width.html: testRunner.display(); fast/table/empty-section-crash.html: testRunner.display(); fast/text/font-initial.html: testRunner.display(); fast/text/international/harfbuzz-runs-with-no-glyph.html: testRunner.display(); fast/text/text-shadow-extreme-value.html: testRunner.display(); http/tests/misc/slow-loading-image-in-pattern.html: testRunner.display(); media/audio-repaint.html: testRunner.display(); media/media-document-audio-repaint.html: testRunner.display(); scrollbars/scrollbar-percent-padding-crash.html: testRunner.display(); svg/custom/non-scaling-stroke-update.svg: testRunner.display(); svg/custom/stale-resource-data-crash.svg: testRunner.display();
I think the new way is bug 171641, right?
Created attachment 309116 [details] Patch
Created attachment 309117 [details] Patch
Comment on attachment 309117 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=309117&action=review > LayoutTests/fast/images/async-image-background-image-repeated.html:18 > + background-image: url(""); Maybe just remove the property? > LayoutTests/fast/images/async-image-background-image.html:9 > + background-image: url(""); Remove?
Created attachment 309122 [details] Patch
Comment on attachment 309122 [details] Patch Clearing flags on attachment: 309122 Committed r216225: <http://trac.webkit.org/changeset/216225>
All reviewed patches have been landed. Closing bug.