Commit Graph

920 Commits

Author SHA1 Message Date
Seth Fowler
69bd34af46 Bug 1163878 (Part 2) - Use IsImageContainerAvailable() when making layerization decisions and only call GetImageContainer() if we layerize. r=tn 2015-05-13 00:23:46 -07:00
Ehsan Akhgari
8e90a84114 Bug 1163397 - Convert PaintedLayerData::mLog to an nsCString in order to make it possible to safely store PaintedLayerData inside nsTArrays; r=roc 2015-05-12 10:12:01 -04:00
Kartikaya Gupta
5c55f94ee0 Bug 1022080 - Split out the paint item dumping from the rest of the paint dumping. r=mattwoodrow 2015-05-12 09:16:54 -04:00
Morris Tseng
9372f985dd Bug 1161662 - Exclude post scale from layer.GetTransform(). r=roc 2015-05-07 01:18:00 +02:00
L. David Baron
613a1db1d8 Bug 1153539 patch 2 - Compute scale for rasterizing off-main-thread transform animations based on ratio to display size in addition to maximum and minimum scale. r=roc
This fixes bug 1153539 with the Firefox download arrow being pixellated
(verified by testing locally).

I also confirmed what happens on a flame device with the transform
unlocking the Firefox OS homescreen (bug 945082 / bug 972310).  For that
transform (which had a maximum scale of 2), I see four calls to
GetSuitableScale:
  GetSuitableScale: aMaxScale=2.000000, displayVisibleRatio=1.000000
  GetSuitableScale: aMaxScale=2.000000, displayVisibleRatio=1.000586
  GetSuitableScale: aMaxScale=2.000000, displayVisibleRatio=1.000000
  GetSuitableScale: aMaxScale=2.000000, displayVisibleRatio=1.000586
(Presumably the first and third are for width, and the second and fourth
are for height.)  I believe this shows that bug 972310 will remain fixed
with this patch.

I chose to use the pres context's visible area rather than the screen
size because it seemed more appropriate, and also because (if memory
serves correctly) it's much cheaper to get.
2015-05-06 08:52:20 +02:00
Morris Tseng
c3bd218aa6 Bug 1156636 - Remove post scale multiplication for event regions. r=roc 2015-04-28 01:46:00 +02:00
Markus Stange
6d6e33904f Bug 1147194 - Do scroll info layer hoisting when building the display list. r=tn 2015-04-30 14:54:48 -04:00
Markus Stange
8c4b6a72b0 Bug 1141089 - Add more asserts for DisplayItemData, trying to catch whether we're accessing deleted instances. r=roc 2015-04-21 14:13:54 -04:00
Nicolas Silva
d73f54cb00 Bug 1155621 - Make nsIntRect and nsIntPoint typedefs of mozilla::gfx::IntRect and mozilla::gfx::IntPoint. r=Bas 2015-04-21 17:04:57 +02:00
Timothy Nikkel
e30d596402 Bug 1156598. Remove old, dead scroll layer item code. r=mstange 2015-04-20 22:48:10 -05:00
Morris Tseng
2ce5c1a8dd Bug 1147279 - Get correct translation when layer optimize away. r=roc 2015-04-14 22:39:00 +02:00
Ying-Ruei Liang (KK)
2c219b4aaf Bug 1143522 - Convert Layer::mClipRect to ParentLayerIntRect. r=botond
Change interface of getter/setter for mClipRect,
also necessary modification for codes that use these resources.

* * *
Bundle mUseClipRect and mClipRect as Maybe<ParentLayerIntRect> mClipRect
2015-04-11 22:03:00 -04:00
Markus Stange
a9c4cfe989 Bug 1141089 - Check that we're unsetting sDestroyedFrame correctly. r=roc 2015-04-10 17:34:28 -04:00
Markus Stange
48d7ef2d91 Bug 1141089 - Turn these two assertions into release assertions. r=roc 2015-04-10 17:34:04 -04:00
Markus Stange
c3507d019d Bug 1141089 - Use const nsTArray* in all the places where we don't change the array's contents. r=roc 2015-04-10 17:42:42 -04:00
Markus Stange
45b3b6ebe0 Bug 1141089 - Add a few more MOZ_RELEASE_ASSERT(mLayer) checks, just for fun. r=roc 2015-04-10 17:30:09 -04:00
Markus Stange
2413e47897 Bug 1141089 - Remove unused DisplayItemData copy constructor. r=roc 2015-04-10 17:23:22 -04:00
Markus Stange
6abf8493f1 Bug 1141089 - Initialize DisplayItemData with a non-null mLayer, so that mLayer is non-null throughout the object's whole lifetime. r=roc 2015-04-10 17:11:04 -04:00
Seth Fowler
610a6bff26 Bug 1150774 (Part 2) - Use the correct units in nsDisplayImageContainer::ConfigureLayer and related code. r=botond 2015-04-07 18:55:28 -07:00
Markus Stange
a595e183ed Bug 1151306 - Add a missing check during background color pulling. r=roc 2015-04-05 14:05:44 -04:00
Markus Stange
62e26df8d4 Bug 1148855 - Rework how display items are assigned to PaintedLayers and make it work the same way with and without APZ. r=roc 2015-04-02 14:22:40 -04:00
Markus Stange
50e2b4ec0f Bug 1148855 - Intermediate state that unifies APZ and non-APZ layerization behavior somewhat. 2015-04-01 17:31:56 -04:00
Markus Stange
974b17b639 Bug 1148855 - Mark some ContainerState methods as const. r=roc 2015-03-25 18:08:56 -04:00
Nicolas Silva
13344864c0 Bug 1132854 - Make nsIntSize a typedef of gfx::IntSize. r=Bas, roc 2015-03-29 16:59:08 +02:00
Tom Tromey
840a9ca9bc Bug 1144820 - Use rvalue reference in AddProfileTimelineMarker. r=smaug 2015-03-27 08:41:00 -04:00
Kearwood (Kip) Gilbert
c4ece0cbcf Bug 1035611 - Part 1: Updated Matrix4x4::ProjectRectBounds to properly handle infinite values when untransformed rects cross the w=0 plane. r=mattwoodrow
- Added specialized rect clipping functionality to Matrix4x4::ProjectRectBounds
  so we don't have to return infinite values when rects cross the w=0 plane
  in homogenous coordinate space.
- Updated callsites of ProjectRectBounds to pass a clipping rect that is
  appropriate for the units that are returned.
2015-03-13 16:42:00 -04:00
Kushan Joshi
183deadbee Bug 1101627 - Add touch action regions. r=kats 2015-03-24 09:13:24 -04:00
Ehsan Akhgari
ea41d8de48 Bug 1145631 - Part 1: Replace MOZ_OVERRIDE and MOZ_FINAL with override and final in the tree; r=froydnj
This patch was automatically generated using the following script:

function convert() {
echo "Converting $1 to $2..."
find . \
       ! -wholename "*/.git*" \
       ! -wholename "obj-ff-dbg*" \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.c" \
         -o -iname "*.cc" \
         -o -iname "*.idl" \
         -o -iname "*.ipdl" \
         -o -iname "*.ipdlh" \
         -o -iname "*.mm" \) | \
    xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}

convert MOZ_OVERRIDE override
convert MOZ_FINAL final
2015-03-21 12:28:04 -04:00
Markus Stange
b22143048d Bug 1144307 - Destroy scroll info layer items when we're done with them. r=tn 2015-03-17 22:04:33 -04:00
Markus Stange
86517737b7 Bug 1141595 - Make scroll info display item hoisting work after bug 913443. r=tn 2015-03-16 18:37:04 -04:00
Markus Stange
513142d08e Bug 1141089 - Add some release assertions to gather more data. r=roc 2015-03-16 16:04:00 -04:00
Botond Ballo
c2cac95e8c Bug 1139675 - Simplify the APIs for getting and setting the pres shell resolution. r=mstange,mattwoodrow 2015-03-06 18:07:59 -05:00
Jeff Muizelaar
2611102d5c Bug 1143789. Remove unnecessary cast to BasicLayerManager. r=mstange 2015-03-16 14:19:32 -04:00
Markus Stange
29b8c8daad Bug 1142211 - Add layerization testing mechanisms to reftest. r=roc
This adds support for class="reftest-opaque-layer" and for
reftest-assigned-layer="some-layer-name" to the reftest harness.

From reftest/README.txt:

Opaque Layer Tests: class="reftest-opaque-layer"
================================================

If an element should be assigned to a PaintedLayer that's opaque, set the class
"reftest-opaque-layer" on it. This checks whether the layer is opaque during
the last paint of the test, and it works whether your test is an invalidation
test or not. In order to pass the test, the element has to have a primary
frame, and that frame's display items must all be assigned to a single painted
layer and no other layers, so it can't be used on elements that create stacking
contexts (active or inactive).

Layerization Tests: reftest-assigned-layer="layer-name"
=======================================================

If two elements should be assigned to the same PaintedLayer, choose any string
value as the layer name and set the attribute reftest-assigned-layer="yourname"
on both elements. Reftest will check whether all elements with the same
reftest-assigned-layer value share the same layer. It will also test whether
elements with different reftest-assigned-layer values are assigned to different
layers.
The same restrictions as with class="reftest-opaque-layer" apply: All elements
must have a primary frame, and that frame's display items must all be assigned
to the same PaintedLayer and no other layers. If these requirements are not
met, the test will fail.
2015-03-11 14:51:59 -04:00
Markus Stange
49816b85c2 Bug 1141281 - Don't put empty Info: lines into the layers dump. r=BenWa 2015-03-09 00:41:11 -04:00
Markus Stange
2ae8abfa79 Bug 1141408 - Don't include the display item's memory address in the profile label. r=BenWa 2015-03-07 18:40:03 -05:00
Milan Sreckovic
a5610e14a3 Bug 1140113 - Catch direct (and some indirect) callers of CreateDrawTarget* and deal with failure. r=mstange 2015-03-09 15:48:20 -04:00
Markus Stange
85ccc11393 Bug 913443 - Remove duplicated argument variables. r=roc 2015-03-04 12:08:28 -05:00
Markus Stange
91a57f7c13 Bug 913443 - Recycle PaintedLayers as soon as possible. r=roc
This means layers are assigned bottom-to-top.
2015-03-04 00:18:47 -05:00
Markus Stange
b1f42e9cfa Bug 913443 - When determining the layer to recycle, only consider layers that have display items in common with the layer we need. r=roc 2015-03-04 00:21:00 -05:00
Markus Stange
32bdb84387 Bug 913443 - Delay PaintedLayer recycling until PopPaintedLayerData(). r=roc
Once we're smarter about recycling the right layer, we can't decide on a layer
as soon as we encounter its first display item. We might need to have to look
at all of the assigned display items. This change makes that requirement
explicit.
2015-03-03 21:32:08 -05:00
Markus Stange
53382a0e6b Bug 913443 - Add a display item buffer for PaintedLayerData so that we can assign items without needing to know the actual Layer. r=roc 2015-03-04 00:21:55 -05:00
Markus Stange
9028c78896 Bug 913443 - Change the order of these calls. r=roc
The calls above don't need access to the PaintedLayer, but the ones this change
is moving down do. This change just makes it more obvious that we're free to
move the calls to an even later point.
2015-03-03 17:21:42 -05:00
Markus Stange
cb89375a41 Bug 913443 - Move IsWidgetLayerManager() check out of UpdateCommonClipCount. r=roc
UpdateCommonClipCount accesses the PaintedLayerData's mLayer field in order to
get the layer manager. We want to be able to call UpdateCommonClipCount when
mLayer is null.
2015-03-03 17:00:55 -05:00
Markus Stange
87afc2f865 Bug 913443 - Remove unused aItemVisibleRect argument. r=roc 2015-03-03 16:57:30 -05:00
Markus Stange
2bffef71e9 Bug 913443 - Break CreateOrRecyclePaintedLayer up even more. r=roc 2015-03-02 19:25:13 -05:00
Markus Stange
248cad10db Bug 913443 - Extract layer hint calculation. r=roc 2015-03-02 19:24:18 -05:00
Markus Stange
e04a240904 Bug 913443 - Break up CreateOrRecyclePaintedLayer into more parts. r=roc 2015-03-02 18:43:58 -05:00
Markus Stange
757489f378 Bug 913443 - Remove some #ifdefs. r=roc
This function will be split up into more functions, and carrying along the
#ifdefs throughout those would be a pain.
2015-03-02 18:29:12 -05:00
Markus Stange
107de28cd7 Bug 913443 - Remove mention of the word ThebesLayer in a comment. r=roc 2015-03-02 18:19:12 -05:00