David Zbarsky
1c27c4d045
[Bug 847110] Fix up includes in layout/style r=dbaron
2013-03-02 19:31:48 -05:00
Kyle Huey
0ee82049a5
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
Randell Jesup
3b4961b603
Bug 773151: Convert nsCAutoString->nsAutoCString CLOSED TREE r=bsmedberg
2012-09-01 22:35:17 -04:00
Ehsan Akhgari
243c878d26
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
David Zbarsky
191398e14e
[Bug 780428] Don't include nsIFrame.h in places where it's not necessary r=roc
2012-08-05 23:00:56 -04:00
Aryeh Gregor
8b4a23fc4c
Bug 777292 part 2 - Change all nsnull to nullptr
2012-07-30 17:20:58 +03:00
Gervase Markham
cb6a072c2a
Bug 716478 - update licence to MPL 2.
2012-05-21 12:12:37 +01:00
Nicholas Nethercote
c1dd090b4c
Bug 715453 - Remove computedSize from nsMallocSizeOfFun. r=jlebar,bhackett.
2012-01-25 00:52:51 -08:00
Nicholas Nethercote
a76fc052f5
Bug 705987 - Use mallocSizeOf in the layout memory reporters. r=khuey,bzbarsky
2011-12-08 21:01:52 -08:00
Matheus Kerschbaum
0e909492fe
Bug 698630 - Remove --disable-smil build option; r=dholbert
2011-11-05 10:32:52 +00:00
Ehsan Akhgari
478ad1a412
Bug 690892 - Replace PR_TRUE/PR_FALSE with true/false on mozilla-central; rs=dbaron
...
Landing on a CLOSED TREE
2011-10-17 10:59:28 -04:00
Michael Wu
0fe7772ece
Bug 675553 - Switch from PRBool to bool on a CLOSED TREE , r=bsmedberg,khuey,bz,cjones
2011-09-28 23:19:26 -07:00
Craig Topper
fc51c496b9
Bug 576831 part 4. Remove nsICSSStyleRule and use mozilla::css::StyleRule instead. r=bzbarsky
2011-03-10 21:48:57 -05:00
Craig Topper
6954d497fb
Bug 575901 - DeCOMtaminate nsIStyleRuleProcessor method signatures. r=bz
2010-07-18 23:20:40 +02:00
Boris Zbarsky
0a1730db7c
Bug 555627. Make transitions actually work correctly on :before and :after. r=dbaron
2010-06-30 18:54:29 -07:00
Craig Topper
2a903a226d
Change some nsIStyleSheet methods from returning AddRef-ed to un-AddRef-ed pointers, and some other cleanup. (Bug 239008) r=dbaron
2010-05-17 21:00:39 -07:00
Craig Topper
9c6993fafb
Rename nsIStyleSheet::GetApplicable to IsApplicable and GetComplete to IsComplete. (Bug 239008) r=dbaron
2010-05-14 12:05:14 -07:00
Boris Zbarsky
90fbe3d23f
Bug 565809. Move checking for style attribute changes into the cascade level. r=dbaron
2010-05-14 13:04:51 -04:00
Craig Topper
bc479824b7
DeCOMtaminate nsIStyleSheet method signatures. (Bug 239008) r=dbaron
2010-05-12 13:18:47 -07:00
Boris Zbarsky
cd27fc6a1c
Bug 562971. Include Element.h as mozilla/dom/Element.h and don't use 'using namespace' quite as much. r=jst
2010-05-05 14:18:05 -04:00
Boris Zbarsky
04369f836f
Bug 562688 part 14. Eliminate eELEMENT usage in the rule processor; switch to Element as we can. r=dbaron
2010-04-30 09:12:06 -04:00
Zack Weinberg
bbd7ec0ef6
Bug 494117 preliminary refactor: Search-and-replace 'ReStyle' with 'Restyle' throughout layout. r=roc
2010-03-31 17:43:32 -07:00
Markus Stange
d0cb573e65
Bug 508482 - Window activation status should be a pseudoclass (:-moz-window-inactive) instead of an attribute. r=dbaron, r+sr=jst
2010-03-17 18:10:57 +01:00
Markus Stange
8e573045c0
Backed out changeset e17c076aceea, bug 508482 (:-moz-window-inactive pseudoclass) because of test_righttoleft.xul test failures.
2010-03-17 20:03:53 +01:00
Markus Stange
56f855c121
Bug 508482 - Window activation status should be a pseudoclass (:-moz-window-inactive) instead of an attribute. r=dbaron, r+sr=jst
2010-03-17 18:10:57 +01:00
Daniel Holbert
c6f482add7
Bug 537139: Prevent SMIL animation from triggering CSS transitions. r=dbaron
2010-03-01 11:31:45 -08:00
L. David Baron
c7a8e2f119
DeCOMify nsHTMLCSSStyleSheet. (Bug 239008) r=bzbarsky
2009-12-31 10:56:33 -05:00
L. David Baron
0e9201325b
Move class definition of nsHTMLCSSStyleSheet into its own header. (Bug 239008) r=bzbarsky
2009-12-31 10:56:32 -05:00
L. David Baron
48c4be18f2
Rename HTMLCSSStyleSheetImpl to nsHTMLCSSStyleSheet. (Bug 239008) r=bzbarsky
2009-12-31 10:56:32 -05:00
Boris Zbarsky
132f15b4f7
Bug 531933. Give HasStateDependentStyle a better signature. r=dbaron
2009-12-11 22:36:34 -08:00
L. David Baron
fe94e54988
Call RuleMatched method on CSS rules when they are matched. (Bug 522595) r=bzbarsky
2009-12-11 08:13:19 -08:00
Boris Zbarsky
ac7336e1e4
Bug 525608 part 7. Make tree pseudos use a separate hashtable instead of riding along on the rulehash. r=dbaron
2009-12-11 02:37:40 -05:00
Boris Zbarsky
5bd63786f3
Bug 525608 part 6. Remove null-checks on RuleProcessorData::mContent. r=dbaron
2009-12-11 02:37:40 -05:00
Boris Zbarsky
4e44a2773f
Bug 525608 part 5. Change anonymous box rule matching to just use a separate hashtable and not ever run SelectorMatches. r=dbaron
2009-12-11 02:37:40 -05:00
Boris Zbarsky
9dddf02038
Bug 525608 part 4. Change pseudo-element probing and resolution to not use EnumerateTagRules. r=dbaron
2009-12-11 02:37:40 -05:00
Boris Zbarsky
e28191d463
Backing out bug 525608 and bug 525952
2009-12-10 18:28:08 -08:00
Boris Zbarsky
2dc3416efd
Bug 525608 part 7. Make tree pseudos use a separate hashtable instead of riding along on the rulehash. r=dbaron
2009-12-10 14:36:06 -08:00
Boris Zbarsky
6a4e4a980d
Bug 525608 part 6. Remove null-checks on RuleProcessorData::mContent. r=dbaron
2009-12-10 14:36:06 -08:00
Boris Zbarsky
466cb9267a
Bug 525608 part 5. Change anonymous box rule matching to just use a separate hashtable and not ever run SelectorMatches. r=dbaron
2009-12-10 14:36:06 -08:00
Boris Zbarsky
d3be0d7fe0
Bug 525608 part 4. Change pseudo-element probing and resolution to not use EnumerateTagRules. r=dbaron
2009-12-10 14:36:06 -08:00
Boris Zbarsky
f7f5bdf839
Bug 523294 part 1. Change the signature of HasAttributeDependentStyle. r=dbaron
2009-12-10 14:36:03 -08:00
Daniel Holbert
ab5c658868
Bug 474049: (first patch) Add SMILOverrideStyle rule & accessors on nsIContent/nsGenericElement, to store SMIL-animated style values. r=dbaron r=bz
2009-09-02 17:28:37 -07:00
L. David Baron
53dc5ba228
Separate RuleProcessorData and derived structs into their own header file to reduce include dependencies. (Bug 435441) r=bzbarsky
2009-08-01 08:53:40 -07:00
L. David Baron
072a78fa56
Replace mechanism for restricting the properties that apply to :first-line and :first-letter. (Bug 469227) r+sr=bzbarsky
2008-12-12 10:59:03 -08:00
L. David Baron
4d33a8e08f
Disable -moz-transform and -moz-transform-origin for :first-line and :first-letter pseudo-elements. (Bug 466845) r+sr=bzbarsky a=blocking1.9.1+
2008-12-12 10:59:03 -08:00
L. David Baron
87ecbe4d19
Merge Quotes and CounterData storage types into ValuePairList. (Bug 322475) r+sr=bzbarsky
2008-08-04 15:15:11 -07:00
L. David Baron
e84914bac8
Implement media queries, part 3: infrastructure for dynamic change handling at the rule processor and style set level. (Bug 156716) r+sr=bzbarsky
2008-07-26 09:14:48 -07:00
L. David Baron
fc42f08dde
Implement Media Queries, part 2: infrastructure for dynamic change handling at the rule cascade and style sheet level. (Bug 156716) r+sr=bzbarsky
2008-07-26 09:14:48 -07:00
3d19607d03
Allow MapRuleInfoInto to map data for multiple structs at the same time. b=240117 r+sr=bzbarsky a=roc
2007-10-08 14:58:22 -07:00
dbaron@dbaron.org
bdeea6cda8
File comments that show up in LXR and provide a quick summary of what's in each file.
2006-03-25 05:47:31 +00:00