• ojan@chromium.org's avatar
    z-index should work without position on flexitems · a4039c89
    ojan@chromium.org authored
    Reviewed by Tony Chang.
    Require a layer on any RenderBox that has a non-auto z-index.
    Statically positioned, non-flex-item's have their z-index coerced to auto,
    so it's safe to check z-index unconditionally.
    Test: css3/flexbox/z-index.html
    * css/StyleResolver.cpp:
    -Don't coerce z-index to auto on statically positioned flex-items.
    -Use the parentStyle to determine if the parent is a flexbox instead of
    looking at the element's parentNode's renderer.
    * rendering/RenderBox.h:
    -Add having a non-auto z-index to the list of things that require a layer.
    * css3/flexbox/z-index-expected.html: Added.
    * css3/flexbox/z-index.html: Added.
    Use a ref-test since we want to be sure that the elements get painted in the right order.
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@125693 268f45cc-cd09-0410-ab3c-d52691b4dbfc
z-index.html 1.22 KB