Cameron McCormack
1d38a7132f
Bug 829363 - Make :scope match style scope roots. r=bzbarsky
2013-01-16 15:48:29 +11:00
Mats Palmgren
b7ae90666d
Bug 786533 - Replace NS_MIN/NS_MAX with std::min/std::max and #include <algorithm> where needed. r=ehsan
2013-01-15 13:22:03 +01:00
Daniel Holbert
13884b7d1d
Bug 828838: Fix nsCSSRuleProcessor init-list order. r=heycam
2013-01-10 07:55:43 -08:00
Cameron McCormack
4f4a1d1d74
Bug 508725 - Part 6: Modify selector matching to take style scopes into account. r=dbaron
2013-01-09 10:25:48 +11:00
Cameron McCormack
c2964df438
Bug 508725 - Part 5: Record the <style scoped> elements in scope in preparation for selector matching. r=dbaron
2013-01-09 10:25:48 +11:00
Cameron McCormack
42c46424b4
Bug 508725 - Part 3: Create a rule processor for each style scope. r=dbaron
2013-01-09 10:25:47 +11:00
Cameron McCormack
c067646b00
Backout bug 508725 (d267bb4b58b5, 50f71edffeb9, 6aec8e22fe60, e62e1f33958a, 0f146c435249, eb959b9f4862, 2b0ee42f3aa0, 02db01cd6796, 2ef0e517d43d, b650588e05c9 and a3c916829d56) for build failure on a CLOSED TREE.
2013-01-08 19:36:21 +11:00
Cameron McCormack
f83b36df21
Bug 508725 - Part 6: Modify selector matching to take style scopes into account. r=dbaron
2013-01-08 19:09:23 +11:00
Cameron McCormack
5000fec383
Bug 508725 - Part 5: Record the <style scoped> elements in scope in preparation for selector matching. r=dbaron
2013-01-08 19:09:23 +11:00
Cameron McCormack
6b90406bb3
Bug 508725 - Part 3: Create a rule processor for each style scope. r=dbaron
2013-01-08 19:09:22 +11:00
Boris Zbarsky
402ce665fe
Bug 818400. Add a preference to control :scope and pref it off in release builds for now. r=dbaron
2012-12-24 19:35:34 -08:00
Boris Zbarsky
b8f5cf0684
Bug 648722 part 2. Make :scope match the context node for selectors API calls. r=dbaron
2012-12-04 23:15:47 -05:00
Boris Zbarsky
cd6c640261
Bug 648722 part 1. Add a :scope pseudo-class that just matches the same thing as :root for now. r=dbaron
2012-12-04 23:15:47 -05:00
John Schoenick
afe0548a59
Bug 548133 - Remove special handling for object 'pluginurl' param. r=dolske,josh
2012-11-19 11:38:03 -08:00
Brendan Dahl
6adcd0523c
Bug 115199 - CSS2 @page rule style support. r=dbaron
2012-08-31 14:21:28 -07:00
Boris Zbarsky
05ba9f02c1
Bug 811449 part 8. Get rid of nsGenericElement. r=peterv
2012-11-14 14:10:08 -08:00
Cameron McCormack
28fd36a685
Bug 811581 - Add a base class for all *RuleProcessorData classes. r=bz
2012-11-15 06:09:01 +11:00
Ryan VanderMeulen
9cb0f91d55
Backed out changesets 0b6b3d2856a4 and 30776e402787 (bug 115199) for reftest failures.
2012-11-13 20:19:18 -05:00
Brendan Dahl
ec5ca0d279
Bug 115199 - CSS2 @page rule style support. r=dbaron
2012-08-31 14:21:28 -07:00
Jacek Szpot
761b11160f
Bug 792180 - Replace NS_{UN,}LIKELY with MOZ_{UN,}LIKELY; r=ehsan
2012-10-26 15:32:10 +02:00
Peter Van der Beken
e4c543b77c
Fix for bug 773780 (Add API for new DOM bindings for Node). r=bz.
...
--HG--
extra : rebase_source : 5dd51c4ad5274da9235c8c341b0531f234e95a91
2012-10-09 14:31:24 +02:00
Kyle Huey
43e58e33c8
Bug 760331: Coalesce data for inline style across nodes. r=bz
...
This patch enables sharing of an nsAttrValue's MiscContainer between nodes for style rules. MiscContainers of type eCSSStyleRule are now refcounted (with some clever struct packing to ensure that the amount of memory allocated for MiscContainer remains unchanged on 32 and 64 bit). This infrastructure can be used to share most MiscContainer types in the future if we find advantages to sharing other types than just eCSSStyleRuley. A cache mapping strings to MiscContainers has been added to nsHTMLCSSStyleSheet. MiscContainers can be shared between nsAttrValues when one nsAttrValue is SetTo another nsAttrValue or when there is a cache hit in this cache. This patch also adds the ability to tell a style rule that it belongs to an nsHTMLCSSStyleSheet, with appropriate accessor functions to separate that from the existing case of belonging to an nsCSSStyleSheet.
The primary use case is to reduce memory use for pages that have lots of inline style attributes with the same value. This can happen easily with large pages that are automatically generated. An (admittedly pathological) testcase in Bug 686975 sees over 250 MB of memory savings with this change. Reusing the same MiscContainer for multiple nodes saves the overhead of maintaining separate copies of the string containing the serialized value of the style attribute and of creating separate style rules for each node. Eliminating duplicate style rules enables further savings in layout through style context sharing. The testcase sees the amount of memory used by style contexts go from over 250 MB to 10 KB.
Because the cache is based on the text value of the style attribute, it will not handle attributes that have different text values but are parsed into identical style rules. We also do not attempt to share MiscContainers when the node's base URI differs from the document URI. The effect of these limitations is expected to be low.
2012-09-30 09:40:24 -07:00
Simon Montagu
13c3b3bdbc
Add vendor prefix to :dir selector. Bug 562169, r=dbaron
2012-09-29 13:41:10 -07:00
Ehsan Akhgari
e368dc9c85
Bug 579517 - Part 1: Automated conversion of NSPR numeric types to stdint types in Gecko; r=bsmedberg
...
This patch was generated by a script. Here's the source of the script for
future reference:
function convert() {
echo "Converting $1 to $2..."
find . ! -wholename "*nsprpub*" \
! -wholename "*security/nss*" \
! -wholename "*/.hg*" \
! -wholename "obj-ff-dbg*" \
! -name nsXPCOMCID.h \
! -name prtypes.h \
-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 PRInt8 int8_t
convert PRUint8 uint8_t
convert PRInt16 int16_t
convert PRUint16 uint16_t
convert PRInt32 int32_t
convert PRUint32 uint32_t
convert PRInt64 int64_t
convert PRUint64 uint64_t
convert PRIntn int
convert PRUintn unsigned
convert PRSize size_t
convert PROffset32 int32_t
convert PROffset64 int64_t
convert PRPtrdiff ptrdiff_t
convert PRFloat64 double
2012-08-22 11:56:38 -04:00
Aryeh Gregor
4e199a1679
Bug 780618 - Move all error codes to nsError.h; r=ehsan
2012-07-27 17:03:27 +03:00
Simon Montagu
7b0bd7bf8b
Bug 562169. Add support for :dir(ltr/rtl) CSS selector, layout/style part, r=bz
2012-08-09 20:37:58 -07:00
Matt Brubeck
3cfaa1db23
Back out bug 562169 because of Dromaeo DOM regressions
...
Backed out changeset 841cd6e1e585 (bug 562169)
Backed out changeset e226e413dd27 (bug 562169)
Backed out changeset 9c24b7287c5b (bug 562169)
2012-08-08 08:14:48 -07:00
Simon Montagu
aed3f621eb
Add support for :dir(ltr/rtl) CSS selector, layout/style part. Bug 562159, r=bz
2012-08-07 21:44:24 -07:00
Cameron McCormack
1528758ac5
Bug 649740 - Implement @supports. r=dbaron,bz
2012-08-02 10:32:12 +10:00
Aryeh Gregor
d0ad5a7d0c
Bug 777292 part 2 - Change all nsnull to nullptr
2012-07-30 17:20:58 +03:00
Aryeh Gregor
65eef91085
Bug 626472 part 1 - Define nsnull as nullptr where available; r=ehsan
2012-07-20 14:16:17 +03:00
Boris Zbarsky
fcf99ba406
Bug 758885. Don't apply the dynamic :hover reresolution skipping optimization to selectors which can match on mutable state other than :hover. r=dbaron
2012-05-29 00:17:45 -04:00
Gervase Markham
82ff7027aa
Bug 716478 - update licence to MPL 2.
2012-05-21 12:12:37 +01:00
Josh Matthews
0a84303b99
Bug 722853 - Derive private browsing status from docshell when assigning element states. r=dbaron
2012-03-30 02:16:22 -04:00
Ms2ger
cd6e787733
Backout bug 722853 - changeset f40a17213344; r=orange
2012-03-26 18:41:19 +02:00
Josh Matthews
5b05bfee0b
Bug 722853 - Derive private browsing status from docshell when assigning element states. r=dbaron
...
--HG--
extra : rebase_source : d59985b415ccafc4a9c8e8dbea9b69fa61602b8b
2012-02-21 09:57:09 -05:00
Boris Zbarsky
64e0bf573c
Bug 735481. Skip ancestor filtering on IDs and classes in quirks mode, because that matching needs to be case-insensitive. r=dbaron
2012-03-14 00:44:13 -05:00
Boris Zbarsky
0b6e42d918
Bug 732667. Only do checks for :hover selectors when hover state changes on nodes which have relevant hover rules. r=dbaron
2012-03-12 22:54:15 -05:00
Boris Zbarsky
4e80e64553
Bug 705877 part 4. Use the TreeMatchContext's ancestor filter, if any, in EnumerateAllRules. r=dbaron
2012-03-12 22:54:15 -05:00
Boris Zbarsky
3e12270964
Bug 705877 part 3. Hang an optional Bloom filter and some methods for managing it off the TreeMatchContext. r=dbaron
2012-03-12 22:54:15 -05:00
Boris Zbarsky
0f31ab2288
Bug 705877 part 2. Store the hashes of the atoms occurring as IDs, classes, and tag names in selectors that would need to match one of our ancestors. r=dbaron
...
We store a maximum of 4 hashes to save space. Interesting questions are whether 4 is the right number
and whether we should, prioritize ids and classes over tags. In practice, this seems to be good enough
at least performance-wise, though it's possible we could use less memory and still do OK on the performance.
2012-03-12 22:54:14 -05:00
Phil Ringnalda
ef5d0d917f
Back out 83a33626d965:6e9330f5a9bd (bug 732667 and bug 705877) for Windows build bustage
2012-03-12 22:12:41 -07:00
Boris Zbarsky
4de57bccc9
Bug 732667. Only do checks for :hover selectors when hover state changes on nodes which have relevant hover rules. r=dbaron
2012-03-12 22:54:15 -05:00
Boris Zbarsky
c3ed68f368
Bug 705877 part 4. Use the TreeMatchContext's ancestor filter, if any, in EnumerateAllRules. r=dbaron
2012-03-12 22:54:15 -05:00
Boris Zbarsky
f593cd5e83
Bug 705877 part 3. Hang an optional Bloom filter and some methods for managing it off the TreeMatchContext. r=dbaron
2012-03-12 22:54:15 -05:00
Boris Zbarsky
e9f9272eeb
Bug 705877 part 2. Store the hashes of the atoms occurring as IDs, classes, and tag names in selectors that would need to match one of our ancestors. r=dbaron
...
We store a maximum of 4 hashes to save space. Interesting questions are whether 4 is the right number
and whether we should, prioritize ids and classes over tags. In practice, this seems to be good enough
at least performance-wise, though it's possible we could use less memory and still do OK on the performance.
2012-03-12 22:54:14 -05:00
Nathan Froyd
68a79f10ae
Bug 731615 - Eliminate duplicate headers in layout. rs=smontagu
2012-02-29 10:57:47 -05:00
Zack Weinberg
f4fb4a1991
Bug 729142 - Convert layout/style to MOZ_STATIC_ASSERT. r=dbaron
2012-02-23 08:19:00 -08:00
Heather Arthur
580e841242
Bug 708874 - API for locking pseudo-class state of an element. r=bz
2012-02-08 10:42:38 -08:00
Nicholas Nethercote
7559a70a04
Bug 715453 - Remove computedSize from nsMallocSizeOfFun. r=jlebar,bhackett.
...
--HG--
extra : rebase_source : a65039a407daab45360a5b375b53cbf1bc05b7f6
2012-01-25 00:52:51 -08:00