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

3075 Коммитов

Автор SHA1 Сообщение Дата
Masayuki Nakano f8a317eb9a Bug 998941 - part 2-3: Create new constructors of DataTransfer to set only plain text or nsITransferable r=smaug
DataTransfer should have more 2 constructors.  One takes |const nsAString&| and
sets its data to the string.  The other takes |nsITransferable*| and stores only
its data with DataTransferItem.

If given data is external resource like the case of `HTMLEditor::PasteTransferable()`,
we should copy its data to each DataTransferItem because nsITransferable is not
cycle-collectable, but DataTransfer may be grabbed by JS.  Unfortunately, adding
new path to initialize DataTransfer with nsITransferable instance is too risky
because DataTransfer and DataTransferItem work together to initialize each of
them if DataTransfer is in external mode. Therefore, this patch makes the
new constructor temporarily sets it to in external mode, then, cache usable types
first, then, call `FillAllExternalData()` to  make each DataTransferItem initializes
its data by itself, finally, make the constructor set it to internal mode and release
nsITransferable instance.  This is ugly implementation but the most reasonable
way for now because:

- We don't need to change DataTransfer nor DataTransferItem a lot in this bug.
- We don't need to duplicate any code like a loop in `CacheExternalData()`.

In another bug, we should redesign DataTransfer and DataTransferItem to
make DataTransferable easier to be added new constructors.

Differential Revision: https://phabricator.services.mozilla.com/D19298

--HG--
extra : moz-landing-system : lando
2019-02-19 07:13:20 +00:00
Masayuki Nakano 6eadee9e6c Bug 998941 - part 2-1: Implement InputEvent.dataTransfer declared by Input Events r=smaug
InputEvent.dataTransfer is declared by Input Events Level 1 and Level 2 (i.e.,
not UI Events).  It's necessary for "beforeinput" event on contenteditable
elements because of with some InputEvent.inputType values on contenteditable,
InputEvent.dataTransfer is used instead of InputEvent.data.

According to the Chrome's behavior, if InputEvent.dataTransfer is created by
web apps, the DataTransfer object is mutable.  Otherwise, i.e., the event
represents user input, the DataTransfer object is read only.  We should follow
this behavior.

This is enabled by default.

Differential Revision: https://phabricator.services.mozilla.com/D19296

--HG--
extra : moz-landing-system : lando
2019-02-19 06:32:11 +00:00
Masayuki Nakano 0f145fc8e5 Bug 998941 - part 1-1: Implement InputEvent.data of UI Events r=smaug
InputEvent.data notifies web apps of inserting/inserted text with "beforeinput"
and "input" events.  So, this is important especially for "beforeinput" event
listeners.  That's the reason why we need to support this before implementing
"beforeinput" event.

This patch adds it into InputEvent and make it enabled by default.

Differential Revision: https://phabricator.services.mozilla.com/D19285

--HG--
extra : moz-landing-system : lando
2019-02-19 06:27:41 +00:00
Markus Stange 0b151b8c2b Bug 1500692 - Centralize profiling category definition and add infrastructure for subcategories. r=njn
The actual subcategories will be added in later patches, so that there are no
unused categories.

Differential Revision: https://phabricator.services.mozilla.com/D11334

--HG--
extra : moz-landing-system : lando
2019-02-16 17:37:43 +00:00
Kyle Machulis 2bb286e58e Bug 1524683 - Move all nsIFrameLoaderOwner references to nsFrameLoaderOwner; r=nika
Depends on D19728

Differential Revision: https://phabricator.services.mozilla.com/D19729

--HG--
extra : moz-landing-system : lando
2019-02-15 22:20:53 +00:00
Edgar Chen 14d6d67458 Bug 1323400 - Part 3-2: Add test; r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D19811

--HG--
extra : moz-landing-system : lando
2019-02-15 21:53:44 +00:00
Edgar Chen 652012afa9 Bug 1323400 - Part 3-1: Refactor test_multiple_touches.html; r=smaug
To make it easier to add new test without introudcing duplicated code.

Differential Revision: https://phabricator.services.mozilla.com/D19810

--HG--
extra : moz-landing-system : lando
2019-02-15 16:47:26 +00:00
Edgar Chen 408cdd3a53 Bug 1323400 - Part 2: Filter out duplicated touchmove for pointer event; r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D19804

--HG--
extra : moz-landing-system : lando
2019-02-15 22:04:13 +00:00
Edgar Chen 0518b15392 Bug 1323400 - Part 1: Mark Touch::Equals as a const method; r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D18232

--HG--
extra : moz-landing-system : lando
2019-02-15 16:28:35 +00:00
Sylvestre Ledru 41d1d79094 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D19663

--HG--
extra : moz-landing-system : lando
2019-02-15 08:15:57 +00:00
Joel Maher 2d1cf6ee1f Bug 1527369 - re-enable many tests on windows 1803 due to invalid screen resolution whilst testing. r=gbrown
re-enable many tests on windows 1803 due to invalid screen resolution whilst testing

Differential Revision: https://phabricator.services.mozilla.com/D19535

--HG--
extra : moz-landing-system : lando
2019-02-12 17:47:39 +00:00
Masayuki Nakano 0c300040e9 Bug 1506508 - Make PresShell::EventHandler::HandleEvent() flush any dirty region before deciding to event target of eMouseDown and eMouseUp r=smaug
When preceding mouse event is handled, that may cause changing style of the
target.  Therefore, when an eMouseDown or eMouseUp event is handled, handlers
require the latest layout.  Currently, nsViewManager::DispatchEvent() tries
to guarantee that with calling nsIPresShell::FlushPendingNotifications()
with FlushType::Layout.  However, this just flushes the pending layout in
the PresShell associated with the nsViewManager instance.  I.e., if the
target is in a child PresShell, its layout hasn't been flushed.

This patch makes PresShell::EventHandler::HandleEvent() flush pending
notifications at first of handling events using coordinates (only when
eMouseDown or eMouseUp, though).  Then, when it realizes that the event
should be handled in a child PresShell, makes it flush its pending
notifications and then, recompute event target with the latest layout if
the layout is actually changed.

Differential Revision: https://phabricator.services.mozilla.com/D13720

--HG--
extra : moz-landing-system : lando
2019-02-11 23:25:45 +00:00
Boris Zbarsky bc348929b6 Bug 1515582. Remove the separate XBL scope setup. r=bholley
With these changes, XBL just runs in the window scope of whatever document it's
attached to.  Since (outside of tests and "remote XUL") we no longer attach XBL
to web documents, this is fine.  And "remote XUL" already ran without the XBL
scope.

Native anonymous content, which used to be placed in the XBL scope to hide it
from the page, is now placed in the unprivileged junk scope, so it stays hidden
from the page.

dom/xbl/test/test_bug944407.xul is being removed because we are changing the
behavior it's trying to test for.  Since we now always put the XBL in the same
scope as the page, script is enabled for the XBL if and only if it's enabled for
the page.

dom/base/test/test_bug419527.xhtml, dom/events/test/test_bug391568.xhtml,
dom/xbl/test/test_bug1086996.xhtml are being switched to a chrome test because
otherwise the XBL can't see the getAnonymousNodes method.

All the XBL bits are being removed from test_interfaces because we no longer
have a separate XBL scope to test the behavior of.

js/xpconnect/tests/mochitest/test_nac.xhtml is being removed because XBL no
longer has access to NAC unless the page it's attached to does too, so the test
doesn't really make sense.

layout/xul/test/test_bug1197913.xul is being switched to a chrome test because
its XUL elements use bindings that rely on APIs that are not exposed to normal
web content.

layout/reftests/bugs/495385-2f.xhtml is being removed because I can't think of
a sane way to test that in the new world, short of running the reftest as
chrome.  And it doesn't seem worthwhile to look for a way to do that.

dom/xbl/test/test_bug1098628_throw_from_construct.xhtml now needs to
expectUncaughtException(), because the exception is now being thrown in Window
scope.

dom/xbl/test/test_bug1359859.xhtml needs to expectUncaughtException() as needed
and not use XPCNativeWrapper (which it doesn't need to anyway now).

dom/xbl/test/test_bug389322.xhtml, dom/xbl/test/test_bug400705.xhtml,
dom/xbl/test/test_bug401907.xhtml, dom/xbl/test/test_bug403162.xhtml,
dom/xbl/test/test_bug526178.xhtml, dom/xbl/test/test_bug639338.xhtml don't need
to use XPCNativeWrapper anymore.

dom/xbl/test/test_bug821850.html is being removed because it exists only to test XBL scopes.

dom/xbl/test/file_bug950909.xml is being changed to work without a separate XBL
scope (though whether the test still makes sense at that point is a bit questionable).

Differential Revision: https://phabricator.services.mozilla.com/D19260

--HG--
extra : moz-landing-system : lando
2019-02-11 21:51:47 +00:00
Joel Maher bdd8e3ce31 Bug 1522900 - adjust manifests to allow tests to pass on windows10 1803 release. r=gbrown CLOSED TREE
--HG--
extra : rebase_source : 1350412a9925eea526bda708011086c4e8e19170
extra : amend_source : 548af67b37ba2207f380c509a1b213c323fcd1cb
2019-02-11 10:02:51 +01:00
Xidorn Quan a55a8f3935 Bug 1524130 - Remove deprecation of attr modified event. r=smaug
It was added in bug 1461696 probably for tracking whether bug 1460295
is a wide-spread issue or so. This deprecation was already part of
deprecated mutation event, so it's never output to console. It was
added purely for getting telemetry.

Given that related issues are now fixed, we no longer needs this.

Differential Revision: https://phabricator.services.mozilla.com/D18935

--HG--
extra : moz-landing-system : lando
2019-02-07 14:21:08 +00:00
Emilio Cobos Álvarez d29cff7e18 Bug 1445844 - Add a pref to block large custom cursors outside of the viewport's bounds. r=smaug
And for now, start blocking custom cursors that are larger than 64 pixels.

I wish I knew how to add a test for this, but I tested manually using the
test-case from bug 1518189 with and without hidpi.

We always treat the cursor image size as CSS pixels (and upscale it to device
pixels in HiDPI). We have bugs to stop doing that though (bug 1425694).

Differential Revision: https://phabricator.services.mozilla.com/D18671

--HG--
extra : moz-landing-system : lando
2019-02-06 17:40:46 +00:00
Jon Coppeard 5e71f04dec Bug 1523899 - Dynamic import in event handlers should be relative to the document r=smaug 2019-02-06 11:07:29 +00:00
Narcis Beleuzu d77339d244 Backed out changeset 4f266277d3b8 (bug 1523899) for wpt failures on string-compilation-base-url-external-classic.html. CLOSED TREE 2019-02-06 14:37:25 +02:00
Jon Coppeard 207e74d173 Bug 1523899 - Dynamic import in event handlers should be relative to the document r=smaug 2019-02-06 11:07:29 +00:00
Masayuki Nakano 1895d1bfe3 Bug 1514940 - part 1: Forcibly disable new keyCode/charCode value of keypress events if the document is Confluence r=smaug,Ehsan,kmag
Old Confluence does not aware of conflated model keypress event (see UI Events
spec, https://w3c.github.io/uievents/#determine-keypress-keyCode).
Additionally, Confluence can be hosted with any domains.  Therefore, we cannot
use blacklist to disable the conflated model keypress event only on it.

This patch checks whether current or parent document is Confluence with JS
module, called KeyPressEventModelCheckerChild.  For kicking this module,
nsHTMLDocument dispatches an custom event, CheckKeyPressEventModel, when it
becomes editable only first time.  Finally, if it's a Confluence instance, the
module let PresShell know that we need to use split model keypress event in it.

Differential Revision: https://phabricator.services.mozilla.com/D17907

--HG--
extra : moz-landing-system : lando
2019-02-05 11:35:43 +00:00
Sylvestre Ledru 14486004b6 Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D18488

--HG--
extra : moz-landing-system : lando
2019-02-04 19:10:18 +00:00
Olli Pettay ba8719ae4a Bug 1523158 - try to make test_bug574663.html a tad more stable, r=kats
--HG--
extra : rebase_source : f456c2e45964937d2cfea11f6a97f8ae129cbf2f
2019-01-30 00:02:39 +02:00
garvitdelhi 6bd950c37a Bug 1519185: Remove AttributeWillChange aNewValue parameter r=emilio,bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D17073
2019-01-29 17:59:38 +01:00
Cosmin Sabou 6b126c3ff0 Backed out 2 changesets (bug 1519185) build bustages on nsMenuGroupOwnerX.mm. CLOSED TREE
Backed out changeset e1de5282e21a (bug 1519185)
Backed out changeset 00d8afb01890 (bug 1519185)

--HG--
extra : rebase_source : d92a7d4606992503f24c66093d35676e12a84ff0
2019-01-29 18:22:46 +02:00
garvitdelhi 3b6550b93f Bug 1519185: Remove AttributeWillChange aNewValue parameter r=emilio,bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D17073

--HG--
extra : moz-landing-system : lando
2019-01-29 15:27:02 +00:00
Sebastian Hengst 9ece29fd9b Merge mozilla-central to autoland. CLOSED TREE 2019-01-29 12:59:48 +02:00
Edgar Chen 56711d7e2b Bug 1521082 - Don't dispatch pointer event if the touch in touchstart event is already registered; r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D16976

--HG--
extra : moz-landing-system : lando
2019-01-29 09:08:05 +00:00
Emilio Cobos Álvarez ef7d8198eb Bug 1520502 - Set the standard cursor and the custom cursor in the same IPC message. r=jmathies
This cleans up a bit and allows us to be smarter about which cursors
should we allow from content or what not, which will help with bug 1445844 and
co.

Differential Revision: https://phabricator.services.mozilla.com/D16711
2019-01-26 07:49:28 +01:00
Kris Maglione e930b89c34 Bug 1514594: Part 3 - Change ChromeUtils.import API.
***
Bug 1514594: Part 3a - Change ChromeUtils.import to return an exports object; not pollute global. r=mccr8

This changes the behavior of ChromeUtils.import() to return an exports object,
rather than a module global, in all cases except when `null` is passed as a
second argument, and changes the default behavior not to pollute the global
scope with the module's exports. Thus, the following code written for the old
model:

  ChromeUtils.import("resource://gre/modules/Services.jsm");

is approximately the same as the following, in the new model:

  var {Services} = ChromeUtils.import("resource://gre/modules/Services.jsm");

Since the two behaviors are mutually incompatible, this patch will land with a
scripted rewrite to update all existing callers to use the new model rather
than the old.
***
Bug 1514594: Part 3b - Mass rewrite all JS code to use the new ChromeUtils.import API. rs=Gijs

This was done using the followng script:

https://bitbucket.org/kmaglione/m-c-rewrites/src/tip/processors/cu-import-exports.jsm
***
Bug 1514594: Part 3c - Update ESLint plugin for ChromeUtils.import API changes. r=Standard8

Differential Revision: https://phabricator.services.mozilla.com/D16747
***
Bug 1514594: Part 3d - Remove/fix hundreds of duplicate imports from sync tests. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16748
***
Bug 1514594: Part 3e - Remove no-op ChromeUtils.import() calls. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16749
***
Bug 1514594: Part 3f.1 - Cleanup various test corner cases after mass rewrite. r=Gijs
***
Bug 1514594: Part 3f.2 - Cleanup various non-test corner cases after mass rewrite. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D16750

--HG--
extra : rebase_source : 359574ee3064c90f33bf36c2ebe3159a24cc8895
extra : histedit_source : b93c8f42808b1599f9122d7842d2c0b3e656a594%2C64a3a4e3359dc889e2ab2b49461bab9e27fc10a7
2019-01-17 10:18:31 -08:00
Masayuki Nakano 96bd720118 Bug 1521396 - Make ClickHandlerChild prevent multiple action of middle click on link element for preventing middle click paste r=smaug
When user middle clicks a link, most users must not expect to expose clipboard
content to the web application.  Therefore, we should stop firing paste event
when user click a link with middle button.

This patch makes ClickHandlerChild.handleEvent() prevent multiple action
when it posts middle click event on a link.  Note that even if middle click
event is consumed, default event handler will dispatch paste event.
Unfortunately, this is compatible behavior with the other browsers.
Therefore, we cannot change this behavior with calling preventDefault() and
this is the reason why this patch adds Event.preventMultipleActions().

Out of scope of this bug though, if there is an element which looks like a
link but implemented with JS, web apps can steal clipboard content if user
enables middle click event and user just wants to open the link in new tab.
It might be better to stop dispatching paste event in any browsers and request
to change each web apps.

Differential Revision: https://phabricator.services.mozilla.com/D17209

--HG--
extra : moz-landing-system : lando
2019-01-22 07:28:55 +00:00
Cosmin Sabou 7ccc9d8b0b Merge mozilla-inbound to mozilla-central. a=merge 2019-01-19 11:57:49 +02:00
Greg Tatum 7042c8f1c3 Bug 1520526 - Add categories to all profiler markers; r=mstange
This commit adds categories to all markers. This way the profiler's
marker categories and frame label categories agree. There are a few
duplicate category properties on some of the marker payloads, but
this could be cleaned up in a follow-up if needed.

Differential Revision: https://phabricator.services.mozilla.com/D16864

--HG--
extra : moz-landing-system : lando
2019-01-18 15:40:15 +00:00
Emilio Cobos Álvarez b44ff327e9 Bug 1520154 - Move cursor to cbindgen. r=boris
The only reason it was on style_traits is so that they could use it from some
other crates, but Servo eventually ends up getting the value from an integer, so
may as well pass it around and do that in the end of the process anyway.

Differential Revision: https://phabricator.services.mozilla.com/D16557
2019-01-16 14:13:07 +01:00
Ehsan Akhgari e5e885ae31 Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre
# ignore-this-changeset

--HG--
extra : amend_source : 7221c8d15a765df71171099468e7c7faa648f37c
extra : histedit_source : a0cce6015636202bff09e35a13f72e03257a7695
2019-01-18 10:16:18 +01:00
Ehsan Akhgari 06c3d29113 Bug 1521000 - Part 1: Reformat the tree to ensure everything is formatted correctly with clang-format r=sylvestre
Summary: # ignore-this-changeset

Reviewers: sylvestre

Reviewed By: sylvestre

Subscribers: reviewbot, emilio, jandem, bbouvier, karlt, jya

Bug #: 1521000

Differential Revision: https://phabricator.services.mozilla.com/D16936

--HG--
extra : histedit_source : 4add583bfa729ccc1aef934629ed45ff095189b0
2019-01-18 10:12:56 +01:00
Brian Grinstead 7e9d440886 Bug 1519905 - Always return false in NodeAllowsClickThrough for browser elements;r=mstange
This prevents mouse events from firing on browsers in unfocused windows. It used to be done
with the [clickthrough=never] attribute set from XBL content.

Differential Revision: https://phabricator.services.mozilla.com/D16498

--HG--
extra : moz-landing-system : lando
2019-01-14 20:42:50 +00:00
Masayuki Nakano f421d7b889 Bug 181137 - part 8: Make ContentIteratorBase and its subclasses non-refcountable r=smaug
This patch makes ContentIteratorBase, PostContentIterator, PreContentIterator
and ContentSubtreeIterator classes non-refcountable because most users can
create their instances in stack and such users may be in a hot path.  So,
we can save a lot of cost of instantiation.

Unfortunately, only ScriptableContentIterator creates one of the concrete
classes and needs to destroy it properly.  Therefore, its
EnsureContentIterator(), destructor, traverse and unlink code becomes messy.
However, ScriptableContentIterator was designed for automated tests and we
need to maintain it not so many times.  Therefore, improvement of other
users must be worthwhiler than this demerit.

Differential Revision: https://phabricator.services.mozilla.com/D15928

--HG--
extra : moz-landing-system : lando
2019-01-11 01:52:26 +00:00
Masayuki Nakano da38fe53bc Bug 181137 - part 5: Make all users of PostContentIterator treat it directly rather than via nsIContentIterator r=smaug
Now, all users of PostContentIterator can access it directly.  This patch
makes them use the concrete class directly.

Differential Revision: https://phabricator.services.mozilla.com/D15923

--HG--
extra : moz-landing-system : lando
2019-01-11 01:50:19 +00:00
Masayuki Nakano f5602b96ab Bug 181137 - part 4: Make all users of PreContentIterator treat it directly rather than via nsIContentIterator r=smaug
Now, all users of PreContentIterator can access it directly.  This patch makes
them use the concrete class directly.

Differential Revision: https://phabricator.services.mozilla.com/D15922

--HG--
extra : moz-landing-system : lando
2019-01-11 01:49:36 +00:00
Masayuki Nakano 2d75b78552 Bug 181137 - part 1: Move nsContentIterator and nsContentSubtreeIterator into mozilla namespace r=smaug
First, we should move nsContentIterator and nsContentSubtreeIterator into
mozilla namespace and then, remove "ns" prefix.

Additionally, this patch separates the definition of the classes into
ContentIterator.h and exposes it as "mozilla/ContentIterator.h".  This allows
everybody access those concrete classes.

Differential Revision: https://phabricator.services.mozilla.com/D15917

--HG--
rename : dom/base/nsContentIterator.cpp => dom/base/ContentIterator.cpp
rename : dom/base/nsContentIterator.cpp => dom/base/ContentIterator.h
extra : moz-landing-system : lando
2019-01-11 01:47:15 +00:00
Andrew McCreight a3f7eb4598 Bug 1517577 - DataTransferItemList::Add should use nsVariantCC. r=nika
nsVariant isn't cycle collected, so this can cause a leak.

Differential Revision: https://phabricator.services.mozilla.com/D16124

--HG--
extra : moz-landing-system : lando
2019-01-10 19:23:43 +00:00
Csoregi Natalia 13506c036a Backed out 8 changesets (bug 181137) for bustage on FragmentOrElement.cpp:1751. CLOSED TREE
Backed out changeset 99a977d519a0 (bug 181137)
Backed out changeset 65a4b245e851 (bug 181137)
Backed out changeset 5385d5fd9b8b (bug 181137)
Backed out changeset 83bec02c21d9 (bug 181137)
Backed out changeset b7ab59bf545e (bug 181137)
Backed out changeset b6fc7a332db7 (bug 181137)
Backed out changeset 654fdbad67db (bug 181137)
Backed out changeset 90a1ff49b6b1 (bug 181137)

--HG--
rename : dom/base/ContentIterator.h => dom/base/nsContentIterator.cpp
rename : editor/spellchecker/FilteredContentIterator.cpp => editor/spellchecker/nsFilteredContentIterator.cpp
rename : editor/spellchecker/FilteredContentIterator.h => editor/spellchecker/nsFilteredContentIterator.h
2019-01-10 11:42:27 +02:00
Masayuki Nakano 796ceb094f Bug 181137 - part 8: Make ContentIteratorBase and its subclasses non-refcountable r=smaug
This patch makes ContentIteratorBase, PostContentIterator, PreContentIterator
and ContentSubtreeIterator classes non-refcountable because most users can
create their instances in stack and such users may be in a hot path.  So,
we can save a lot of cost of instantiation.

Unfortunately, only ScriptableContentIterator creates one of the concrete
classes and needs to destroy it properly.  Therefore, its
EnsureContentIterator(), destructor, traverse and unlink code becomes messy.
However, ScriptableContentIterator was designed for automated tests and we
need to maintain it not so many times.  Therefore, improvement of other
users must be worthwhiler than this demerit.

Differential Revision: https://phabricator.services.mozilla.com/D15928

--HG--
extra : moz-landing-system : lando
2019-01-10 08:50:41 +00:00
Masayuki Nakano bdc602b92f Bug 181137 - part 5: Make all users of PostContentIterator treat it directly rather than via nsIContentIterator r=smaug
Now, all users of PostContentIterator can access it directly.  This patch
makes them use the concrete class directly.

Differential Revision: https://phabricator.services.mozilla.com/D15923

--HG--
extra : moz-landing-system : lando
2019-01-10 08:46:32 +00:00
Masayuki Nakano 6f5a9fb98a Bug 181137 - part 4: Make all users of PreContentIterator treat it directly rather than via nsIContentIterator r=smaug
Now, all users of PreContentIterator can access it directly.  This patch makes
them use the concrete class directly.

Differential Revision: https://phabricator.services.mozilla.com/D15922

--HG--
extra : moz-landing-system : lando
2019-01-10 08:46:25 +00:00
Masayuki Nakano 8c30926700 Bug 181137 - part 1: Move nsContentIterator and nsContentSubtreeIterator into mozilla namespace r=smaug
First, we should move nsContentIterator and nsContentSubtreeIterator into
mozilla namespace and then, remove "ns" prefix.

Additionally, this patch separates the definition of the classes into
ContentIterator.h and exposes it as "mozilla/ContentIterator.h".  This allows
everybody access those concrete classes.

Differential Revision: https://phabricator.services.mozilla.com/D15917

--HG--
rename : dom/base/nsContentIterator.cpp => dom/base/ContentIterator.cpp
rename : dom/base/nsContentIterator.cpp => dom/base/ContentIterator.h
extra : moz-landing-system : lando
2019-01-10 08:43:50 +00:00
Daniel Varga 8306d673ed Merge mozilla-central to autoland. a=merge on a CLOSED TREE 2019-01-08 18:31:08 +02:00
Ryan VanderMeulen 262c894e52 Bug 1518478 - Re-enable some DOM Events mochitests which are now passing. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D15942

--HG--
extra : rebase_source : 991ba7bd144da3531c88f5a6ef1e815aced9a92b
2019-01-07 20:09:57 -05:00
Bas Schouten f532743510 Bug 1506537 - Part 1: Register KeyPress events with the LayerManager when painting is scheduled. r=smaug
--HG--
extra : rebase_source : 11ec887d6cdcdcb8333804aa524723e34d554b15
2018-12-13 03:32:18 +01:00
Masayuki Nakano ed2040ac16 Bug 1447239 - Implement InputEvent.inputType r=smaug
This patch implements InputType.inputType which is declared by Input Events.
The attribute has already been implemented by Chrome and Safari.  Chrome
implements Input Events Level 1, but Safari implements Input Events Level 2.
 Difference between them is only whether it supports "insertFromComposition",
"deleteByComposition" and "deleteCompositionText".  This patch makes the
level switchable with pref and takes Level 1 by default because Level 2 is
still unstable around event order with composition events.

For reducing string copy cost at dispatching "input" event, this patch
makes EditorInternalInputEvent store valid input-type as enum class,
EditorInputType and resolves it to string value when
dom::InputEvent::GetInputType() is called.  Note that the reason why
this patch names the enum class as EditorInputType is, there is InputType
enum class already for avoiding conflict the name, this appends "Editor"
prefix because "input" and "beforeinput" events are fired only when an
editor has focus.

Differential Revision: https://phabricator.services.mozilla.com/D14128

--HG--
extra : moz-landing-system : lando
2019-01-07 10:10:57 +00:00