This has two desirable side effects. The first and more important is that it prevents a scrollbar item from sitting between scroll layer items and preventing them from merging into one and thus preventing the creation of an async scrollable layer. The second is that scrollbars should be on top of the content they are scrolling in general, and this will make that happen in more cases.
This guarantees that the animated geometry root for an item is always in the
same display list coordinate system as the frame.
--HG--
extra : rebase_source : 249fd847a2c08f8d0846d698cce9dd4681e38a98
This patch deprecates the UpdateSurface and PaintWithOpacity methods in the
CCL class. To do this, many other changes were made in the process.
BasicImplData::Paint was deprecated, and its mOperator was ported to Moz2D.
This caused changes in several *Layer subclasses.
GLScreenBuffer::Readback was deprecated.
I want to change the usages of the (now) deprecated functions, so that they
use the new Moz2D ones: CanvasClient::Update has been updated, but the big
one (BasicLayerManager::PaintSelfOrChildren) will have to be its own
project.
We incorrectly wrap abs pos items, but not wrapping them leads to too many sites failing to create scrollable layers that we can't do that. So instead just fix the clipping issue for now until a more robust solution can be developed.
The bounds of the scroll port match what will actually be drawn on the screen.
The bounds of the contained content (sized to the display port) are still accessible via mList.GetBounds, and similarly the visible rect of the contained content is mList.GetVisibleRect. The external bounds/visible rect are GetBounds and GetVisibleRect on the nsDisplayScrollLayer object itself.
We implement nsDisplayScrollInfoLayer::GetBounds solely so that it continues to return an empty rect because we expect active empty layers to have empty visible rects.
We no longer have to set our mVisibleRect in nsDisplayScrollLayer::ComputeVisibility because nsDisplayList::ComputeVisibilityForSublist now does it correctly for us (like other items).
We also have to teach ContainerState::ProcessDisplayItems to not set the visible region for scroll layers because it has the external visible region, not the larger internal display port sized visible region. We instead let BuildContainerLayer set the visible region of the layer.
APZC information is associated with layers, and having those layers suddenly
disappear because they became occluded, or their displayports are off-screen
has undesired effects.
This adds a new eCSSUnit_SharedList type for nsCSSValue, which is a
reference counted object that contains an nsCSSValueList. We need this
so that nsStyleDisplay::mSpecifiedTransform can hold a strong reference
to a specified transform list value. When 'transform' is specified
using a variable reference, the resulting nsCSSValue does not stick
around in the Declaration object, so we wouldn't be guaranteed that
it lives long enough for nsStyleDisplay to keep referencing it.
The scroll layer item has the clip induced by the scroll frame, but the scrolled items are only clipped to the (larger) display port so we can async scroll the display port area. But if we can't merge all the scroll layer items then we can't render the expanded display port content so we have to clip the scrolled items to the scroll frame by propagating the clip on the scroll layer item to its children.