Граф коммитов

3538 Коммитов

Автор SHA1 Сообщение Дата
Eugen Sawin b03149e8d0 Bug 1439013 - [1.2] Add isUserTriggered argument to nsILinkHandler and expose it as an internal load flag. r=smaug 2018-04-27 20:49:54 +02:00
Cosmin Sabou 68fdb6cf4f Merge inbound to mozilla-central. a=merge 2018-04-27 13:04:36 +03:00
Boris Zbarsky 1cbc813260 Bug 1455674 part 20. Get rid of nsIDOMElement. r=qdot 2018-04-26 23:37:34 -04:00
Boris Zbarsky 76ead58490 Bug 1455674 part 19. Get rid of JS uses of nsIDOMElement. r=qdot
In nsBlocklistService.js we know we're dealing with actual nodes, so .nodeType
checks should be fine.
2018-04-26 23:37:34 -04:00
Boris Zbarsky 25aa42d9a4 Bug 1455674 part 16. Remove most use of nsIDOMElement in dom. r=qdot 2018-04-26 23:37:34 -04:00
Boris Zbarsky 914f11a6d2 Bug 1455674 part 10. Remove nsIDOMElement use from remaining dom/ xpidl files. r=qdot 2018-04-26 23:36:10 -04:00
Boris Zbarsky ffa08d7425 Bug 1455674 part 9. Remove nsIDOMElement use from nsIFocusManager. r=qdot 2018-04-26 23:35:19 -04:00
Boris Zbarsky dd4506eee2 Bug 1457155. Rename various focus manager variables to make it clearer that they're Elements. r=mccr8 2018-04-26 15:28:31 -04:00
Boris Zbarsky 4773c6d1d9 Bug 1457156. Rename nsPIDOMWindow::mFocusedNode to reflect that it's an Element now. r=mccr8 2018-04-26 15:28:30 -04:00
shindli af700315a1 Backed out 2 changesets (bug 1457155, bug 1457156) for B failures in builds/worker/workspace/build/src/dom/html/HTMLObjectElement.cpp on a CLOSED TREE
Backed out changeset 8b2a6b54336c (bug 1457155)
Backed out changeset 4e267d999797 (bug 1457156)
2018-04-27 01:34:37 +03:00
Boris Zbarsky cb54ece0d5 Bug 1457156. Rename nsPIDOMWindow::mFocusedNode to reflect that it's an Element now. r=mccr8 2018-04-26 15:28:30 -04:00
Emilio Cobos Álvarez a1b2e5070a Bug 1455885: Inline and make document casts fatally assert. r=bz
For consistency with AsElement / AsContent / AsDocumentFragment, etc.

MozReview-Commit-ID: 8GSj8R9hLBe
2018-04-26 17:05:12 +02:00
Emilio Cobos Álvarez a00f507b72 Bug 1456435: Make UpdateStyleSheet less bool-happy. r=heycam
MozReview-Commit-ID: FlTD390lMhg
2018-04-26 16:43:52 +02:00
Boris Zbarsky dac6314cb8 Bug 1456588 part 2. Change nsIFocusManager::MoveFocus to take Element. r=enndeakin 2018-04-26 10:37:47 -04:00
Boris Zbarsky 8a0b50bea8 Bug 1456588 part 1. Change nsIFocusManager::SetFocus to take Element. r=enndeakin 2018-04-26 10:37:46 -04:00
Xidorn Quan 8af9d264aa Bug 1456364 part 1 - Reduce dependencies to nsCSSProps.h. r=emilio
So that hacking on this header can be less painful...

MozReview-Commit-ID: LmpMnF7q9RG
2018-04-26 16:24:30 +02:00
Emilio Cobos Álvarez 4cfead6d7f Bug 1457102: Avoid grabbing a reference to the pres context. r=heycam
Nothing from within CompatibilityModeChanged can kill it.

MozReview-Commit-ID: 386GiYBC6kF

--HG--
extra : rebase_source : ac93fb98dce07b04381cd5429cb1bc693c1fd07a
2018-04-26 16:10:10 +02:00
Emilio Cobos Álvarez c0e0be0ea9 Bug 1457102: Avoid all the work if the compat mode hasn't actually changed. r=heycam
In this case the stylist is marked dirty because a compat mode change. The
change just doesn't exist (NavQuirks -> NavQuirks).

So avoid the work in the first place.

MozReview-Commit-ID: lchKJECNkO

--HG--
extra : rebase_source : 421bd4147da5dfa83f8f82d05228175c70cf5615
2018-04-26 16:07:30 +02:00
Adrian Wielgosik b3c501adc4 Bug 1447389 - Remove nsIDOMNodeList. r=bz
MozReview-Commit-ID: 11szZP6dS6V

--HG--
extra : rebase_source : 9acfb352750e53d3b36684fa945a18e817c9b82e
2018-04-25 23:01:30 +02:00
Emilio Cobos Álvarez f8233b4454 Bug 1456471: Remove nsCSSParser.h. r=xidorn
MozReview-Commit-ID: 4qa7llzCXeR
2018-04-25 10:38:37 +02:00
Dragana Damjanovic d9148a8a51 Bug 1441246 - Move preload cod from nsStyleLinkElement to HTMLLinkElement. r=smaug
--HG--
extra : rebase_source : 01cb8b69aa1187abb83b36098d81df1d96c7d79c
2018-04-20 12:47:00 +03:00
Andrea Marchesini 3abafd2746 Bug 1454889 - Remove createObjectURL()'s MediaStream overload, r=valentin 2018-04-24 16:19:51 +02:00
Boris Zbarsky 36ff5f731b Bug 1456169 part 3. Remove the now-unnecessary nsITextControlElement::GetPreviewNode. r=emilio
MozReview-Commit-ID: 3goF5VXvQap
2018-04-24 02:17:18 -04:00
Boris Zbarsky f82660f831 Bug 1456169 part 2. Remove the now-unnecessary nsITextControlElement::GetPlaceholderNode. r=emilio
MozReview-Commit-ID: FcVbeHEwkMz
2018-04-24 02:17:17 -04:00
Boris Zbarsky ca622386bd Bug 1456169 part 1. Remove the now-unnecessary nsITextControlElement::GetRootEditorNode. r=emilio
MozReview-Commit-ID: 6DYEtQMTCRF
2018-04-24 02:17:17 -04:00
Chris Pearce b36acd0564 Bug 1453843 - Remove extraneous play promise reject. r=bryce
We already reject the play promises when we call Pause(), so this extra
reject is unnecessary.

MozReview-Commit-ID: 6LKw7hCwJPH

--HG--
extra : rebase_source : b75c147c2f475cf1ae4b4dddc3085c306f31d6e6
2018-04-20 17:54:08 +12:00
Chris Pearce 7b1b141797 Bug 1453843 - Ensure we fire "pause" event when rejecting play() promise. r=bryce
Bug 1435133 introduced a new path where we block autoplay and reject the play()
promise, but we didn't fire a "pause" event. This confuses YouTube's controls.

Additionally, even if we're not in a user generated event handler, we
unilaterally consider the media element blessed if execution reaches here:
https://searchfox.org/mozilla-central/rev/11a2ae294f50049e12515b5821f5a396d951aacb/dom/html/HTMLMediaElement.cpp#4110
We previously rejected before reaching here when not in a user generated event
handler, but now if play() is called before we've reached loadedmetadata, we
reject the promise if we're not in a non-event handler and bail out early, and
so we'll bless even if not in a user generated event handler. Meaning when we
do reach loadedmetadata, we think we were in a user generated event handler
when play() was originally called, and so we won't reject the play promise.

So this patch ensures we dispatch a "pause" event when we reject the play()
promise here. The WHATWG spec says we should do this when pausing anyway.

Note: calling our interal Pause() function when rejecting the play() promise
here breaks YouTube, as if we do that we fire a "timeupdate" event. So I opted
to manually code to fire the event here instead of just calling Pause()
everywhere we want to ensure we're paused.

MozReview-Commit-ID: 1snkiTnPGih

--HG--
extra : rebase_source : 2c5ca6c0ed7c2dff2fb971cd159cfdc12a8a227f
2018-04-20 17:53:37 +12:00
Masayuki Nakano 043e93a8ba Bug 1451672 - part 21: Refine TextEditor::TypedText() r=m_kato
According to existing comments, TextEditor::TypedText() and
HTMLEditor::TypedText() are intentional bottleneck to debug.  However, only
for that purpose, it and its internal methods are made virtual.  This really
doesn't make sense.

So, this patch creates TextEditor::OnInputText() for callers of TypedText()
with non-empty string, TextEditor::OnInputParagraphSeparator() for callers
of TypedText() with eTypeBreak (Enter key or insertParagraphSeparator),
HTMLEditor::OnInputLineBreak() for callers of TypedText() with eTypeBR
(Shift + Enter or insertLineBreak).  Additionally, this creates internal
non-virtual methods for XPCOM methods which are used as internal methods of
TypedText().  One is InsertTextAsAction() for nsIPlatintextEditor.insertText().
the other is InsertParagraphSeparator() for nsIPlaintextEditor.insertLineBreak().

Although those new methods are not have "WithTransaction" postfix, they must
be clearer they'll use transactions since user input and actions should be
undo-able.

MozReview-Commit-ID: AmOkMqovIKA

--HG--
extra : rebase_source : 9c0f4b25fa2a36ad2f3394f72eb290824c31d82a
2018-04-16 23:43:36 +09:00
Masayuki Nakano 80c2ea82ed Bug 1451672 - part 9: Create TextEditor::DeleteSelectionAsAction() as implementation of nsIEditor::DeleteSelection() r=m_kato
First, EditorBase::DeleteSelection() is never used since
TextEditor::DeleteSelection() overrides it but does not call it.  So, this patch
makes EditorBase::DeleteSelection() only returns NS_ERROR_NOT_IMPLEMENTED.

Next, EditorBase::DeleteSelectionImpl() actually removes content for
TextEditor::DeleteSelection().  So, it should be named as
DeleteSelectionWithTransaction().  However, it'll be done in the following
patch.  On the other hand, its callers are EditorBase::HandleKeyPressEvent()
and EditorBase::DeleteSelectionAndPrepareToCreateNode().  Fortunately, they
can be moved to TextEditor simply.  Therefore this patch moves the methods
to TextEditor for making related methods in a place.

Then, we can make the implementation of nsIEditor::TextEditor() as a non-virtual
method, TextEditor::DeleteSelectionAsAction().

MozReview-Commit-ID: KXFDhW3G9lA

--HG--
extra : rebase_source : 15986979279b2cae3b61cda1bf6bf3d9e4987f3f
2018-04-11 17:37:49 +09:00
Dorel Luca 65669dae30 Merge mozilla-inbound to mozilla-central. a=merge 2018-04-21 02:00:04 +03:00
Dorel Luca 644bf34f8b Backed out 8 changesets (bug 1453011, bug 1452981, bug 1146316) For xpcshell and mochitest failures on multiple files. CLOSED TREE
Backed out changeset 033299f27339 (bug 1453011)
Backed out changeset 4464997475c1 (bug 1453011)
Backed out changeset cae243fb2a3c (bug 1453011)
Backed out changeset adf56a83131b (bug 1453011)
Backed out changeset 80abe3305b24 (bug 1452981)
Backed out changeset 02178545f255 (bug 1452981)
Backed out changeset 719f7596c208 (bug 1146316)
Backed out changeset 1316c78daeb6 (bug 1146316)
2018-04-20 21:40:24 +03:00
Boris Zbarsky 0ba35d199f Bug 1455052 part 8. Stop using nsIDOMEvent in docshell and dom. r=masayuki
MozReview-Commit-ID: ASkuyN3xSwB
2018-04-20 12:55:30 -04:00
Masayuki Nakano 9000054fed Bug 1454945 - Get rid of nsIEditor.suppressDispatchingInputEvent since nobody uses it from JS r=m_kato
So, this patch replaces the setter with non-virtual method and removing the
getter since where is already non-virtual getter method.

MozReview-Commit-ID: Is19Yriz8t8

--HG--
extra : rebase_source : bb2f49f380ddb2e2f96e8690effd8d47d24ae0ae
2018-04-18 22:57:41 +09:00
Bobby Holley d4c76e366b Bug 1240225 - Make test not racey. r=emilio
Depending on the chunking and timing of the HTML parser, we may end up
firing onload on the image before the script tag is evaluated, leading
to an undefined onLoad (which is the intermittent failure in the test).

MozReview-Commit-ID: 78OAZan1xbC
2018-04-19 18:10:14 -07:00
Boris Zbarsky faa2ec447e Bug 1450421 part 1. Stop using nsIDOMDOMRequest in xpidl. r=qdot
MozReview-Commit-ID: LYGIRidVNW
2018-04-19 12:55:33 -04:00
Peter Van der Beken 79663afa7d Bug 1452981 - Remove qsObjectHelper. r=bz.
--HG--
extra : rebase_source : 931b915a05d026d826ceb5ec919c3909f9bae053
2018-03-01 09:01:00 +01:00
Boris Zbarsky a517e45add Bug 1452183 part 4. Remove nsIDOMDocumentFragment. r=mccr8 2018-04-17 21:13:03 -04:00
Nika Layzell 5e2e5fc993 Bug 1444991 - Part 5: Make some XPCOM methods more strongly typed, r=bz
This patch goes through and changes a bunch of places in our tree which mention
this bug to use the new feature, making the methods more strongly typed.

There are probably more places in tree which could be changed, but I didn't try
to find them.
2018-04-17 19:21:05 -04:00
Brindusan Cristian 25a0c6dc80 Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-04-17 13:09:40 +03:00
Brindusan Cristian 667fae7dc8 Merge inbound to mozilla-central. a=merge 2018-04-17 12:53:33 +03:00
Xidorn Quan fdb9d8b7d8 Bug 1454528 - Remove trailing underscore of float ident. r=heycam
MozReview-Commit-ID: DN7rQu3adSB

--HG--
extra : rebase_source : c0fb1df20a6612a96abb1e6a74fde61b6ee870f8
2018-04-17 11:07:57 +10:00
Chris Pearce 5328fa5cb9 Bug 1453176 - Add telemetry to report fulfilment of HTMLMediaElement.play(). r=bryce
We'd like to know the proportion of HTMLMediaElement.play() calls that are
rejected due to autoplay being blocked. There are also other conditions that
cause us to reject the promise returned by HTMLMediaElement.play(), so add
telemetry to report all the identifyable conditions under which play()
succeeds or fails.

MozReview-Commit-ID: AZ67WWXaowN

--HG--
extra : rebase_source : 4a164cb0b4fb7fb6944cd371c6e90dde021a4dc0
2018-04-13 20:28:39 +12:00
Nicholas Nethercote 51f2b494ea Bug 1448222 - Remove MediaPrefs. r=jya
This patch converts all the prefs in MediaPrefs to the new StaticPrefs system.

Note that the "media.wmf.skip-blacklist" pref was present in both MediaPrefs
and gfxPrefs. The copy in MediaPrefs was never used; this explains why this
patch does not add an entry for it to StaticPrefList.h.

Note also that the patch removes themedia.rust.mp4parser pref, because it's
unused.

MozReview-Commit-ID: IfHP37NbIjY

--HG--
extra : rebase_source : df84ea813b7c366d7be663c696891325610149c8
2018-03-20 09:48:56 +11:00
Jeff Walden 821db93ccc Bug 1453456 - Replace nsCRT::IsAscii{Alpha,Digit} with mfbt/TextUtils.h versions. r=froydnj
--HG--
extra : rebase_source : b31986c0e6828be79442cfb0cf369eb80c232139
2018-04-12 20:19:30 -07:00
Emilio Cobos Álvarez 9083c33e83 Bug 1453206: Fix IsInAnonymousSubtree to account for XBL in Shadow DOM. r=smaug
MozReview-Commit-ID: B2aYury8K7i
2018-04-14 11:59:06 +02:00
Andreea Pavel 4784e6b61b Backed out 2 changesets (bug 1453206) for crashtest failures on muliple files e.g. tests/reftest/tests/layout/base/crashtests/416107.xhtml on a CLOSED TREE
Backed out changeset 1844a120acda (bug 1453206)
Backed out changeset b12b7c5b8178 (bug 1453206)
2018-04-13 23:06:55 +03:00
Emilio Cobos Álvarez 1fe3a2d36a Bug 1453206: Fix IsInAnonymousSubtree to account for XBL in Shadow DOM. r=smaug
MozReview-Commit-ID: B2aYury8K7i
2018-04-13 21:05:48 +02:00
shindli 108a654fb8 Merge inbound to mozilla-central. a=merge 2018-04-12 02:45:34 +03:00
Andreea Pavel 29ba7b4974 Merge mozilla-central to mozilla-inbound. a=merge on a CLOSED TREE 2018-04-11 17:40:37 +03:00
Andreea Pavel 4114ad2cfc Merge mozilla-inbound to mozilla-central. a=merge 2018-04-11 17:36:09 +03:00