Commit Graph

383 Commits

Author SHA1 Message Date
Andreea Pavel
dbd394ae9e Backed out 2 changesets (bug 1504065) for failing Win reftest at child-in-animating-element-display-none.html on a CLOSED TREE
Backed out changeset 129188370231 (bug 1504065)
Backed out changeset 359e81b35cfb (bug 1504065)
2018-11-27 15:33:29 +02:00
Hiroyuki Ikezoe
678e8d5615 Bug 1504065 - Run background-color animations on the compositor. r=birtles
Changes for nsIDOMWindowUtils.getOMTAValue is in the next commit with come test
cases.

Differential Revision: https://phabricator.services.mozilla.com/D13001
2018-11-27 09:26:51 +00:00
Ryan Hunt
8fc281bdb4 Bug 1504220 - Move ScrollableLayerGuid, ViewID, ZoomConstraints from FrameMetrics.h r=botond
This commit attempts to lower the pain of modifying FrameMetrics.h.

It looks like most includes really only want ViewID or
ScrollableLayerGuid, so this commit factors them out into a separate
header. In the process FrameMetrics::ViewID is changed to
ScrollableLayerGuid::ViewID, which personally seems like a better
place for it now that we have RepaintRequest. Unfortunately that
requires a lot of places to be updated.

After this commit there are still a couple of major places that
FrameMetrics is included.
 * nsDisplayList.h
 * nsIScrollableFrame.h
 * Layers.h

Those are going to be more tricky or impossible to fix so they're
not in this commit.

Differential Revision: https://phabricator.services.mozilla.com/D10722
2018-11-01 15:15:46 -05:00
Kartikaya Gupta
7a172a18b1 Bug 1498699 - Only create the AndroidDynamicToolbarAnimator for Fennec. r=jnicol
The bulk of this is adjusting the code that tries to use the toolbar to
have appropriate null checks instead of asserting it will exist. The
creation of the animator instance is now guarded by a IsFennec
condition.

Depends on D8658

Differential Revision: https://phabricator.services.mozilla.com/D8659
2018-10-15 14:56:35 +00:00
Kartikaya Gupta
4f6914b06a Bug 1498699 - Move the FIRST_PAINT notification from AndroidDynamicToolbarAnimator to UiCompositorControllerParent. r=jnicol
Depends on D8657

Differential Revision: https://phabricator.services.mozilla.com/D8658
2018-10-15 13:20:27 +00:00
Kartikaya Gupta
da16723333 Bug 1498699 - Move the LAYERS_UPDATED notification from AndroidDynamicToolbarAnimator to UiCompositorControllerParent. r=jnicol
This extracts code that is conceptually unrelated to the dynamic toolbar
from the dynamic toolbar codebase. It is a stepping stone to being able
to not instantiate the AndroidDynamicToolbarAnimator at all for
non-Fennec android products.

Differential Revision: https://phabricator.services.mozilla.com/D8657
2018-10-15 13:19:16 +00:00
Botond Ballo
8b68524b51 Bug 1489630 - Mark AutoApplyAsyncTestAttributes as MOZ_RAII. r=kats
Differential Revision: https://phabricator.services.mozilla.com/D5306
2018-09-07 20:12:35 +00:00
Gabriele Svelto
b3b1ef307d Bug 1486772 - Refactor the screen-orientation types and headers r=smaug
This patch removes the 'ScreenOrientationInternal' type from
dom/base/ScreenOrientation.h and moves it into the
HalScreenConfiguration.h header, renaming it simply to 'ScreenOrientation'
in the process. This has several knock-off effects:

- It allows files that needed ScreenOrientationInternal to include a much
  smaller header than before

- It greatly reduces the number of headers pulled in when including Hal.h

- It clarifies the role of the type. The 'Internal' part in the name had
  nothing to do with it being part of the implementation. The type was public
  and called that way only to avoid clashing with the 'ScreenOrientation'
  class. Since we moved it into a different namespace it can be renamed
  safely.

- It allows a file that was manually re-declaring 'ScreenConfigurationInternal'
  type to use the original one

- Finally this fixes a few files which were missing headers they actually
  required but that would still build because unified compilation put them into
  units that already had those headers thanks to ScreenConfiguration.h

Differential Revision: https://phabricator.services.mozilla.com/D4458
2018-08-29 20:54:56 +00:00
Kashav Madan
34a2a657e2 Bug 1465616 - Use layout viewport transformations to async-adjust fixed position elements. r=botond
This results in fixed position elements being attached to the layout viewport
when being async-scrolled by APZ (when the layout viewport is larger than the
visual viewport).

MozReview-Commit-ID: 2YYIDnTWgVn
2018-07-20 17:45:48 -04:00
Kashav Madan
2efce63fcc Bug 1465616 - Temporarily apply async test attributes when compositing. r=botond,kats
Includes a new RAII class: AutoApplyAsyncTestAttributes, which, for the
duration of its lifetime, applies mTestAsyncScrollOffset and mTestAsyncZoom to
the APZC's FrameMetrics. We need this to ensure that the
AsyncPanZoomController::GetCurrentAsync* methods consider test scroll and zoom
attributes when doing their respective computations.

MozReview-Commit-ID: 9owJcdIegNH
2018-07-20 17:37:36 -04:00
Ryan VanderMeulen
8095c724b3 Backed out 5 changesets (bug 1465616) for causing Fennec scrolling regressions.
Backed out changeset 403ba3d9539a (bug 1465616)
Backed out changeset ea79ddd406f4 (bug 1465616)
Backed out changeset 559c8997eb53 (bug 1465616)
Backed out changeset 3f5ca59998bf (bug 1465616)
Backed out changeset 9e48a27950be (bug 1465616)
2018-07-20 14:40:51 -04:00
Kashav Madan
3837abd8e1 Bug 1465616 - Remove call to AlignFixedAndStickyLayers for RCD-RSF. r=botond
MozReview-Commit-ID: B8HH6mbjTnv
2018-07-04 15:52:03 -04:00
Hiroyuki Ikezoe
19c81c05d0 Bug 1464568 - Set the shadow base transform value for the case where opacity animations' calculation was skipped. r=kats
And make DOMWindowUtils.getOMTCTransform work for opacity animations' layer.

MozReview-Commit-ID: 7P99WjYqPr0
2018-06-05 12:50:39 +09:00
Hiroyuki Ikezoe
8ed64a7809 Bug 1464568 - Set the shadow base transform for animation explicitly even if the transform value hasn't changed. r=kats
That's because the shadow base transform value might have been changed by APZC.

The test case in this patch fail without this fix on non-WebRender and the test
case is skipped on WebRender since the bug should never happen on WebRender
because WebRender manages animation transform value and APZ transform value
separately.

MozReview-Commit-ID: Itgh0QL1su6
2018-06-05 12:50:36 +09:00
Hiroyuki Ikezoe
ffad189cbb Bug 1464568 - Add an argument to ApplyAsyncProperties() to apply the transform by APZC or not. r=kats
In the next patch, we will introduce a new IPC function to get transform value
modified by both animations and APZC.

MozReview-Commit-ID: Uf5UHg5Jm
2018-06-05 09:18:21 +09:00
Emilio Cobos Álvarez
4b8b5e1717 Bug 1465585: Switch from mozilla::Move to std::move. r=froydnj
This was done automatically replacing:

  s/mozilla::Move/std::move/
  s/ Move(/ std::move(/
  s/(Move(/(std::move(/

Removing the 'using mozilla::Move;' lines.

And then with a few manual fixups, see the bug for the split series..

MozReview-Commit-ID: Jxze3adipUh
2018-06-01 10:45:27 +02:00
Hiroyuki Ikezoe
a74555fc42 Bug 1461023 - Disable the assertion that checks the previous opacity animation value exists when we skip computing opacity animation. r=kats
We are going to re-enable the assertion with a proper fix in bug 1459775.

MozReview-Commit-ID: 2jy6vIImqD
2018-05-12 08:01:46 +09:00
Hiroyuki Ikezoe
999ddde682 Bug 1458457 - Use the current frame time stamp instead of the previous frame's time stamp in the case where the animation was play pending state when the animation was sent to the compositor. r=birtles
When we send play-pending animation to the compositor, we resolve its start
time with the time at the very moment we send the animation to the compositor
instead of refresh drivers' tick time.  That means that it's possible that the
start time indicates more future time stamp than the previous frame time stamp
on the compositor.  If we were to use the previous frame timestamp in this
case, then we'd end up treating the animation as if it had not yet started so
we would skip its initial paint.

MozReview-Commit-ID: 8TdZ6m0gqMm
2018-05-08 16:58:06 +09:00
Hiroyuki Ikezoe
64245bf502 Bug 1458457 - Move the logic that we use whether the previous time stamp or the last compose time stamp into SampleAnimationForEachNode. r=birtles
So that we can do an additional check depending on each animation in a subsequent
patch in this patch series.

MozReview-Commit-ID: C1ZJMdwraVk
2018-05-08 12:58:42 +09:00
Hiroyuki Ikezoe
d31abdea5a Bug 1457249 - Use actually calculated value for the assertion that checks animation value is unchanged when we decided to skip calculation for the animation on debug build. r=kats
Before this change, the value which was set by SetShadowBaseTransform()
has been used for the assertion, but it is possible that the value is changed
by APZ.  And it's hard to tell whether the value has been changed by APZ or not
and it's hard to *reverse-calculate* the differences in the past APZ at the
moment we want to do the assert.

So after this patch, on debug build we don't actually skip the calculation for
unchanged animations and use the newly calculated value for the assertion.

MozReview-Commit-ID: 8fCcvvbUMHe
2018-04-28 18:09:27 +09:00
Hiroyuki Ikezoe
1e8935d9c9 Bug 1457249 - Factor out the function that converts transform into device space. r=kats
MozReview-Commit-ID: L7CDcSdIj4D
2018-04-28 18:08:15 +09:00
Hiroyuki Ikezoe
e26835e692 Bug 1457249 - Factor out the function that converts servo's animation value to matrix. r=kats
MozReview-Commit-ID: HpdFYykOkOS
2018-04-28 18:08:15 +09:00
Hiroyuki Ikezoe
1851b451d6 Bug 1457249 - Assert that there is an animation value set by animations when we skip calculation for newly animation value. r=kats
MozReview-Commit-ID: F85nAmKIGCA
2018-04-28 18:08:15 +09:00
Hiroyuki Ikezoe
302c271b0f Bug 1454324 - Skip calculating animation value if animation's progress value hasn't been changed since the last composition and if there are no other animations on the same element. r=birtles,kats
Note that we have to calculate animation values if there is another animation
since the other animation might be 'accumulate' or 'add', or might have a
missing keyframe (i.e. the calculated animation values will be used in the
missing keyframe).

MozReview-Commit-ID: rQyS9nuVJi
2018-04-24 09:27:54 +09:00
Hiroyuki Ikezoe
2f2afbfec8 Bug 1454324 - Set non-animated values to the layer only if there is no running animation. r=kats
In the next patch, we skip updating animation value for the layer if the
animation value isn't changed.  So without this patch, we will have to update
animation value even if the value isn't changed at all.

MozReview-Commit-ID: 9tU7BTkNOHL
2018-04-24 09:27:54 +09:00
Botond Ballo
9de1075452 Bug 1455285 - In MoveScrollbarForLayerMargin(), move the actual scrollbar thumb layer, not the scrollbar container layer. r=kats
This was regressed by bug 1420512, which changed things so that
ScrollbarData::mDirection is set for both kinds of scrollbar layers.

MozReview-Commit-ID: 3UHFSOgDtWj
2018-04-19 15:58:44 -04:00
Hiroyuki Ikezoe
dddfed71b4 Bug 1455155 - Drop AnimationValue usage in gfx/. r=birtles
Two AnimationValue are still used in AnimationPropertySegment since the
AnimationPropertySegment is used in compose_animation_segment() which is also
invoked on the main-thread, so we will fix it later in a bug that will drop
AnimationValue usage on the main-thread side.

MozReview-Commit-ID: B086g2qHtZL
2018-04-19 13:50:14 +09:00
Coroiu Cristina
3ca1ef71f0 Merge inbound to mozilla-central a=merge 2018-04-18 13:44:22 +03:00
Kartikaya Gupta
ebdee7f0bd Bug 1454485 - Stop passing around the scroll view and container direction since it's already in the scrollbar data. r=botond
MozReview-Commit-ID: 3t4uLBQZSAi
2018-04-17 15:04:34 -04:00
Hiroyuki Ikezoe
916a26357f Bug 1454550 - Call AnimationHelper::SampleAnimationForEachNode only for layers that have animations. r=kats
This is slightly efficient since we don't need to call
GetBaseAnimationStyle() or we do skip allocating animation data for such case.

MozReview-Commit-ID: BYFNwZsZ1oE
2018-04-17 13:20:33 +09:00
Daniel Zielas
2af458e291 Bug 1420512 - Try unifying data structures for scrollbar container and scrollbar thumb info. r=botond
MozReview-Commit-ID: 9zPkrA3CwsN
2018-03-02 19:00:03 +01:00
Kartikaya Gupta
3815264134 Bug 1449287 - Remove obsolete compositor animation telemetry probes. r=botond
MozReview-Commit-ID: 7zFtemtGIAx
2018-04-05 14:55:32 -04:00
Kartikaya Gupta
2b0c5012cf Bug 1446022 - Guard against dereferencing a null APZC pointer in degenerate cases. r=botond
This rolls back a few of the changes from bug 1443792. Although in
theory a LayerMetricsWrapper having an APZC should be equivalent to it
having a scrollable metrics, this might not always be strictly true. For
example, if there is no GeckoContentController registered for a layer
tree, then there might not be APZCs for that layer tree even though it
has scrollable metrics. More importantly, a malicious child process
might be able to trigger scenarios where the equivalence doesn't hold,
and thereby trigger failures in the UI/GPU process.

MozReview-Commit-ID: 1gfbILx7HWU
2018-03-19 17:11:22 -04:00
Kartikaya Gupta
71988f012c Bug 1443792 - Remove direct access to AsyncPanZoomController from AsyncCompositionManager. r=botond
MozReview-Commit-ID: FA8XFOhy1wk
2018-03-12 16:06:38 -04:00
Kartikaya Gupta
dd4654438b Bug 1443792 - Move ComputeTransformForScrollThumb to APZCTreeManager. r=botond
This makes more sense in APZCTreeManager, but is exposed back to
AsyncCompositionManager via APZSampler. This also makes the APZ code
better encapsulated since the method API exposed on APZSampler doesn't
need to take a AsyncPanZoomController; it can just take the
LayerMetricsWrapper instead.

MozReview-Commit-ID: 9yJJd3x8VhN
2018-03-12 16:06:37 -04:00
Kartikaya Gupta
50b60b6cc9 Bug 1443792 - Move the SampleAPZAnimations function into APZSampler. r=botond
MozReview-Commit-ID: 2KIQ5A2J7m9
2018-03-12 16:06:37 -04:00
Kartikaya Gupta
7a361deefd Bug 1443301 - Stop exposing mApzcTreeManager from CompositorBridgeParent. r=botond
MozReview-Commit-ID: 5Dq0HzLImTz
2018-03-07 17:34:11 -05:00
Botond Ballo
436c9a74eb Bug 1442767 - Rename Box to RectAbsolute (Gecko changes). r=kats
MozReview-Commit-ID: 1wrzwQw8bdx
2018-03-05 18:08:18 -05:00
Kartikaya Gupta
f3a49361f4 Bug 1442627 - Stop exporting APZCTreeManager.h in mozilla/layers/. r=botond
MozReview-Commit-ID: GC5fSWOYtF5
2018-03-06 10:25:39 -05:00
Botond Ballo
09f98979a9 Bug 1434250 - Use a Box, rather than a Rect, representation for position:sticky inner/outer rects in the Layers API. r=kats
MozReview-Commit-ID: 4LDQ3XmWynx
2018-02-09 15:40:13 -05:00
Milan Sreckovic
c77bdb1654 Bug 1423570: Use BaseRect access methods instead of member variables in gfx/ r=bas.schouten
MozReview-Commit-ID: ZGySgc9oP3
2017-12-19 15:48:39 -05:00
Botond Ballo
2ed09fbcd8 Bug 1420516 - Remove ScrollDirection::NONE. r=kats
ScrollDirection variables for which NONE was a valid value are replaced with
Maybe<ScrollDirection>.

I also took the opportunity to change the remaining ScrollDirection
enumerators to eTitleCase as per style guide.

MozReview-Commit-ID: GWejQR2HqH5
2017-11-20 19:00:34 -05:00
Daniel Holbert
bb0a8b6602 Bug 1412427 part 8: (automated patch) Switch a bunch of C++ files in gfx to use our standard mode lines. r=jrmuizel
This patch was generated automatically by the "modeline.py" script, available
here: https://github.com/amccreight/moz-source-tools/blob/master/modeline.py

For every file that is modified in this patch, the changes are as follows:
 (1) The patch changes the file to use the exact C++ mode lines from the
     Mozilla coding style guide, available here:
https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Coding_Style#Mode_Line

 (2) The patch deletes any blank lines between the mode line & the MPL
     boilerplate comment.

 (3) If the file previously had the mode lines and MPL boilerplate in a
     single contiguous C++ comment, then the patch splits them into
     separate C++ comments, to match the boilerplate in the coding style.

MozReview-Commit-ID: 77D61xpSmIl
2017-10-27 16:10:06 -07:00
Boris Chiou
462458b3e6 Bug 1340005 - Part 4: Retrieve transform list from AnimationValue. r=birtles
MozReview-Commit-ID: 82NAOBV2rEl
2017-09-25 14:25:43 +08:00
Boris Chiou
63c95da28b Bug 1340005 - Part 3: Use AnimationValue on the compositor thread. r=birtles
MozReview-Commit-ID: CtnDLsdcr9x
2017-09-21 17:01:48 +08:00
Milan Sreckovic
fe9daf64d1 Bug 1387514: Upgrade BaseRect (derived classes) width and height direct member variable use to instead use Width()/SetWidth() and Height()/SetHeight() in .cpp files in gfx/*. r=milan
MozReview-Commit-ID: 1jESowJKdyp
2017-08-14 08:29:28 -04:00
Sylvestre Ledru
576cac5ec7 Bug 1381253 - Remove redundant control flow declarations rs=ehsan
MozReview-Commit-ID: FFxP4aMCbOL
2017-07-15 19:03:04 +02:00
Kartikaya Gupta
42cf0f4da6 Bug 1382200 - Eliminate LayerMetricsWrapper::IsScrollInfoLayer entirely by inlining it. r=botond
MozReview-Commit-ID: KX35cjOAQw7
2017-07-19 09:24:28 -04:00
Kartikaya Gupta
2800e31568 Bug 1382200 - Rename Layer::IsScrollInfoLayer to better capture what the call sites care about. r=botond
MozReview-Commit-ID: 1vMBMo5zOhK
2017-07-19 09:24:22 -04:00
sotaro
0969fd2d2e Bug 1379033 - Remove CompositorBridgeParentBase::GetAnimationStorage() r=kats
The patch removes CompositorBridgeParentBase::GetAnimationStorage and CrossProcessCompositorBridgeParent::GetAnimationStorage, and remove the "aId" parameter to CompositorBridgeParent::GetAnimationStorage, since it's only ever called with "0" as the argument.
2017-07-10 10:03:12 +09:00