Cameron McCormack
966619a0d1
Bug 1180118 - Part 5: Add a RestyleHintData outparam to HasAttributeDependentStyle for use with eRestyle_SomeDescendants. r=bzbarsky
2015-08-04 17:27:53 +10:00
Cameron McCormack
bf0d2d3bc4
Bug 1180118 - Part 4: Store pointer to the rightmost selector for class, ID and attribute selectors in the rule cascade. r=bzbarsky
2015-08-04 17:27:53 +10:00
Cameron McCormack
eef1458e03
Bug 1180118 - Part 3: Convert eRestyle_SomeDescendants into eRestyle_Self for elements that match selectors. r=bzbarsky
2015-08-04 17:27:52 +10:00
Cameron McCormack
6b0db7331c
Bug 1180118 - Part 1: Add a method to match a single nsCSSSelector (without pseudo-elements) against an Element. r=bzbarsky
2015-08-04 17:27:52 +10:00
Nicholas Nethercote
dd37a3b4b2
Bug 1189156 (part 4) - Don't use enumeration style for nsBaseHashtable::SizeOf{In,Ex}cludingThis(). r=erahm,jfkthame.
...
After this change, we have ShallowSizeOf{In,Ex}cludingThis(), which don't do
anything to measure children. (They can be combined with iteration to measure
children.)
2015-07-30 21:19:57 -07:00
Robert O'Callahan
9885b30027
Bug 1184842. Restyling should consider only the classes that have changed. r=heycam
2015-07-25 17:56:58 +12:00
Nicholas Nethercote
d904560d80
Bug 1189156 (part 1) - Don't use enumeration style for PLDHashTable::SizeOf{In,Ex}cludingThis(). r=froydnj.
...
After this change, we have PLDHashTable::ShallowSizeOf{In,Ex}cludingThis(),
which don't do anything to measure children. (They can be combined with
iteration to measure children.)
This patch also removes the PL_DHashTableSizeOf{In,Ex}cludingThis() functions.
They're not necessary because the methods can be used instead.
Finally, the patch deliberately converts some SizeOfExcludingThis() calls to
SizeOfIncludingThis(). These are all done on heap pointers so this change is
valid.
2015-07-29 22:28:20 -07:00
Nicholas Nethercote
37d91ed8fe
Bug 1188745 - Rename nsTArray::SizeOfExcludingThis() as ShallowSizeOfExcludingThis(). r=froydnj.
...
This makes it clearer that, unlike how SizeOf*() functions usually work, this
doesn't measure any children hanging off the array.
And do likewise for nsTObserverArray.
2015-07-28 23:24:24 -07:00
Cameron McCormack
cb04c74def
Bug 77999 - Part 4: Mark nsCSSRuleProcessors as ready for expiration from the RuleProcessorCache once no nsStyleSets are using them. r=dbaron
...
We want the RuleProcessorCache to start considering a given
nsCSSRuleProcessor as ready for expiration only once no nsStyleSets are
using it.
2015-06-26 13:52:47 +10:00
Cameron McCormack
be5e7316ad
Bug 77999 - Part 3: Gather document rules and produce an nsDocumentRuleResultCacheKey in nsCSSRuleProcessors. r=dbaron
2015-06-26 13:52:47 +10:00
Cameron McCormack
341c732fdb
Bug 77999 - Part 2: Add RuleProcessorCache. r=dbaron
2015-06-26 13:52:47 +10:00
Nicholas Nethercote
3a15b71bd6
Bug 1174631 (part 2) - Replace nsCSSRuleProcessor's uses of PL_DHashTableEnumerate() with PLDHashTable::Iterator. r=dholbert.
2015-06-10 21:28:14 -07:00
Chris Peterson
d7948043bc
Bug 1171368 - Fix -Wunreachable-code-break warning in layout/style/nsCSSRuleProcessor.cpp. r=dholbert
2015-06-03 23:12:24 -07:00
Nicholas Nethercote
920bcd7199
Bug 1170416 (part 5) - Remove PLDHashTable::IsInitialized(). r=froydnj.
...
|mOps| is always non-null now, and there's no longer any distinction between
and uninitialized and initialized table. Yay.
2015-05-20 21:23:55 -07:00
Nicholas Nethercote
4500bfa831
Bug 1170416 (part 3) - Remove the PLDHashTable2 typedef. r=froydnj.
2015-05-19 16:46:17 -07:00
Nicholas Nethercote
0e6d634852
Bug 1166586 (part 2) - Convert some easy PL_DHashTable{Init,Finish} cases. r=froydnj.
...
This patch converts easy cases, i.e. where the PL_DHashTableInit() call occurs
in a constructor and the PL_DHashTableFinish() call occurs in a destructor.
2015-05-04 22:59:24 -07:00
Nicholas Nethercote
594f872fe6
Back out all four patches from bug 1161377. r=me.
...
Due to Android startup regressions (bug 1163066) and plugin crashes (bug
1165155).
2015-05-14 21:48:43 -07:00
Nicholas Nethercote
faab612820
Bug 1161377 (part 3, attempt 2) - Convert some easy PL_DHashTable{Init,Finish} cases. r=froydnj.
2015-05-12 17:33:26 -07:00
Nicholas Nethercote
31336c41f1
Backout c375efe78e07 (bug 1161377 part 3) for (probably) increasing the static constructor count and regressing Fennec start-up time. r=me.
2015-05-10 22:16:18 -07:00
Nicholas Nethercote
1c8a109619
Bug 1161377 (part 3) - Convert some easy PL_DHashTable{Init,Finish} cases. r=froydnj.
...
This patch converts easy cases, i.e. where the PL_DHashTableInit() call occurs
in a constructor and the PL_DHashTableFinish() call occurs in a destructor.
2015-05-04 22:59:24 -07:00
Nicholas Nethercote
1fac632e43
Bug 1129786 (part 1) - Instantiate RuleHash::m*Table eagerly. r=bz.
...
Now that empty PLDHashTables don't allocate any entry storage, we can undo the
lazification of RuleHash::m*Table from bug 700914.
2015-03-22 20:19:18 -07:00
Andrea Marchesini
2ce3453b15
Bug 1134280 - Get rid of Tag() - patch 2.12 - layout/style, layout/svg - Fix all the occurrences, m=smaug, r=surkov
2015-03-03 11:09:00 +00:00
Andrea Marchesini
6b10d5e43e
Bug 1134280 - Get rid of Tag() - patch 1 - Is{HTML,XUL,MathML,SVG}Element and IsAnyOf{HTML,XUL,MathML,SVG}Elements, r=smaug
2015-03-03 11:08:59 +00:00
Daniel Holbert
4fa02578fb
Bug 1135181: Remove unnecessary 'nsresult' return value from nsCSSRuleProcessor::Startup(), since it always succeeds. r=heycam
2015-02-20 22:31:09 -08:00
Nicholas Nethercote
3b0764a330
Bug 1131901 (part 1) - Make PL_DHashTableAdd() infallible by default, and add a fallible alternative. r=froydnj.
...
I kept all the existing PL_DHashTableAdd() calls fallible, in order to be
conservative, except for the ones in nsAtomTable.cpp which already were
followed immediately by an abort on failure.
2015-02-02 14:48:58 -08:00
Andrew McCreight
414d2fb22b
Bug 1131199, part 2 - Make PLDHashtInitEntry infallible. r=froydnj
...
Also, drop the unused table argument.
2015-02-11 09:46:40 -08:00
Nicholas Nethercote
1ce96de5ae
Back out changesets 2fcef6b54be7, 2be07829fefc, 66dfe37b8532, df3fcd2be8fd, 0a436bce77a6 (bug 1050035) for causing intermittent crashes and assertion failures.
2015-02-10 14:39:49 -08:00
Nicholas Nethercote
0247de46d8
Bug 1127201 (attempt 2, part 1) - Replace most NS_ABORT_IF_FALSE calls with MOZ_ASSERT. r=Waldo.
2015-02-09 14:34:50 -08:00
Andrew McCreight
e048a7df33
Back out Bug 1127201 (part 2) for various problems.
2015-02-06 15:04:32 -08:00
Nicholas Nethercote
40ab0270d5
Bug 1127201 (part 2) - Convert all NS_ABORT_IF_FALSE calls to MOZ_ASSERT. r=Waldo.
2015-02-04 20:05:36 -08:00
Nicholas Nethercote
a3bf151ee6
Bug 1050035 (part 4) - Make PL_DHashTableAdd() infallible by default, and add a fallible alternative. r=froydnj.
...
I kept all the existing PL_DHashTableAdd() calls fallible, in order to be
conservative, except for the ones in nsAtomTable.cpp which already were
followed immediately by an abort on failure.
2015-02-02 14:48:58 -08:00
Nicholas Nethercote
c38455902a
Bug 1124973 (part 2) - Introduce PL_DHashTableSearch(), and replace most PL_DHashTableLookup() calls with it. r=froydnj.
...
It feels safer to use a function with a new name, rather than just changing the
behaviour of the existing function.
For most of these cases the PL_DHashTableLookup() result was checked with
PL_DHASH_ENTRY_IS_{FREE,BUSY} so the conversion was easy. A few of them
preceded that check with a useless null check, but the intent of these was
still easy to determine.
I'll do the trickier ones in subsequent patches.
2015-01-22 21:06:55 -08:00
Masatoshi Kimura
90898b1eb4
Bug 1111290 - Part 3: Remove TypedEnum.h and fold TypedEnumInternal.h into TypedEnumBits.h. r=waldo
2015-01-26 07:22:11 +09:00
Masatoshi Kimura
4eacef39b7
Bug 1111290 - Part 1: Remove MOZ_(BEGIN|END)_ENUM_CLASS. r=waldo
2015-01-26 07:22:07 +09:00
Nicholas Nethercote
16fcb0d8bb
Bug 1123151 (part 3) - Make PLDHashTable::ops private. r=froydnj.
...
This required adding a getter and a setter, but they're used sparingly.
2015-01-19 16:34:44 -08:00
Nicholas Nethercote
4604f714c6
Bug 1123151 (part 2) - Add PLDHashTable::IsInitialized(). r=froydnj.
...
This encapsulates most of the uses of PLDHashTable::ops.
2015-01-19 16:11:34 -08:00
Nicholas Nethercote
009293c72a
Bug 1123151 (part 1) - Set PLDHashTable::ops consistently. r=froydnj.
...
Currently the setting of PLDHashTable::ops is very haphazard.
- PLDHashTable has no constructor, so it's not auto-nulled, so lots of places
null it themselves.
- In the fallible PLDHashTable::Init() function, if the entry storage
allocation fails we'll be left with a table that has |ops| set -- indicating
it's been initialized -- but has null entry storage. I'm not certain this can
cause problems but it feels unsafe, and some (but not all) callers of Init()
null it on failure.
- PLDHashTable does not null |ops| in Finish(), so some (but not all) callers
do this themselves.
This patch makes things simpler.
- It adds a constructor that zeroes |ops|.
- It modifies Init() so that it only sets |ops| once success is ensured.
- It zeroes |ops| in Finish().
- Finally, it removes all the now-unnecessary |ops| nulling done by the users
of PLDHashTable.
2015-01-19 16:01:24 -08:00
L. David Baron
b58f7f0e67
Bug 1089417 patch 10 - Make CloneMQCacheKey clone the mPreviousCacheKey, to fix bug 1089417 for multiple rebuilds of the rule cascade in sequence. r=heycam
...
I confirmed that this patch fixes the mochitest.
2015-01-19 00:49:56 -08:00
Nicholas Nethercote
d746138aca
Bug 1121304 (part 2, attempt 2) - Remove PLDHashTableOps::{alloc,free}Table. r=froydnj.
2015-01-14 14:35:56 -08:00
Phil Ringnalda
41e41579d9
Backed out 2 changesets (bug 1121304) for consistent b2g hangs in webgl-color-test.html?frame=1&__&preserve&premult&_____
...
Backed out changeset 20651ac19549 (bug 1121304)
Backed out changeset 758afec77c95 (bug 1121304)
2015-01-14 22:02:23 -08:00
Nicholas Nethercote
70f5bf6167
Bug 1121304 (part 2) - Remove PLDHashTableOps::{alloc,free}Table. r=froydnj.
2015-01-14 14:35:56 -08:00
Nicholas Nethercote
43fc26b699
Bug 1120476 (part 4) - Remove PLDHashTableOps::finalize. r=froydnj.
2015-01-13 19:02:35 -08:00
Nicholas Nethercote
eda870fe92
Bug 1120476 (part 3) - Remove PLDHashTable::data. r=froydnj.
2015-01-13 16:42:13 -08:00
Michael Pruett
cbe37abc44
Bug 1118024 - Use new PL_DHashTable{Add,Lookup,Remove} functions. r=nfroyd
2015-01-05 20:27:28 -06:00
L. David Baron
bf1f20686b
Bug 1089417 patch 8 - Only drop MediumFeaturesChanged on the floor if we've never computed style before, rather than never computed style using this rule processor. r=heycam
...
This depends on patches 4 and 7.
2014-12-05 15:50:01 -08:00
L. David Baron
33d7a61d85
Bug 1089417 patch 7 - Save the previous media query cache key on the rule processor. r=heycam
...
This depends on patches 5 and 6, and is needed for patch 8.
2014-12-05 15:50:00 -08:00
L. David Baron
57696e47bf
Bug 1089417 patch 6 - Pass the previous CSS rule processor to the constructor of the new one (when we replace one with another). r=heycam
...
This is needed for patch 7.
2014-12-05 15:50:00 -08:00
L. David Baron
ba3dfb48ef
Bug 1089417 patch 5 - Add method to save the current media query result cache key from a rule processor. r=heycam
...
This is needed for patch 7.
2014-12-05 15:50:00 -08:00
Wes Kocher
6d72488ca1
Backed out 8 changesets (bug 1089417) for b2g bustage possibly on a CLOSED TREE
...
Backed out changeset bf9f31312c1a (bug 1089417)
Backed out changeset babf33f8e077 (bug 1089417)
Backed out changeset 47b4f47d2e36 (bug 1089417)
Backed out changeset 11da22489a4f (bug 1089417)
Backed out changeset a39f32b2b2de (bug 1089417)
Backed out changeset fba9c331e036 (bug 1089417)
Backed out changeset b541a037f627 (bug 1089417)
Backed out changeset fc47a51b4f96 (bug 1089417)
2014-12-05 12:45:41 -08:00
L. David Baron
6c6c7f679d
Bug 1089417 patch 8 - Only drop MediumFeaturesChanged on the floor if we've never computed style before, rather than never computed style using this rule processor. r=heycam
...
This depends on patches 4 and 7.
2014-12-05 11:37:39 -08:00