Commit Graph

101 Commits

Author SHA1 Message Date
Emilio Cobos Álvarez
dc336a73ba Bug 1517241 - Rename nsIDocument to mozilla::dom::Document. r=smaug
Summary: Really sorry for the size of the patch. It's mostly automatic
s/nsIDocument/Document/ but I had to fix up in a bunch of places manually to
add the right namespacing and such.

Overall it's not a very interesting patch I think.

nsDocument.cpp turns into Document.cpp, nsIDocument.h into Document.h and
nsIDocumentInlines.h into DocumentInlines.h.

I also changed a bunch of nsCOMPtr usage to RefPtr, but not all of it.

While fixing up some of the bits I also removed some unneeded OwnerDoc() null
checks and such, but I didn't do anything riskier than that.
2019-01-03 17:48:33 +01:00
Sylvestre Ledru
e5a134f73a Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset
2018-11-30 11:46:48 +01:00
Emilio Cobos Álvarez
08bea7e24f Bug 1456471: Remove nsCSSParser.h. r=xidorn
MozReview-Commit-ID: 4qa7llzCXeR
2018-04-25 10:38:37 +02:00
Blake Kaplan
1e4512cee3 Bug 1391154 - Handle edge cases around the borders of IntersectionObservers more consistently. r=dholbert
The old code would ignore mThresholds if we happened to update when the
observed element was edge-adjacent to its root. This could cause spurious
notifications if it happened to run during a CSS transformation. The new code
more closely follows the spec with a slight deviation where the code treats
all values less than the smallest passed-in threshold as equivalent (when
looking at previousIndex). This matches Chrome's implementation and the tests.

MozReview-Commit-ID: 7oAh1EdjMiY
2018-04-10 18:54:01 -07:00
Xidorn Quan
b305ac227e Bug 1448763 part 1 - Make DOMIntersectionObserver use nsStyleSides for mRootMargin, and use Servo code to serialize it. r=emilio
MozReview-Commit-ID: 8RsoLflRtzE
2018-04-05 18:27:33 +10:00
Emilio Cobos Álvarez
c48b1f646b Bug 1448690: Remove IsStyledByServo. r=xidorn
MozReview-Commit-ID: I3MDbo2Yu7d
2018-03-26 09:39:26 +02:00
Emilio Cobos Álvarez
b1a35fbef7 Bug 1447358: Unifdef the old style system code. r=jwatt
Summary:
This has been automatically generated using:

  http://dotat.at/prog/unifdef/

And:

find $OBJDIR -type f -name '*.h' |
while read FILE; do
  echo "$FILE"
  unifdef -m -DMOZ_STYLO -UMOZ_OLD_STYLE "$FILE";
done

find $OBJDIR -type f -name '*.cpp' |
while read FILE; do
  echo "$FILE"
  unifdef -m -DMOZ_STYLO -UMOZ_OLD_STYLE "$FILE";
done

MozReview-Commit-ID: I4NdKqbMXzJ

Reviewers: jwatt

Bug #: 1447358

Differential Revision: https://phabricator.services.mozilla.com/D779
2018-03-21 10:20:34 +01:00
Dorel Luca
ee8e21ebda Backed out changeset 38577c007450 (bug 1424371) for Marionett test failure on testing/marionette/harness/marionette_harness/tests/unit/test_window_maximize.py. CLOSED TREE 2018-02-19 22:15:23 +02:00
Milan Sreckovic
2aa2530441 Bug 1424371: Use BaseRect access methods instead of member variables in dom/ r=qdot
MozReview-Commit-ID: HXWhggOMIEK
2018-02-19 12:56:10 -05:00
Cameron McCormack
02c617875f Bug 1430014 - Part 4: #ifdef out unnecessary code when the old style system is not built. r=xidorn
MozReview-Commit-ID: 1FZ9VzjcPzN
2018-02-01 15:04:04 +11:00
Olli Pettay
9f03b49e10 Bug 1422092 - Revert the changes made by bug 1399603. r=mrbkap 2017-12-10 14:52:49 -05:00
Cameron McCormack
c931762bf7 Bug 1408305 - Use Servo to parse IntersectionObserver rootMargin values. r=xidorn
MozReview-Commit-ID: 4CIXP73kcf2
2017-10-16 18:02:16 +08:00
Tobias Schneider
7750edf434 Bug 1406102 - [intersection-observer] Calculate areas using int64_t. r=dholbert 2017-10-09 15:08:41 -07:00
Tobias Schneider
7372e9b4b3 Bug 1399603 - [intersection-observer] Stop observing a target when intersection root is deleted. r=mrbkap 2017-10-06 07:39:54 -07:00
Tobias Schneider
3ef2e1983e Bug 1401416 - [intersection-observer] Let intersection rect be empty if do_QueryFrame(rootFrame) returns null. r=dholbert 2017-09-21 12:43:35 -07:00
Tobias Schneider
452c21fede Bug 1399605 - [intersection-observer] Check if target is actually being observed when unobserving. r=mrbkap 2017-09-19 10:50:10 -07:00
Milan Sreckovic
5e848ab767 Bug 1387514: Upgrade BaseRect (derived classes) width and height direct member variable use to instead use Width()/SetWidth() and Height()/SetHeight() in dom/*. r=overholt
MozReview-Commit-ID: B9YWmM3C1oX
2017-08-14 08:30:10 -04:00
Brad Werth
52b929d34a Bug 1383296 Part 1: Remove all uses of the nsCSSValue::Serialization enum, now that it no longer has multiple values. r=heycam
MozReview-Commit-ID: n6px5hNHtB
2017-07-21 17:26:35 -07:00
Tobias Schneider
bbf5037289 Bug 1366371 - Use signed integer for intersection threshold. r=mstange 2017-07-26 16:00:58 -07:00
Sylvestre Ledru
9d4a84d778 Bug 1378712 - Remove all trailing whitespaces r=Ehsan
MozReview-Commit-ID: Kdz2xtTF9EG
2017-07-06 14:00:35 +02:00
Tobias Schneider
86cafd6045 Bug 1359311 - (intersection-observer) Send update notifications in same order as observed. r=smaug 2017-06-25 19:35:21 -07:00
Tobias Schneider
9acab9a0c6 Bug 1363650 - (intersection-observer) Use content area as the intersection rectangle for custom root with overflow clip. r=mattwoodrow 2017-06-21 10:40:44 -07:00
Phil Ringnalda
b2ecb07c37 Backed out changeset eeb0a65afa6d (bug 1363650) for wpt failures in intersection-observer/bounding-box.html and intersection-observer/unclipped-root.html
MozReview-Commit-ID: HycwX8lA9sw
2017-06-20 20:50:08 -07:00
Tobias Schneider
6caca18e1e Bug 1363650 - (intersection-observer) Use content area as the intersection rectangle for custom root with overflow clip. r=mattwoodrow 2017-06-20 16:43:17 -07:00
Tobias Schneider
e46a2bee9e Bug 1359317 - (intersection-observer) Use targetFrame->GetRectRelativeToSelf() as the initial intersection rect. r=mstange 2017-06-19 13:32:07 -07:00
Mats Palmgren
a5b3e14375 Bug 1371925 - Remove unnecessary hashtable lookups in DOMIntersectionObserver. r=froydnj
MozReview-Commit-ID: LUt03nCz3SD
2017-06-17 00:06:04 +02:00
Tobias Schneider
53b184b817 Bug 1370968 - Guard against possible NULL values when IntersecionObserver API is used in XUL pages. r=mstange 2017-06-07 15:16:59 -07:00
Tobias Schneider
4b54676b9d Bug 1359318 - (intersection-observer) Map intersectionRect to the coordinate space of the target document. r=mstange 2017-06-02 14:11:31 -07:00
Tobias Schneider
1376830603 Bug 1359316 - (intersection-observer) Intersection ratio should be 1.0 for zero-area intersections. r=mstange 2017-05-17 12:19:07 -07:00
Tobias Schneider
9c44924b34 Bug 1358668 - (intersection-observer) Set rootBounds to an empty rectangle instead of null when not intersecting. r=mstange 2017-05-24 17:12:31 -07:00
Emilio Cobos Álvarez
3731858edf Bug 1360241: Devirtualize nsIFrame::GetType. r=heycam
MozReview-Commit-ID: 5Nzhyta5Hle
2017-04-30 17:30:08 +02:00
Tobias Schneider
86360ce36d Bug 1353529 - Crash when using IntersectionObserver in XUL pages. r=mstange
MozReview-Commit-ID: 9RBrnst4Wkb
2017-04-04 20:14:46 -07:00
Tobias Schneider
990b34224f Bug 1319137 - (intersection-observer) Add isIntersecting property to IntersectionObserverEntry r=mrbkap,mstange
MozReview-Commit-ID: GmwpD0FYWAa
2017-02-08 11:22:53 -08:00
Tobias Schneider
18718b4035 Bug 1337936 - (intersection-observer) Revise lifetime management. r=smaug
MozReview-Commit-ID: 4pzm00igBLR
2017-02-22 10:45:13 -08:00
Sebastian Hengst
71f8399713 Backed out changeset 5f93d62d9229 (bug 1337936) for asserting in crashtest 869038.html. r=backout 2017-02-22 14:06:26 +01:00
Tobias Schneider
6c083f71b2 Bug 1337936 - (intersection-observer) Revise lifetime management. r=smaug
MozReview-Commit-ID: AvdDJaRELXm
2017-02-21 03:13:39 -08:00
Tobias Schneider
cc7ce5802e Bug 1333580 - Properly unregister last unobserved target. r=mrbkap
MozReview-Commit-ID: FfPJFSXeT98
2017-01-24 14:11:34 -08:00
Olli Pettay
3898f7d882 Bug 1326507, remove NS_IMPL_CYCLE_COLLECTION_TRAVERSE_SCRIPT_OBJECTS, r=mccr8 2017-01-03 21:47:55 +02:00
Tobias Schneider
994270e1fe Bug 1324209 - Safely iterate over mIntersectionObservers in nsDocument::NotifyIntersectionObservers. r=mstange
MozReview-Commit-ID: DmtTUiCObHM
2016-12-21 11:36:41 -08:00
Tobias Schneider
39e291c2b7 Bug 1322717 - Disconnect/Unlink in the proper order to avoid crashes in mozilla::dom::DOMIntersectionObserver::UnlinkTarget. r=mrbkap 2016-12-08 18:54:07 -08:00
Carsten "Tomcat" Book
2ee161bf4e merge mozilla-inbound to mozilla-central a=merge 2016-11-24 16:41:59 +01:00
Tobias Schneider
2c02b64559 Bug 1315837 - Crash in mozilla::dom::Element::UpdateIntersectionObservation. r=mrbkap 2016-11-23 13:14:00 -05:00
Ting-Yu Lin
7e10b6ab51 Bug 1317588 Part 3 - Remove #define NS_SIDE_TOP/RIGHT/BOTTOM/LEFT. r=mats
This patch was written with the help of the following script. Also, manually
add mozilla qualifier to the enum values in nsStyleCoord.h, gfxRect.h, and
Types.h to make it build.

function rename() {
find .\
     -type f\
     ! -path "./obj*"\
     ! -path "./.git"\
     ! -path "./.hg"\
     \( -name "*.cpp" -or\
        -name "*.h" \)\
        -exec sed -i -e "s/$1/$2/g" "{}" \;
}

rename "NS_SIDE_TOP" "eSideTop"
rename "NS_SIDE_RIGHT" "eSideRight"
rename "NS_SIDE_BOTTOM" "eSideBottom"
rename "NS_SIDE_LEFT" "eSideLeft"

MozReview-Commit-ID: 9T0ORsqM6nP
2016-11-18 18:12:25 +08:00
Tobias Schneider
28ff83be24 Bug 1315837 - Crash in mozilla::dom::Element::UpdateIntersectionObservation. r=mrbkap 2016-11-15 15:49:00 +01:00
Carsten "Tomcat" Book
b2903208c2 Merge mozilla-central to inbound 2016-11-16 14:53:15 +01:00
Andi-Bogdan Postelnicu
6da3d00d99 Bug 1317241 - Converts for(...; ...; ...) loops to use the new range-based loops in C++11 in dom/. r=baku
MozReview-Commit-ID: ysMKgcL3YQ
2016-11-14 11:31:11 +02:00
Andrew McCreight
ec2ef51c68 Backed out changeset 63cafb0c2f0f (bug 1315837) for causing bug 1317415. 2016-11-15 07:59:24 -08:00
Tobias Schneider
d5718fccc9 Bug 1315837 - Fix crash in mozilla::dom::Element::UpdateIntersectionObservation. r=mrbkap 2016-11-09 09:10:00 -05:00
Tobias Schneider
0f9065592b Bug 1314027 - r=mstange 2016-11-02 00:25:10 -07:00
Tobias Schneider
622b691603 Bug 1314032 - Add null checks to fix crash in mozilla::dom::DOMIntersectionObserver::Update. r=mstange 2016-10-31 12:24:00 -04:00