Changeset 39588 in webkit


Ignore:
Timestamp:
Jan 4, 2009 10:38:35 AM (15 years ago)
Author:
Simon Fraser
Message:

2009-01-04 Simon Fraser <Simon Fraser>

Reviewed by Darin Adler

https://bugs.webkit.org/show_bug.cgi?id=23090

If an object gets a Layout hint, and the style change will result in
the creation of a RenderLayer, then we need to repaint the old position
of the object. This was done for transform, but we have to test opacity too.

Test: fast/repaint/create-layer-repaint.html

  • rendering/RenderObject.cpp: (WebCore::RenderObject::styleWillChange):
Location:
trunk
Files:
4 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r39581 r39588  
     12009-01-04  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Reviewed by Darin Adler
     4
     5        https://bugs.webkit.org/show_bug.cgi?id=23090
     6       
     7        Repaint test for repainting when an element gets smaller,
     8        and gains a RenderLayer at the same time.
     9       
     10        * fast/repaint/create-layer-repaint.html: Added.
     11        * platform/mac/fast/repaint/create-layer-repaint-expected.checksum: Added.
     12        * platform/mac/fast/repaint/create-layer-repaint-expected.png: Added.
     13        * platform/mac/fast/repaint/create-layer-repaint-expected.txt: Added.
     14
    1152009-01-02  Adam Treat  <treat@kde.org>
    216
  • trunk/WebCore/ChangeLog

    r39587 r39588  
     12009-01-04  Simon Fraser  <simon.fraser@apple.com>
     2
     3        Reviewed by Darin Adler
     4
     5        https://bugs.webkit.org/show_bug.cgi?id=23090
     6       
     7        If an object gets a Layout hint, and the style change will result in
     8        the creation of a RenderLayer, then we need to repaint the old position
     9        of the object. This was done for transform, but we have to test opacity too.
     10
     11        Test: fast/repaint/create-layer-repaint.html
     12
     13        * rendering/RenderObject.cpp:
     14        (WebCore::RenderObject::styleWillChange):
     15
    1162009-01-04  Darin Adler  <darin@apple.com>
    217
  • trunk/WebCore/rendering/RenderObject.cpp

    r39555 r39588  
    23042304                    m_style->transform() != newStyle->transform())
    23052305                layer()->repaintIncludingDescendants();
    2306             } else if (m_style->transform() != newStyle->transform()) {
    2307                 // If we don't have a layer yet, but we are going to get one because of a transform change, then
    2308                 // we need to repaint the old position of the object
     2306            } else if (newStyle->hasTransform() || newStyle->opacity() < 1) {
     2307                // If we don't have a layer yet, but we are going to get one because of transform or opacity,
     2308                //  then we need to repaint the old position of the object.
    23092309                repaint();
    23102310            }
Note: See TracChangeset for help on using the changeset viewer.