Commit Graph

352 Commits

Author SHA1 Message Date
Ehsan Akhgari
ba45de7747 Bug 1321903 - Refactor the timeout/interval management code out of nsGlobalWindow; r=bkelly
This code now lives in TimeoutManager.  Note that this is a transition
state, the Timeout list management code also needs to be refactored out
later.

In order to simplify the lifetime management of the new class, its
lifetime is equal to the lifetime of its containing nsGlobalWindow.  In
a few places where we need to dispatch runnables to do asynchronous work
on this object, we hold the containing window alive to guarantee safety.

This patch also removes a bit of dead code that was left over from the
code removed in bug 1281793. See:
https://hg.mozilla.org/mozilla-central/rev/0ac748f4d677#l1.63
2016-12-13 14:08:47 -05:00
Andrea Marchesini
e9eb01bb25 Bug 1321270 - Get rid of nsIWindowCreator2::PARENT_IS_LOADING_OR_RUNNING_TIMEOUT, r=smaug 2016-12-01 08:49:46 +01:00
Bill McCloskey
85fe8298e7 Bug 1320753 - Refactor for new event target idea (r=ehsan)
MozReview-Commit-ID: AyhemNqBedb
2016-11-30 18:01:59 -08:00
Carsten "Tomcat" Book
3e625cc406 Backed out changeset 7c0ca61c3552 (bug 1321270) for bustage 2016-11-30 16:46:25 +01:00
Andrea Marchesini
ad75482c53 Bug 1321270 - Get rid of nsIWindowCreator2::PARENT_IS_LOADING_OR_RUNNING_TIMEOUT, r=smaug 2016-11-30 16:26:27 +01:00
Ben Kelly
5d7c863dbe Bug 1300659 P2 Expose a ThrottledEventQueue on TabGroup and nsPIDOMWindow. r=smaug 2016-11-07 12:30:17 -08:00
Andreas Farre
95c440b772 Bug 1198381 - Move/rename nsTimeout to Timeout, r=smaug
MozReview-Commit-ID: 1WrH2ZbOuzj
2016-08-22 14:52:19 +02:00
Michael Layzell
beeb5c8509 Bug 1310778 - Move TabGroup and GetDocGroup accessors onto nsPIDOMWindow{Inner,Outer}, r=smaug
MozReview-Commit-ID: Hl0QVktr0Lw
2016-10-28 15:38:28 -04:00
Ben Kelly
3140345d73 Bug 1303167 P6 Rename new suspend and freeze methods to final names. r=smaug 2016-10-26 10:20:16 -07:00
Ben Kelly
10cbf7084c Bug 1303167 P3 Remove old window suspend and freeze methods. r=smaug 2016-10-26 10:20:15 -07:00
Ben Kelly
45fce3ebba Bug 1303167 P1 Add new window suspend and freeze methods. r=smaug
* * *
Bug 1303167 P1 Interdiff 001 Address review feedback
2016-10-26 10:20:15 -07:00
Carsten "Tomcat" Book
be05d6bf8b Backed out changeset 228cc133fe6b (bug 1198381) for causing increased number of hangs in navigate() in marionette tests 2016-10-25 12:34:22 +02:00
Andreas Farre
f291dc880c Bug 1198381 - Move/rename nsTimeout to Timeout, r=smaug
MozReview-Commit-ID: 1WrH2ZbOuzj
2016-08-22 14:52:19 +02:00
Boris Zbarsky
f869bdf12e Bug 1222516 part 2. Add a window API for opening a window passing through a boolean indicating that no opener should be set on the result. r=mconley 2016-10-20 16:52:38 -04:00
Boris Zbarsky
c955e0d4e5 Bug 1222516 part 1. Add a window API for opening a window with navigation and a given docshell loadinfo to use for the navigation. r=mconley
This will be used to pass through information like the triggering principal and
whatnot, as well as the boolean for not sending a referrer, for rel=noreferrer
links.
2016-10-20 16:52:38 -04:00
John Dai
3aaae2af88 Bug 1309140 - Rename CustomElementsRegistry to CustomElementRegistry. r=wchen, r=smaug
MozReview-Commit-ID: 3gYTaRVcV0y
2016-10-12 15:26:02 +08:00
Boris Zbarsky
04f9a09ee5 Bug 1269052 part 2. Add IsSecureContext on nsPIDOMWindowInner. r=bkelly 2016-10-10 15:09:00 -04:00
Andrea Marchesini
4156a8473d Bug 1306232 - Use NeedsSubjectPrincipal in Window, r=ehsan 2016-09-29 16:14:42 +02:00
Olli Pettay
138490da7f Bug 1303471 - TraceBlack (remote) TabChildGlobals, r=mccr8 2016-09-28 21:27:35 +03:00
Kearwood (Kip) Gilbert
f9fd286412 Bug 1250244 - Part 2: Remove old VR rendering paths,r=gw280
MozReview-Commit-ID: 8H7spQggI2w
2016-05-27 13:49:04 -07:00
Ben Tian
efda1d19e8 Bug 1262930 - Skip ShouldShowFocusRing check during TabChild::Init() if no inner window is available. r=khuey 2016-07-29 10:28:50 +08:00
John Dai
1b35d89ef0 Bug 1275833 - Add window.customElements and CustomElementsRegistry interface for custom element v1. r=smaug, wchen 2016-07-24 23:38:00 +02:00
John Dai
210b99c77b Bug 1275833 - Remove redundant trailing spaces. r=wchen 2016-07-21 23:39:00 +02:00
Wes Kocher
85efaf8531 Backed out changeset ca723ddedfe5 (bug 1262930) for being the likely cause of android m(3) crashes CLOSED TREE 2016-07-20 11:56:59 -07:00
Ben Tian
332e2714f6 Bug 1262930 - Remove "no inner window" warning during TabChild::Init() by skipping ShouldShowFocusRing check. r=khuey 2016-07-20 11:47:27 +08:00
Andrea Marchesini
87366df1f0 Bug 1279453 - Remove separate worker binding for ServiceWorkerRegistration API, r=bkelly 2016-06-12 16:26:51 +02:00
Jonathan Watt
9c5b8de022 Bug 1279451 - Remove a lot of unnecessary includes of nsAutoPtr.h. rs=sparky 2016-06-07 21:10:18 +01:00
Andrea Marchesini
7dcf0fcf39 Bug 1278838 - Remove separate worker binding for Performance API, r=smaug 2016-06-09 19:04:42 +02:00
Neil Deakin
43865e47a8 Bug 1174798, propagate keyboard indicator state down to child processes, r=smaug 2016-06-09 07:59:31 -04:00
Alastor Wu
14ade11bab Bug 1242874 - part2 : window's suspend attribute. r=baku, r=ehsan
MozReview-Commit-ID: 2GZMjsaQWHC
2016-05-03 09:51:22 +08:00
Carsten "Tomcat" Book
a146077edc Backed out changeset 50896498013c (bug 1242874) 2016-04-28 13:59:06 +02:00
Alastor Wu
786552d529 Bug 1242874 - part2 : window's suspend attribute. r=ehsan, r=baku
MozReview-Commit-ID: Jw3E8Jdb66J
2016-04-28 00:21:27 +08:00
Jonathan Watt
dd0f116f3e Bug 1267718 - Add a nsPIDOMWindow::GetScriptableParentOrNull method. r=bz
MozReview-Commit-ID: 9L33Wq0fBF6
2016-04-25 15:17:32 +01:00
Ben Kelly
bc83006e31 Bug 1266221 P1 Get devtools http service worker testing option from top window. r=bz 2016-04-21 16:26:42 -07:00
Alastor Wu
5ced857f90 Bug 1249579 - part2 : audio competing suspend/resume methods. r=snorp, baku.
MozReview-Commit-ID: EjNvKELCiAy
2016-04-18 18:48:41 +08:00
Boris Zbarsky
43973730c3 Bug 1254230 kinda-fix. Make sure to never send script errors with stacks attached to the console service if the associated windows have already had FreeInnerObjects called on them. r=bholley 2016-03-08 17:21:40 -05:00
Olli Pettay
32ac7373c3 Bug 1197901, ensure sensor events dispatching follows the becoming spec change, r=bz 2016-02-24 19:43:07 +02:00
Kyle Huey
27ea4f01b5 Bug 1245306: Devirtualize RefreshCompartmentPrincipal. r=smaug 2016-02-03 13:30:45 -08:00
Kyle Huey
71517d2bd3 Bug 1245185: Remove dead event handling code from nsPIDOMWindow<T>. r=smaug 2016-02-03 13:30:45 -08:00
Kyle Huey
993f3e360f Bug 1245182: Move a few event handling functions to nsPIDOMWindowInner. r=smaug 2016-02-03 13:30:45 -08:00
Kyle Huey
e95edb30a9 Bug 1241764: Replace nsPIDOMWindow with nsPIDOMWindowInner/Outer. r=mrbkap,smaug 2016-01-30 09:05:36 -08:00
Kyle Huey
8f1698c80c Bug 1241763: Don't fire dom-window-destroyed on outer windows. r=bz 2016-01-22 10:27:54 -08:00
Kearwood (Kip) Gilbert
2773eeacb8 Bug 1182048 - Part 2: Implement e10s support for WebVR,r=vlad 2015-09-17 14:23:13 -07:00
Ehsan Akhgari
42c5fc7bc4 Bug 1201127 - Return the same ServiceWorkerRegistration object from service worker APIs dealing with the same underlying registration object; r=jdm 2015-11-26 15:13:33 -05:00
Kyle Huey
8f8794e1c7 Bug 1216401: Eviscerate nsIDOMWindow, move still needed methods to nsPIDOMWindow. r=bz 2015-10-26 14:37:32 -07:00
William Chen
39c5f1512f Bug 920734 - Part 1: Implement window.orientation and window.onorientationchange. r=baku 2015-10-23 21:37:28 -07:00
Nathan Froyd
4e6d8f6705 Bug 1207245 - part 6 - rename nsRefPtr<T> to RefPtr<T>; r=ehsan; a=Tomcat
The bulk of this commit was generated with a script, executed at the top
level of a typical source code checkout.  The only non-machine-generated
part was modifying MFBT's moz.build to reflect the new naming.

CLOSED TREE makes big refactorings like this a piece of cake.

 # The main substitution.
find . -name '*.cpp' -o -name '*.cc' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    xargs perl -p -i -e '
 s/nsRefPtr\.h/RefPtr\.h/g; # handle includes
 s/nsRefPtr ?</RefPtr</g;   # handle declarations and variables
'

 # Handle a special friend declaration in gfx/layers/AtomicRefCountedWithFinalize.h.
perl -p -i -e 's/::nsRefPtr;/::RefPtr;/' gfx/layers/AtomicRefCountedWithFinalize.h

 # Handle nsRefPtr.h itself, a couple places that define constructors
 # from nsRefPtr, and code generators specially.  We do this here, rather
 # than indiscriminantly s/nsRefPtr/RefPtr/, because that would rename
 # things like nsRefPtrHashtable.
perl -p -i -e 's/nsRefPtr/RefPtr/g' \
     mfbt/nsRefPtr.h \
     xpcom/glue/nsCOMPtr.h \
     xpcom/base/OwningNonNull.h \
     ipc/ipdl/ipdl/lower.py \
     ipc/ipdl/ipdl/builtin.py \
     dom/bindings/Codegen.py \
     python/lldbutils/lldbutils/utils.py

 # In our indiscriminate substitution above, we renamed
 # nsRefPtrGetterAddRefs, the class behind getter_AddRefs.  Fix that up.
find . -name '*.cpp' -o -name '*.h' -o -name '*.idl' | \
    xargs perl -p -i -e 's/nsRefPtrGetterAddRefs/RefPtrGetterAddRefs/g'

if [ -d .git ]; then
    git mv mfbt/nsRefPtr.h mfbt/RefPtr.h
else
    hg mv mfbt/nsRefPtr.h mfbt/RefPtr.h
fi
2015-10-18 01:24:48 -04:00
Eddy Bruel
4744d0a8f3 Bug 1178721 - Implement SuspendWorkersForWindow;r=khuey 2015-10-07 12:20:59 +02:00
Xidorn Quan
c216739c03 Bug 1196163 part 3 - Derive value of window.fullScreen for content process from the sizemode of puppet widget. r=smaug 2015-08-29 11:12:41 +10:00
Masayuki Nakano
d36f87a852 Bug 895274 part.3 Make the enum of event messages a named enum IGNORE IDL r=smaug 2015-08-26 21:56:59 +09:00