Commit Graph

522 Commits

Author SHA1 Message Date
Emilio Cobos Álvarez
de099db7bd Bug 1444905: Remove scoped style support from the old style system. r=xidorn,smaug
Summary: It uses two node bits that can be better suited for something else.

Reviewers: xidorn, smaug

Bug #: 1444905

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

MozReview-Commit-ID: HIPDtHm6xpM
2018-03-13 10:26:13 +01:00
Xidorn Quan
5b522decf1 Bug 1441729 - Remove aTextIsSignificant param from nsStyleUtil::IsSignificantChild and its friends. r=emilio
MozReview-Commit-ID: CEZmAwcnglg

--HG--
extra : rebase_source : 4b5526baaf6a5fdee658ae5bdecb46e719bb2d38
2018-02-28 12:54:01 +11:00
Daniel Holbert
10b8b4cdb3 Bug 1437723: Preemptively fix unified bustage in layout/style by adding missing includes/namespaces/forward-decls. r=emilio
MozReview-Commit-ID: 8ljZkAqgT4N

--HG--
extra : rebase_source : bea400511aa6c6c10e76c8418d6dfc8df2b31d17
2018-02-12 16:53:44 -08:00
Boris Zbarsky
3660ff5632 Bug 1436508 part 13. Remove nsIDOMMutationEvent constants. r=masayuki
MozReview-Commit-ID: Anl5QJZknJL
2018-02-09 11:17:10 -05:00
Andrea Marchesini
e4c986bbbc Bug 1425440 - Get rid of GetChildAt_Deprecated in nsCSSRuleProcessor, r=catalinb 2018-01-12 22:24:14 +01:00
Andrea Marchesini
00e79ef07b Bug 1425321 - Renaming nsINode::GetChildAt to GetChildAt_Deprecated, r=catalinb
We want to deprecate nsINode::GetChildAt as the first step of removing DOM node
child array storage. See bug 651120.
2018-01-03 13:59:54 +01:00
Cameron McCormack
de377508c9 Bug 1418232 - Part 1: Move pseudo-class matching helper methods from nsCSSRuleProcessor to nsCSSPseudoClasses. r=emilio
MozReview-Commit-ID: LYn6duc0Zwh

--HG--
extra : rebase_source : d05df8d736547426c8719d114782556571b6479b
2017-11-17 16:48:34 +08:00
Cameron McCormack
0c8270fed4 Bug 1418222 - Move system metrics handling to nsMediaFeatures. r=TYLin
MozReview-Commit-ID: 25yWc29Wt4R

--HG--
extra : rebase_source : 2f17bd7444de71c6e4d4cb2429ba85180425fc52
2017-11-17 15:35:26 +08:00
Cameron McCormack
99c87da38a Bug 1418217 - Move visited links pref to StylePrefs. r=TYLin
On a CLOSED TREE to fix Servo bustage.

MozReview-Commit-ID: HLukaX0EFFv
2017-11-17 14:08:22 +01:00
Martin Stransky
aa7f0bf7f1 Bug 1413166 - Bind gtk_csd* atoms with LookAndFeel, r=bz
Based on patch by Andrew Comminos [:acomminos] <andrew@comminos.com>

MozReview-Commit-ID: 91pyS53yTVt

--HG--
extra : rebase_source : 7418ba9f83075211f2a8d9b0ef85039684e78121
2017-10-31 14:27:58 +01:00
Attila Craciun
334a1e2309 Backed out 5 changesets (bug 1413166) for failing valgrind-test at Conditional jump or move depends on uninitialised value(s) at nsCSSRuleProcessor::InitSystemMetrics / InitSystemMetrics / nsCSSRuleProcessor::HasSystemMetric / GetSystemMetric r=backout on a CLOSED TREE.
Backed out changeset b39bf4bf8127 (bug 1413166)
Backed out changeset e1ef2adcc815 (bug 1413166)
Backed out changeset 16fd21f5ad8c (bug 1413166)
Backed out changeset 9e5f5924dad8 (bug 1413166)
Backed out changeset 3b8671ab0719 (bug 1413166)
2017-11-03 15:55:56 +02:00
Emilio Cobos Álvarez
76b64c7c5f Bug 1374247: Keep the hack working on late beta and release, so we can land this a little earlier. r=bz,xidorn
As Xidorn mentions, if the plan is stylo-in-chrome for 59, we really should land
this assertion pretty much now. This ensures that we don't ship 58 without this
hack.

MozReview-Commit-ID: JXol2r3BMtC
2017-11-03 14:30:05 +01:00
Emilio Cobos Álvarez
101005c955 Bug 1374247: Remove the XBL children matching hack, and assert against it. r=xidorn,francois
MozReview-Commit-ID: 9Q9WpJFczxc
2017-11-03 14:30:03 +01:00
Martin Stransky
29fb3228ed Bug 1413166 - Bind gtk_csd* atoms with LookAndFeel, r=bz
Based on patch by Andrew Comminos [:acomminos] <andrew@comminos.com>

MozReview-Commit-ID: 91pyS53yTVt

--HG--
extra : rebase_source : 7418ba9f83075211f2a8d9b0ef85039684e78121
2017-10-31 14:27:58 +01:00
Mike Hommey
04fe451c07 Bug 1413111 - Use nsTSubstring::Split in nsCSSRuleProcessor::LangPseudoMatches instead of manually go through with FindChar. r=dbaron,njn
--HG--
extra : rebase_source : ff5fc57a3ec6ce6878789bf59524c7180d85c716
2017-11-01 10:19:56 +09:00
Daniel Holbert
680815cd6e Bug 1412346 part 5: (automated patch) Switch a bunch of C++ files in layout to use our standard mode lines. r=jfkthame
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: EuRsDue63tK

--HG--
extra : rebase_source : 3356d4b80ff6213935192e87cdbc9103fec6084c
2017-10-27 10:33:53 -07:00
Emilio Cobos Álvarez
63db5c2845 Bug 1408838: Remove -moz-physical-home-button system metric. r=xidorn
MozReview-Commit-ID: A7nZdj6GQtM

--HG--
extra : rebase_source : b721a9e21e935fdb08bb0b0342d447d89509986b
2017-10-16 08:57:59 +02:00
Xidorn Quan
841f0f88b0 Bug 1407843 part 3 - Remove nsICSSPseudoComparator. r=heycam
MozReview-Commit-ID: Ct3zUoiSIA4

--HG--
extra : rebase_source : 4a415c13fe51d5cfbff0c9cd873f3100974da327
2017-10-13 13:50:04 +11:00
Xidorn Quan
22466ec8dd Bug 1407843 part 2 - Move tree pseudo matching code from nsTreeBodyFrame into nsCSSRuleProcessor. r=heycam
MozReview-Commit-ID: FyPhBLGX2qD

--HG--
extra : rebase_source : b401f41a6132be6ca4d438c97aa7e09865c94adb
2017-10-13 12:54:18 +11:00
Emilio Cobos Álvarez
d19ac89f75 Bug 1405311: Remove :-moz-system-metric pseudo-class. r=xidorn
MozReview-Commit-ID: CIF64dG1F2k
2017-10-12 15:10:49 +02:00
Emilio Cobos Álvarez
e808575ca4 Bug 1406631: Remove the color-picker-available system metric. r=xidorn
All our widgets support it with a constant true.

MozReview-Commit-ID: JMEItUsxYWq

--HG--
extra : rebase_source : e7e0a3f83001813239338bc5b3895252e1fb3ea6
2017-10-07 14:06:44 +02:00
Hiroyuki Ikezoe
5e34bc1f57 Bug 1329169 - Use atom for animation-name property. r=xidorn
MozReview-Commit-ID: 9yVWXVi1oXf

--HG--
extra : rebase_source : f0d8a731c3e6caaf248a0b0e25ef96370af3ecd8
2017-10-10 17:00:28 +09:00
Nicholas Nethercote
d225f7151b Bug 1400460 - Rename nsIAtom as nsAtom. r=hiro.
(Path is actually r=froydnj.)

Bug 1400459 devirtualized nsIAtom so that it is no longer a subclass of
nsISupports. This means that nsAtom is now a better name for it than nsIAtom.

MozReview-Commit-ID: 91U22X2NydP

--HG--
rename : xpcom/ds/nsIAtom.h => xpcom/ds/nsAtom.h
extra : rebase_source : ac3e904a21b8b48e74534fff964f1623ee937c67
2017-10-03 09:05:19 +11:00
Sebastian Hengst
b29f365446 Backed out changeset f70d6fcdb760 (bug 1406631) for failing color related reftests like layout/reftests/writing-mode/ua-style-sheet-input-color-1.html on Android. r=backout 2017-10-07 20:08:12 +02:00
Emilio Cobos Álvarez
b7befbe6b5 Bug 1406631: Remove the color-picker-available system metric. r=xidorn
All our widgets support it with a constant true.

MozReview-Commit-ID: JMEItUsxYWq

--HG--
extra : rebase_source : a2661dce1ac191fdf098e631cd7878f0215643d5
2017-10-07 14:06:44 +02:00
Emilio Cobos Álvarez
371f0cc42f Bug 1396073: Simplify and remove some more code. r=xidorn
MozReview-Commit-ID: Ec9pfQw7U6W
Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
2017-09-28 12:26:44 +02:00
Emilio Cobos Álvarez
88eef10615 Bug 1396073: Remove :-moz-empty-except-children-with-local-name. r=xidorn
<applet> is not a thing anymore, and that selector in our UA sheet will never
match anyway, since an <applet> element will never have the BROKEN state.

MozReview-Commit-ID: 7UOMKOv55uJ
Signed-off-by: Emilio Cobos Álvarez <emilio@crisal.io>
2017-09-28 12:26:26 +02:00
Nicholas Nethercote
dfd3b7e7aa Bug 1400459 (part 2) - Devirtualize nsIAtom. r=heycam.
This patch merges nsAtom into nsIAtom. For the moment, both names can be used
interchangeably due to a typedef. The patch also devirtualizes nsIAtom, by
making it not inherit from nsISupports, removing NS_DECL_NSIATOM, and dropping
the use of NS_IMETHOD_. It also removes nsIAtom's IIDs.

These changes trigger knock-on changes throughout the codebase, changing the
types of lots of things as follows.

- nsCOMPtr<nsIAtom> --> RefPtr<nsIAtom>

- nsCOMArray<nsIAtom> --> nsTArray<RefPtr<nsIAtom>>
  - Count() --> Length()
  - ObjectAt() --> ElementAt()
  - AppendObject() --> AppendElement()
  - RemoveObjectAt() --> RemoveElementAt()

- ns*Hashtable<nsISupportsHashKey, ...> -->
  ns*Hashtable<nsRefPtrHashKey<nsIAtom>, ...>

- nsInterfaceHashtable<T, nsIAtom> --> nsRefPtrHashtable<T, nsIAtom>
  - This requires adding a Get() method to nsRefPtrHashtable that it lacks but
    nsInterfaceHashtable has.

- nsCOMPtr<nsIMutableArray> --> nsTArray<RefPtr<nsIAtom>>
  - nsArrayBase::Create() --> nsTArray()
  - GetLength() --> Length()
  - do_QueryElementAt() --> operator[]

The patch also has some changes to Rust code that manipulates nsIAtom.

MozReview-Commit-ID: DykOl8aEnUJ

--HG--
extra : rebase_source : 254404e318e94b4c93ec8d4081ff0f0fda8aa7d1
2017-09-26 08:33:21 +10:00
Emilio Cobos Álvarez
ecbfd2ef14 Bug 1383307: Honor the relevant link visited pref. r=manishearth
MozReview-Commit-ID: D5NiEJUpONQ
2017-07-23 23:56:37 +02:00
Sylvestre Ledru
7c0ae251cd Bug 1381253 - Remove redundant control flow declarations rs=ehsan
MozReview-Commit-ID: FFxP4aMCbOL

--HG--
extra : amend_source : 3aec108430b11048f47ffe19d5da7ac5034770a9
2017-07-15 19:03:04 +02:00
Dão Gottwald
4b7389da4e Bug 1379938 - Rename the -moz-windows-accent-color-applies media query and make -moz-win-accentcolor available without it. r=jimm
MozReview-Commit-ID: 9zMr9JwkloF

--HG--
extra : rebase_source : 25e9cfa11dc0c3ff09e4e3aac18a53535cbcc27b
2017-07-19 16:38:49 +02:00
Dão Gottwald
8f5c440b72 Backed out changeset 5a5d8de65b70 (bug 1379938) on CLOSED TREE 2017-07-13 23:16:12 +02:00
Dão Gottwald
0f2337c0c7 Bug 1379938 - Rename the -moz-windows-accent-color-applies media query and make -moz-win-accentcolor available without it. r=jimm
MozReview-Commit-ID: BkDrm6KtiP3

--HG--
extra : rebase_source : 1c0deb5b77e1ce83a8f157c100606c563d61577c
2017-07-13 11:08:27 +02:00
Ehsan Akhgari
4390e804ca Bug 1379308 - Improve the hash key generation for two of the hashtables in nsCSSRuleProcessor.cpp; r=mats 2017-07-07 20:34:46 -04:00
Sylvestre Ledru
4e9cf83ee8 Bug 1378712 - Remove all trailing whitespaces r=Ehsan
MozReview-Commit-ID: Kdz2xtTF9EG

--HG--
extra : rebase_source : 7235b3802f25bab29a8c6ba40a181a722f3df0ce
2017-07-06 14:00:35 +02:00
Jonathan Watt
c9118ba223 Bug 1344917, part 1 - Add a '-moz-windows-accent-color-applies' media query. r=heycam
The '-moz-windows-accent-color-applies' media query matches when the Windows 10
accent color should be used as the background of the title bar.

MozReview-Commit-ID: GM7nZij6MhQ

--HG--
extra : rebase_source : ee8089ef876d0887e2c0d063015145d17eefa612
2017-06-08 14:49:21 +01:00
cku
e3fbcec1af Bug 265894 - Part 9. Selectors should not cross use-element shadow tree boundary. r=heycam
MozReview-Commit-ID: 9xrZ5938FRV

--HG--
extra : rebase_source : 4bf4fc35091db868a2908ad5a8c4589e82fd29f7
2017-06-14 23:06:30 +08:00
Emilio Cobos Álvarez
f6dc661b5b Bug 1370802: Parse lang attributes as atoms. r=heycam
MozReview-Commit-ID: Cnq3wB7aVB1

--HG--
extra : rebase_source : fa0252b78381bf023ab08bf2d9fd13d4c0ed57a1
2017-06-15 21:48:26 +02:00
Manish Goregaokar
01dc13b311 Bug 1373018 - Part 1: stylo: Introduce ServoStyleContext and GeckoStyleContext subclasses; r=bholley
MozReview-Commit-ID: GY1GfkWMK0n

--HG--
extra : rebase_source : a631b068cf0d54f5105e3dfe411365157490cac5
2017-06-10 22:27:45 -07:00
Cameron McCormack
84f883b1fb Bug 1365162 - Part 5: Factor out :lang() matching function. r=emilio
MozReview-Commit-ID: KhCd90UPatX

--HG--
extra : rebase_source : f0514a8ee96c9b97e8a4fb98c56f2c256349ec00
2017-06-07 12:17:31 +08:00
Xidorn Quan
e226b79b7c Bug 1368782 - Always use rule order for cascading child sheets. r=dbaron
MozReview-Commit-ID: IzEsMvzGqIm

--HG--
extra : rebase_source : a3880b2a16b5346593e40ed868f58e0ec605b5ff
2017-05-31 10:51:25 +10:00
J. Ryan Stinnett
3041171150 Bug 1328509 - Wire up visited values in ServoStyleSet::GetContext. r=emilio
Create an extra style context using the visited values (if they exist).  This
mirrors the logic Gecko performs in nsStyleSet::GetContext for visited support.

MozReview-Commit-ID: EiJQXDgz8tX
2017-05-25 10:13:23 -05:00
J. Ryan Stinnett
e1b39c2e80 Bug 1328509 - GetContentStateForVisitedHandling can access state directly. r=dbaron
While studying `GetContentStateForVisitedHandling` for adaptation to Stylo, I
noticed it calls through to `GetContentState`, which depends on external state
such as private browser, etc.

However, there's no need to call `GetContentState` here since this function
always clears both unvisited and visited if either is set.

MozReview-Commit-ID: JLwKnowQbJ2
2017-05-25 10:12:01 -05:00
Phil Ringnalda
30a91cb819 Backed out 6 changesets (bug 1328509) for Windows 7 failures in test_visited_reftests.html
Backed out changeset 8388d8c76fed (bug 1328509)
Backed out changeset 182a88607e08 (bug 1328509)
Backed out changeset 008efac7764b (bug 1328509)
Backed out changeset c2ce10b8bc37 (bug 1328509)
Backed out changeset 65bbc73c87aa (bug 1328509)
Backed out changeset e20d3d5170c2 (bug 1328509)

MozReview-Commit-ID: BSmqdFP1Zom
2017-05-24 22:12:53 -07:00
J. Ryan Stinnett
56b5ec82a0 Bug 1328509 - Wire up visited values in ServoStyleSet::GetContext. r=emilio
Create an extra style context using the visited values (if they exist).  This
mirrors the logic Gecko performs in nsStyleSet::GetContext for visited support.

MozReview-Commit-ID: EiJQXDgz8tX
2017-05-24 21:20:06 -05:00
J. Ryan Stinnett
8b8439d4f3 Bug 1328509 - GetContentStateForVisitedHandling can access state directly. r=dbaron
While studying `GetContentStateForVisitedHandling` for adaptation to Stylo, I
noticed it calls through to `GetContentState`, which depends on external state
such as private browser, etc.

However, there's no need to call `GetContentState` here since this function
always clears both unvisited and visited if either is set.

MozReview-Commit-ID: JLwKnowQbJ2
2017-05-24 21:20:04 -05:00
Xidorn Quan
6f168c437d Bug 1328319 part 1 - Move nsCSSCounterStyleRule into a separate header file. r=heycam
MozReview-Commit-ID: Lm1GiKNsgI0

--HG--
extra : rebase_source : 8b792236cf6c89a7469df26cfc57dd66f35f9eef
2017-05-09 21:52:06 +10:00
Xidorn Quan
98f239480d Bug 1362302 part 1 - Use nsIAtom for counter style names. r=dbaron
MozReview-Commit-ID: 5VK6BgGRVRs

--HG--
extra : rebase_source : 104a28eddeb7984bd9f691693cf8debc1387fb87
2017-05-06 11:34:35 +10:00
Manish Goregaokar
1042765b58 Bug 1356305 - stylo: Initialize system metrics before traversing; r=bholley
MozReview-Commit-ID: IOeT4qSHTy5

--HG--
extra : rebase_source : 3a3f87d8564bd47620b0658aef97522f3583dfbe
2017-04-14 09:28:25 +08:00
Eric Rahm
861a58d5a4 Bug 1351904 - Switch layout over to ArenaAllocator. r=xidorn
This switches over layout's usage of PLArena to ArenaAllocator. This allows
us to build more files in unified sources and gets rid of various CONST masks.

MozReview-Commit-ID: Aaf3Dl2kaoz
2017-03-31 14:06:33 -07:00