Граф коммитов

71552 Коммитов

Автор SHA1 Сообщение Дата
Hiroyuki Ikezoe 1c0f15006d Bug 1599795 - Rename BrowserChild::GetRemoteDocumentRect to GetTopLevelViewportVisibleRectInBrowserCoords. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D62183

--HG--
extra : moz-landing-system : lando
2020-02-11 03:35:56 +00:00
Hiroyuki Ikezoe d4fa8f4fad Bug 1599795 - Change the remote document rect to size in gfx. r=emilio
What we really needed in the first place was the size not the rect.

Differential Revision: https://phabricator.services.mozilla.com/D62215

--HG--
extra : moz-landing-system : lando
2020-02-11 03:57:14 +00:00
Emilio Cobos Álvarez 49abab29a5 Bug 1614208 - Remove nsStyleConsts usage from TextRange.h. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D62172

--HG--
extra : moz-landing-system : lando
2020-02-11 01:23:12 +00:00
Emilio Cobos Álvarez b997cfcaf4 Bug 1614208 - Stop including PresShell.h and nsPresContext.h from Element.h. r=smaug
nsPresContext.h is only used for unit conversion, which can be done by Units.h
in a similar fashion.

PresShell.h was needed for some capturing-content stuff which can be moved out
of line.

Differential Revision: https://phabricator.services.mozilla.com/D62170

--HG--
extra : moz-landing-system : lando
2020-02-11 01:23:12 +00:00
Emilio Cobos Álvarez 6615ff9fad Bug 1614208 - Stop including AccessibleCaretEventHub and PresShell.h from Selection.h. r=TYLin
And fix a bunch of fallout as we now don't include nsDocShell.h everywhere.

Differential Revision: https://phabricator.services.mozilla.com/D62169

--HG--
extra : moz-landing-system : lando
2020-02-11 01:22:29 +00:00
Emilio Cobos Álvarez fb586787c5 Bug 1614208 - Remove more dependencies on nsStyleConsts.h / ServoStyleConsts.h. r=jfkthame
Mostly what I was seeing come up in the .deps files from my object directory
which sounded feasible.

Differential Revision: https://phabricator.services.mozilla.com/D62167

--HG--
extra : moz-landing-system : lando
2020-02-11 01:22:15 +00:00
Emilio Cobos Álvarez 298c598770 Bug 1614208 - Forward-declare StaticPresData in nsPresContext.h. r=jfkthame
This avoids including nsFont.h and a bunch of other stuff in nsPresContext.h

Differential Revision: https://phabricator.services.mozilla.com/D62166

--HG--
extra : moz-landing-system : lando
2020-02-11 01:23:37 +00:00
Emilio Cobos Álvarez d7841a5f17 Bug 1614208 - Remove some include dependencies in nsStyleConsts.h. r=jfkthame,jgilbert
We include it everywhere because it's included from gfxTypes.h.

This should avoid including all the generated bindings _everywhere_.

Differential Revision: https://phabricator.services.mozilla.com/D62174

--HG--
extra : moz-landing-system : lando
2020-02-11 01:23:37 +00:00
Emilio Cobos Álvarez d6aacafdfd Bug 1614198 - Merge ImageLayer and Image. r=heycam
ImageLayer is almost the only usage of Image, so keeping them in the same enum
makes the resulting C++ struct smaller, and makes it map more cleanly to
nsStyleImage.

Differential Revision: https://phabricator.services.mozilla.com/D62161

--HG--
extra : moz-landing-system : lando
2020-02-10 20:02:31 +00:00
Mihai Alexandru Michis a53731fa59 Backed out changeset a3695dec8b66 (bug 1614198) for causing bustages in ImageLayer
CLOSED TREE
2020-02-10 21:48:26 +02:00
Emilio Cobos Álvarez 0ca6f95831 Bug 1614198 - Merge ImageLayer and Image. r=heycam
ImageLayer is almost the only usage of Image, so keeping them in the same enum
makes the resulting C++ struct smaller, and makes it map more cleanly to
nsStyleImage.

Differential Revision: https://phabricator.services.mozilla.com/D62161

--HG--
extra : moz-landing-system : lando
2020-02-10 19:25:40 +00:00
Emilio Cobos Álvarez 6afe7e573b Bug 1612301 - Add some comments as per jwatt's request.
Differential Revision: https://phabricator.services.mozilla.com/D62318

--HG--
extra : moz-landing-system : lando
2020-02-10 18:20:16 +00:00
Emilio Cobos Álvarez 44abf87d9d Bug 1612301 - Fix LengthPercentage on big-endian machines. r=jfkthame
Always store the pointer in little-endian order so that the tag trick works.

Differential Revision: https://phabricator.services.mozilla.com/D61386

--HG--
extra : moz-landing-system : lando
2020-02-10 17:12:44 +00:00
Botond Ballo 0167696fdf Bug 1612750 - Have the main thread always populate FrameMetrics::mVisualViewportOffset. r=tnikkel
APZ may want to know what the main thread's view of the visual viewport offset
was at the time of the last paint even if the main thread does not want APZ
to scroll to that visual viewport offset.

Differential Revision: https://phabricator.services.mozilla.com/D62093

--HG--
extra : moz-landing-system : lando
2020-02-10 15:19:46 +00:00
Geoff Brown 12a26f2d5a Bug 1613929 - Normalize reftest manifest identifiers; r=jmaher
Use the manifest ID rather than the manifest path in the reftest suite_start message.

Differential Revision: https://phabricator.services.mozilla.com/D62081

--HG--
extra : moz-landing-system : lando
2020-02-10 14:42:09 +00:00
Emilio Cobos Álvarez 451b254453 Bug 1612291 - Fix two issues with themed widgets in high contrast mode. r=heycam
There were two issues with the existing code that we use to determine whether a
widget is styled or not.

First, it was using `color == Color::transparent()` instead of
`color.is_transparent()` to check for transparent backgrounds. That is not sound
as `Color::transparent()` is the literal value `rgba(0, 0, 0, 0)`, not the
`transparent` keyword, so the equality check would fail.

The other issue is that this function was early-returning false if that check
was returning false. It is a bug for this function to early-return false, as it
makes the result of the function dependent of the order of the declarations.

Differential Revision: https://phabricator.services.mozilla.com/D62060

--HG--
extra : moz-landing-system : lando
2020-02-10 00:37:36 +00:00
Mirko Brodesser ce8bf8cde1 Bug 1613378: part 4) Declare some methods in `nsFrameSelection` static. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D62037

--HG--
extra : moz-landing-system : lando
2020-02-07 16:13:27 +00:00
Boris Zbarsky 3d4c7db0aa Bug 1614165 part 2. Improve some error messages in style code. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D62155

--HG--
extra : moz-landing-system : lando
2020-02-09 03:40:48 +00:00
Boris Zbarsky 4472ba99ca Bug 1614165 part 1. Improve error messages for SVG text. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D62154

--HG--
extra : moz-landing-system : lando
2020-02-09 02:15:32 +00:00
Narcis Beleuzu 3b708c3e29 Backed out changeset a7f4f5a7a8c4 (bug 1604200) for reftest failures on selection-001.html . CLOSED TREE 2020-02-09 00:26:28 +02:00
Emilio Cobos Álvarez 459d1fd97d Bug 1604200 - Try to make high-contrast selection test more reliable. r=mats
Use MozReftestInvalidate rather than onload, following the pattern of most of
the tests in layout/reftests/selection.

Differential Revision: https://phabricator.services.mozilla.com/D62139

--HG--
extra : moz-landing-system : lando
2020-02-08 19:18:56 +00:00
Emilio Cobos Álvarez 5830b68d25 No bug - Fix non-unified build in nsImageBoxFrame.cpp
Differential Revision: https://phabricator.services.mozilla.com/D62147

--HG--
extra : moz-landing-system : lando
2020-02-08 16:52:51 +00:00
Alex Henrie 631136f3b0 Bug 1613834 - Remove redundant check from nsTableCellMap::RemoveColsAtEnd. r=dbaron
Differential Revision: https://phabricator.services.mozilla.com/D61962

--HG--
extra : moz-landing-system : lando
2020-02-08 06:29:28 +00:00
Ting-Yu Lin 9855c6722f Bug 1614082 Part 4 - Add spec links to steps in the flex layout algorithm. r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D62134

--HG--
extra : moz-landing-system : lando
2020-02-08 03:57:45 +00:00
Ting-Yu Lin 475a216245 Bug 1614082 Part 3 - Fix static-analysis nits in nsFlexContainerFrame.cpp. r=dholbert
This patch is generated via
`./mach static-analysis check -f layout/generic/nsFlexContainerFrame.cpp` and
`./mach clang-format`.

Differential Revision: https://phabricator.services.mozilla.com/D62133

--HG--
extra : moz-landing-system : lando
2020-02-08 03:58:02 +00:00
Ting-Yu Lin d961c6d216 Bug 1614082 Part 2 - Rename nsStyleDisplay argument on ShouldUseMozBoxCollapseBehavior() to match its declaration in the header. r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D62132

--HG--
extra : moz-landing-system : lando
2020-02-08 03:58:10 +00:00
Ting-Yu Lin fe439623bc Bug 1614082 Part 1 - Remove unused axis tracker arguments from FlexItem methods. r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D62131

--HG--
extra : moz-landing-system : lando
2020-02-08 02:45:11 +00:00
Ting-Yu Lin c508a968ca Bug 1612983 - Disable APZ only when AccessibleCaret's position is changed. r=botond
`mIsCaretPositionChanged` is used in `UpdateShouldDisableApz()` to
determine whether to disable APZ during scrolling or pinch-zooming.

Suppose the selection is on position:static elements. When
pinch-zooming, the zoom level is changed, but the position is not. We
split `PositionChangedResult::Changed` into two separate states, and set
`mIsCaretPositionChanged` only when the position is changed.

Differential Revision: https://phabricator.services.mozilla.com/D61516

--HG--
extra : moz-landing-system : lando
2020-02-07 22:31:40 +00:00
Jamie Nicol 1639434188 Bug 1613144 - Add reftest. r=botond
Add a reftest that would fail in webrender before the corresponding
fix landed.

Ensures that there is an async zoom and that both the layout and
visual viewports have async scroll offsets. To pass, we must apply
each of the layout and visual offsets in their correct coordinate
spaces.

Differential Revision: https://phabricator.services.mozilla.com/D61788

--HG--
extra : moz-landing-system : lando
2020-02-07 20:45:39 +00:00
Emilio Cobos Álvarez 8ce4456bc5 Bug 1606628 - Fix background and border image association to be symmetric. r=tnikkel
And add an assertion to ensure callers get it right. The only thing that needs
it AFAICT is the canvas frame background, so remove the border-image caller...

Differential Revision: https://phabricator.services.mozilla.com/D61950

--HG--
extra : moz-landing-system : lando
2020-02-07 20:36:34 +00:00
Emilio Cobos Álvarez 374cabd6e7 Bug 1606628 - Remove nsStyleImageRequest. r=tnikkel,heycam
This removes nsStyleImageRequest by moving the load state to LoadData instead
(where other lazy state like the resolved URL and load id lives).

That way we can use cbindgen for more stuff (there's no blocker for using it for
all images now), and we can undo the image tracking shenanigans that I had to do
in bug 1605803 in nsImageFrame.

This removes the mDocGroup member because well, there's no real upside of that
now that quantum DOM is not a thing.

It also removes the static clones of the image requests, and the need for each
computed value instance to have its own request. These were needed because we
needed the image loader for the particular document to observe the image
changes. But we were also tracking the request -> loader for other purposes.
Instead, Now all the images get loaded with GlobalImageObserver as a listener,
which looks in the image map and forwards the notification to all the interested
loaders instead dynamically.

The style value is only responsible to load the image, and no longer tracks /
locks it. Instead, the loader does so, via the image tracker.

Differential Revision: https://phabricator.services.mozilla.com/D58519

--HG--
extra : moz-landing-system : lando
2020-02-07 20:36:34 +00:00
shindli 441a09145b Backed out 2 changesets (bug 1613144) for causing reftest failures CLOSED TREE
Backed out changeset 8124309e0bbe (bug 1613144)
Backed out changeset d5d9bf5b8d20 (bug 1613144)
2020-02-07 22:36:52 +02:00
Jamie Nicol 6dc544f0bc Bug 1613144 - Add reftest. r=botond
Add a reftest that would fail in webrender before the corresponding
fix landed.

Ensures that there is an async zoom and that both the layout and
visual viewports have async scroll offsets. To pass, we must apply
each of the layout and visual offsets in their correct coordinate
spaces.

Differential Revision: https://phabricator.services.mozilla.com/D61788

--HG--
extra : moz-landing-system : lando
2020-02-07 13:23:21 +00:00
Ting-Yu Lin c26c7aeb90 Bug 1613380 - Use FlexboxAxisTracker's main axis to initialize strut FlexItem's mMainAxis. r=dholbert
Annotate optiontext.html for Android as slightly fuzzy, to account for
reftest rebucketing fuzzy-failure fallout. It has 0 in the lower bound
of the fuzzy annotation because not every Android has this
fuzzy-failure.

Meanwhile, bug453105.html no longer fails due to reftest rebucketing, so
I remove its fuzzy annotation.

Differential Revision: https://phabricator.services.mozilla.com/D61877

--HG--
extra : moz-landing-system : lando
2020-02-07 18:53:28 +00:00
Geoff Brown 020306b029 Bug 1613792 - Avoid failure in Android 'mach crashtest'; r=bc
Both _setup_objdir() and run_android_test() have code to set the
default test path, and _setup_objdir()'s crashtest path is wrong;
let's rely on the correct code in run_android_test() instead.

Differential Revision: https://phabricator.services.mozilla.com/D61946

--HG--
extra : moz-landing-system : lando
2020-02-07 15:55:41 +00:00
Tushar Sariya f1b8d179cf Bug 1613257 removed redundant return statement. r=smaug
redundant return statement for GetCSSValuesForProperty in InspectorUtils.cpp removed

Differential Revision: https://phabricator.services.mozilla.com/D61954

--HG--
extra : moz-landing-system : lando
2020-02-07 14:06:36 +00:00
Emilio Cobos Álvarez 61d0c10572 Bug 1613490 - Cleanup usage of ReferenceBox. r=miko
To avoid computing transform bounds over and over. It is generally just better.

Replace the various "overridebounds" thingies by using the "fallback" of the
transform-reference-box code which we need anyway.

Differential Revision: https://phabricator.services.mozilla.com/D61890

--HG--
extra : moz-landing-system : lando
2020-02-07 13:34:42 +00:00
Emilio Cobos Álvarez 33003251e7 Bug 1611733 - Remove unneeded static_cast that breaks the build on a CLOSED TREE.
MANUAL PUSH: Fixing contributor's patch.
2020-02-07 14:16:44 +01:00
Miko Mynttinen ad2536665d Bug 1612895 - Rename nsDisplayHitTestInfoItem to nsDisplayHitTestInfoBase r=mattwoodrow
Differential Revision: https://phabricator.services.mozilla.com/D61472

--HG--
extra : moz-landing-system : lando
2020-02-04 22:01:48 +00:00
Miko Mynttinen 448bd0baea Bug 1612318 - Use nsDisplayEventReceiver for main thread hit testing instead of nsDisplayBackgroundColor r=mattwoodrow
Differential Revision: https://phabricator.services.mozilla.com/D61471

--HG--
extra : moz-landing-system : lando
2020-02-04 22:01:00 +00:00
Thomas Dolezal 062c15357a Bug 1611733 - Bug 1611633 - convert ns style position defines to enum class. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D61958

--HG--
extra : moz-landing-system : lando
2020-02-07 12:35:30 +00:00
Mirko Brodesser 6c8a08fecb Bug 1613378: part 2) Remove unnecessary dependency from `nsFrameSelection::GetCellLayout` to `mPresShell` and declare it static. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D61692

--HG--
extra : moz-landing-system : lando
2020-02-07 09:24:43 +00:00
Bogdan Tara e0728bbf97 Backed out changeset 7dc1fd3fa679 (bug 1613380) for optiontext.html failures CLOSED TREE 2020-02-07 07:31:19 +02:00
Ting-Yu Lin b7d5c92a10 Bug 1613732 Part 3 - Use logical ReflowChild() and FinishReflowChild() to do "measuring reflow" of flex items. r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D61887

--HG--
extra : moz-landing-system : lando
2020-02-07 04:17:35 +00:00
Ting-Yu Lin bb0d044a16 Bug 1613732 Part 2 - Remove unused ReflowChildFlags::NoVisibility. r=dholbert
This bit is set, but no function uses it.

Differential Revision: https://phabricator.services.mozilla.com/D61886

--HG--
extra : moz-landing-system : lando
2020-02-07 04:17:33 +00:00
Ting-Yu Lin e50292bfb5 Bug 1613732 Part 1 - Revise documentation for ReflowChildFlags, ReflowChild(), and FinishReflowChild(). r=dholbert
The entire comment deleted in nsContainerFrame.cpp belongs to
FinishReflowChild(), which is already documented in the header.

Change `aChildFrame` to `aKidFrame` for ReflowChild() to match its
implementation.

Differential Revision: https://phabricator.services.mozilla.com/D61885

--HG--
extra : moz-landing-system : lando
2020-02-07 04:17:30 +00:00
Daniel Holbert a4b224a290 Bug 1541095: Remove an unnecessary static_cast in WritingModes.h. r=TYLin
The variables involved in the bitwise arithmetic are all of type uint8_t, so
we end up with that type automatically (no need to bother with a static_cast).

Note that we *do* need to declare the type (we can't use `auto`, or else
the compiler wants to upgrade the local variable to have a wider type --
"int", I think -- and that then produces an build warning when we pass
that variable as a uint8_t param further down).

Differential Revision: https://phabricator.services.mozilla.com/D61893

--HG--
extra : moz-landing-system : lando
2020-02-07 00:39:28 +00:00
Ting-Yu Lin 8a678ca086 Bug 1613380 - Use FlexboxAxisTracker's main axis to initialize strut FlexItem's mMainAxis. r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D61877

--HG--
extra : moz-landing-system : lando
2020-02-06 23:33:24 +00:00
Emilio Cobos Álvarez 873a349556 Bug 1611701 - Tweak NODE_IS_EDITABLE flag handling for NAC so that it works consistently for <input type=number>. r=bzbarsky,masayuki,whimboo
I thought this would fix <input type=number style="user-select: none">, but
turns out it doesn't.

<input type=number> doesn't have the editor root as a root of the anonymous
subtree, so the current hack wouldn't work, as the anon root wouldn't have the
editable flag. So tweak the code a bit to handle stuff in a simpler way than
setting the flags after the fact, and set the NAC-root flag earlier to avoid
the mOuterWrapper->AppendChildTo(root) call forgetting about root's flags.

I had to tweak one AccessibleCaret test, but that's because it uses <textarea>
with user-select: none, and our behavior there is not particularly sane. It just
happened to work because that test-case also had a bunch of contenteditable
elements, and we stop matching this rule:

  https://searchfox.org/mozilla-central/rev/220a3bd6063fcbe5ca50e88dcabdc7dee0aca448/layout/style/contenteditable.css#22

Because the anonymous div now properly matches :-moz-read-write, which made the
rule apply and the test work. See comment 4 of this bug.

I'll fix this stuff up and add some tests for our behavior here in bug 1611699.

I refactored the dragdrop tests to cover more input types, but I ended up not
being able to use them because they're dependent on the content.

Instead I added an extra test and changed the refactor so that it applies to
<input type=search>, as there's layout work going on in bug 558594, and it'd be
unfortunate to regress this there too.

Differential Revision: https://phabricator.services.mozilla.com/D61094

--HG--
extra : moz-landing-system : lando
2020-02-06 22:15:19 +00:00
Boris Zbarsky 747a4d9f0a Bug 1613013 part 1. Annotate DOMExceptions from WebIDL implementations with the method they come from. r=peterv
This adds the name of the interface and method to the beginning of the exception
string when reporting the exception from Web IDL codegen, so it's clearer what
was called.

Some existing error messages are adjusted to not duplicate the information
about which method was called.

Differential Revision: https://phabricator.services.mozilla.com/D61521

--HG--
extra : moz-landing-system : lando
2020-02-06 21:16:10 +00:00