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

2551 Коммитов

Автор SHA1 Сообщение Дата
Jessica Jong fbd3a63cba Bug 1409975 - Part 3: Fix event get-the-parent algorithm for a node. r=smaug 2017-12-04 16:06:40 +08:00
Chung-Sheng Fu 5b56656364 Bug 1037335 - Fix test failures. r=ckerschb,smaug
Require review from DOM peer.

MozReview-Commit-ID: HWBKKxxPh0e

--HG--
extra : rebase_source : be42de075010e79835b519e04a01c6e3f3c6ef8b
2017-11-29 16:54:00 +02:00
Olli Pettay af3373dc1d Bug 1418002 - Remove HTMLContentElement, r=jessica 2017-11-30 10:57:15 +02:00
Brindusan Cristian 9f3bd430c2 Merge inbound to mozilla-central a=merge r=merge 2017-11-28 11:50:57 +02:00
Stone Shih d6191b028f Bug 1400792 - Fire pointercancel when starting a dnd operation. r=smaug.
MozReview-Commit-ID: 4UTXpPHNqJ7
2017-09-18 18:41:36 +08:00
Nika Layzell f1ac9bf744 Bug 1419597 - Part 18: Remove IsInnerWindow and IsOuterWindow methods, r=smaug
MozReview-Commit-ID: DAAm6tLubhJ
2017-11-23 13:12:13 -05:00
Johann Hofmann d28b4dd837 Bug 1374574 - Remove the FlyWeb service and DOM interfaces. r=bz,djvj
MozReview-Commit-ID: 4hp9pLbMh4R

--HG--
extra : rebase_source : 82f417640211ede4fd7aa290c1f2609b07f38025
2017-11-22 15:00:10 +01:00
shindli 82254ca1cf Merge inbound to mozilla-central r=merge a=merge 2017-11-22 23:29:44 +02:00
James Willcox e1181af857 Bug 1409113 - Add nsIPresShell::HasHandledUserInput() status to InputContext r=masayuki
MozReview-Commit-ID: 60x35NKEzhA
2017-11-22 10:09:06 -06:00
Masayuki Nakano c4f2acf2f3 Bug 1405832 - part 2: TextComposition::RequestToCommit() should request IME to commit or cancel composition only when it hasn't been request it yet and hasn't received commit event yet r=m_kato
According to the log in crash reports, eCompositionCommitRequestHandled is
sent to ContentCacheInParent twice or more for a composition.  This causes
breaking mPendingCompositionCount and mPendingEventsNeedingAck management.

Currently, nsIWidget::NotifyIME() should be called only by
TextComposition::RequestToCommit().  Therefore, the method should manage if
it should request it actually.  If the composition has already received
eCompositionCommit(AsIs) event, it shouldn't request it because parent process
may have already stated new composition and it shouldn't be broken by request
for old composition.

MozReview-Commit-ID: 2ekSa6EIeRP

--HG--
extra : rebase_source : d23aa29ce7871e83b99cec8c15aff0c580e08fb4
2017-11-20 22:59:04 +09:00
Boris Zbarsky b5de3264a2 Bug 1379688 part 2. Make the EventTarget interface constructible. r=smaug
MozReview-Commit-ID: 4xrSSqXna7F
2017-11-20 13:59:22 -05:00
Jan de Mooij 7f30bf48a7 Bug 1417844 part 2 - Remove JSVersion from CompileOptions, CompartmentBehaviors, scripts. r=evilpie 2017-11-17 12:12:39 +01:00
Boris Zbarsky e8d2ef04ef Bug 691151. Remove Event.getPreventDefault. r=smaug
MozReview-Commit-ID: FQ3LzP7rW6e
2017-11-15 12:23:58 -05:00
Alastor Wu 00c469c134 Bug 1415444 - part1 : add flag to record whether the document has been activated by specific user gestures. r=smaug
This flag would be used to help us decide whether website could be allowed the autoplay.
The media related implementation would be implemented in bug1382574.

MozReview-Commit-ID: GGIauBufs5A

--HG--
extra : rebase_source : c407ceed311fc3fb0140e5da44fd69e457a5098f
2017-11-14 14:48:18 +08:00
Geoff Brown cbb956e0c3 Bug 1407679 - Merge nsIIOService and nsIIOService2; r=nwgh 2017-11-10 07:03:36 -07:00
Nika Layzell c223b9ff2d Bug 1414974 - Part 6: Change WebIDL bindings to refer to nsGlobalWindowInner rather than nsGlobalWindow, r=bz
MozReview-Commit-ID: KbCpDFoWyTe
2017-11-09 10:44:49 -05:00
Nika Layzell 3409141758 Bug 1414974 - Part 2: Switch many consumers to nsGlobalWindow{Inner,Outer}, r=smaug
This is a large patch which tries to switch many of the external consumers of
nsGlobalWindow to instead use the new Inner or Outer variants.

MozReview-Commit-ID: 99648Lm46T5
2017-11-09 10:44:47 -05:00
Andrea Marchesini 87a5947043 Bug 1415081 - part 8 - Fix the use of NS_ReadInputStreamToString in DataTransferItem, r=smaug 2017-11-09 11:18:09 +01:00
Mats Palmgren 1c2b8c222e Bug 1414666 part 1 - Add nsIFrame::PresShell() for convenient access to the shell. r=emilio
MozReview-Commit-ID: 8FPTPKWyVtY
2017-11-09 03:00:48 +01:00
Masayuki Nakano 93977460e2 Bug 1406446 - part 1: InputContextAction should treat focus change during handling a user input as caused by user input even if it's caused by JS r=smaug
Currently, widget doesn't show VKB when input context change is caused by JS.
However, if it's caused by an event handler of a user input, user may expect
to open VKB.  For example, if a touch event in fake editor causes moving
focus to actual editable node, user expect to show VKB.

Therefore, InputContextAction should declare two causes.  One is unknown but
occurred during handling non-keyboard event.  The other is unknown but occurred
during handling keyboard event.

However, EventStateManager doesn't have an API to check if it's being handling
a keyboard event.  Therefore, this patch adds it first.
AutoHandlingUserInputStatePusher sends event type to StartHandlingUserInput()
and StopHandlingUserInput() of EventStateManager and sUserKeyboardEventDepth
manages the number of nested keyboard event handling.  Therefore,
EventStateManager::IsHandlingKeyboardInput() can return if it's handling a
keyboard event.

IMEStateManager uses this new API to adjust the cause of changes of input
context.

Finally, InputContextAction::IsUserInput() is renamed to IsHandlingUserInput()
for consistency with EventStateManager and starts to return true when the
input context change is caused by script while it's handling a user input.

MozReview-Commit-ID: 5JsLqdqeGah

--HG--
extra : rebase_source : 9fcf7687d1bf90eeebbf6eac62d4488ff64b083c
2017-10-24 02:46:15 +09:00
Bevis Tseng 6115852e16 Bug 1409985 - Don't fire DOMEvent during StableState. r=smaug 2017-10-19 18:20:31 +08:00
Andrew McCreight 298aa82710 Bug 1412125, part 2 - Fix dom/ mode lines. r=qdot
This was automatically generated by the script modeline.py.

MozReview-Commit-ID: BgulzkGteAL

--HG--
extra : rebase_source : a4b9d16a4c06c4e85d7d85f485221b1e4ebdfede
2017-10-26 15:08:41 -07:00
Emilio Cobos Álvarez dd634e3981 Bug 1411612: Kill nsINode::eCONTENT. r=bz
MozReview-Commit-ID: ESlOqlwhcHI

--HG--
extra : rebase_source : fe6a02469dca1e50c24ba166e15e39160ab4551b
2017-10-25 17:19:11 +02:00
Sebastian Hengst 1ead0a96a9 Backed out changeset dab1c5badddb (bug 1407679) for failing server startup in mochitests on Android. r=backout on a CLOSED TREE
--HG--
extra : amend_source : 3dc4cb2bbaf55f3f6329687ce64d4e862fc3800b
2017-10-24 21:18:26 +02:00
Valentin Gosu 9dd47ebf50 Bug 1407679 - Merge nsIIOService and nsIIOService2 r=nwgh
Removes deprecated nsIIOService2.newChannelFromURIWithProxyFlags

MozReview-Commit-ID: Gr3nA25kcre

--HG--
extra : rebase_source : 3407b5ed0f8f7067523abee28c137db3cac86b14
2017-10-20 16:41:07 +02:00
Stone Shih 4274c680a7 Bug 1347689 Intermittent pointerevent_touch-action-button-test_touch-manual.html. r=kats.
The test case uses double intervals to make sure there is enough time to wait for the scroll event before continuing the testing. However, it doesn't work while the first timeout is delayed and the second one isn't. Tweaked the test case to start the second timer when the first one timeout.

MozReview-Commit-ID: gvhtIpzauE
2017-10-19 17:31:33 +08:00
Sebastian Hengst 364d36fab2 merge mozilla-inbound. r=merge a=merge
MozReview-Commit-ID: B09kHrHK42C
2017-10-23 23:50:37 +02:00
Nicholas Nethercote 3842370ed8 Bug 1405541 (attempt 2) - Split AUTO_PROFILER_LABEL_DYNAMIC into three macros. r=mstange.
It's easy to mess up the scoping so that (a) the label is pushed and then
immediately popped, and/or (b) the string doesn't live long enough. It's also
easy to do a utf16-to-utf8 conversion unnecessarily when the profiler is
inactive. This patch splits that macro into three new ones that are harder to
mess up.

- AUTO_PROFILER_LABEL_DYNAMIC_CSTR: same as current.
- AUTO_PROFILER_LABEL_DYNAMIC_NSCSTRING: for nsCStrings.
- AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING: for nsStrings.

--HG--
extra : rebase_source : 3e2bbec4737b696e1c86579ae54be4cb3186c100
2017-10-13 16:12:57 +11:00
Masatoshi Kimura dbd92543c6 Bug 1313150 - Remove |weak| parameter from nsIMutableArray methods. r=froydnj
MozReview-Commit-ID: 7JoD4VYzZp3

--HG--
extra : rebase_source : 5db437f1c34608aa223916874d62b48c59baeae8
2017-10-21 23:53:02 +09:00
Masayuki Nakano 16fd3a84a4 Bug 143038 Make users can scroll contents horizontally with vertical wheel operation with a modifier r=smaug
This patch declares a new default action, "horizontal scroll", this scrolls
content horizontally with deltaY of wheel events and ignores deltaX and deltaZ.
This is used for default action with Shift key in default setting except on
macOS. On macOS, legacy mouse's vertical wheel operation with Shift key causes
native horizontal wheel event.  Therefore, we don't need to use this new
default action on macOS.  Additionally, old default action with Shift key,
navigating history, is moved to with Alt key.  This makes same settings between
macOS and the others.  So, this is better for users who use macOS and another
OS and web app developers who check wheel events only on macOS or other
platform(s).

For simpler implementation, default action handlers moves deltaY values to
deltaX values temporarily *only* while they handle wheel events.  This is
performed by AutoWheelDeltaAdjuster and restored after handling it
automatically.

So, in other words, even if default action is "horizontal scroll", web apps
receives wheel events whose deltaY is not zero but its content will be
scrolled horizontally.  This is same as Chromium, so, this behavior shouldn't
cause any incompatible behavior with it.

MozReview-Commit-ID: E4X3yZzLEAl

--HG--
extra : rebase_source : e20d854c6b0a181ad4c9e7304bd9ad14256481ff
2017-10-05 01:12:35 +09:00
Brendan Dahl 42bc28d260 Bug 1399956 - Disable some mochitests in headless. r=jrmuizel
These tests will need more work and are low priority.

MozReview-Commit-ID: H0J16E8FqNr
2017-10-16 16:15:45 -07:00
Kris Maglione 60d080b412 Bug 1404198: Part 2i - Switch to NS_NewTimer* in dom. r=njn
MozReview-Commit-ID: 8Oei6TuXNbu

--HG--
extra : rebase_source : 31c583c699790cbcf302064146d313ee8126ef0c
2017-10-15 23:15:40 -07:00
Kris Maglione 3876d40960 Bug 1404198: Part 1 - Add non-virtual constructor for nsIObject(Input|Output)Stream and update existing callers. r=njn
MozReview-Commit-ID: 3eoh6AwDJyz

--HG--
extra : rebase_source : 92b18b6ef07d276cac79ce735ca0b592cffbf87e
2017-10-04 20:06:28 -07:00
Makoto Kato e1c9f1505d Bug 1407943 - IMEContentObserver should use Selection instead of nsISelectionPrivate. r=masayuki
We can use Selection directly instead of nsISelection.  It means that we don't need QI for nsISelectionPrivate.  So IMEContentObserver should hold Selection instead if nsISelection.

MozReview-Commit-ID: 4jp9wWHRHRd

--HG--
extra : rebase_source : 9f4792cf75555b5aafdacfd8f137e68d9da86e04
2017-10-12 18:11:09 +09:00
Sebastian Hengst 051f888cef Backed out changeset 759a43ebc6bf (bug 1405541) for asserting in devtools/client/performance/test/browser_perf-console-record-03.js on Windows 7. r=backout
--HG--
extra : amend_source : 3df3e75c561cbc42db104ec1a6f6026ef021e3c7
2017-10-11 13:15:26 +02:00
Nicholas Nethercote add7e65972 Bug 1405541 - Split AUTO_PROFILER_LABEL_DYNAMIC into three macros. r=mstange.
It's easy to mess up the scoping so that (a) the label is pushed and then
immediately popped, and/or (b) the string doesn't live long enough. It's also
easy to do a utf16-to-utf8 conversion unnecessarily when the profiler is
inactive.

This patch splits that macro into three new ones that are harder to mess up.

- AUTO_PROFILER_LABEL_DYNAMIC_CSTR: same as current.
- AUTO_PROFILER_LABEL_DYNAMIC_NSCSTRING: for nsCStrings.
- AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING: for nsStrings.

--HG--
extra : rebase_source : 53c8b43b6a1be06d00618a133e28bf95c46a3ba3
2017-10-11 13:03:34 +02:00
Phil Ringnalda bd5ca8f40d Backed out changeset 901a16fec9fc (bug 1405541) for Windows assertion failures
MozReview-Commit-ID: DRGWXU4Tbfk
2017-10-10 23:28:33 -07:00
Nicholas Nethercote b23fb68ae3 Bug 1405541 - Split AUTO_PROFILER_LABEL_DYNAMIC into three macros. r=mstange.
It's easy to mess up the scoping so that (a) the label is pushed and then
immediately popped, and/or (b) the string doesn't live long enough. It's also
easy to do a utf16-to-utf8 conversion unnecessarily when the profiler is
inactive.

This patch splits that macro into three new ones that are harder to mess up.

- AUTO_PROFILER_LABEL_DYNAMIC_CSTR: same as current.
- AUTO_PROFILER_LABEL_DYNAMIC_NSCSTRING: for nsCStrings.
- AUTO_PROFILER_LABEL_DYNAMIC_LOSSY_NSSTRING: for nsStrings.

--HG--
extra : rebase_source : 59f77df0124249bfd11fee3585420a17b4201d37
2017-10-04 13:44:24 +11:00
Stone Shih 163ae96bee Bug 1400143 - [Pointer Event] Update pointerevent's mLastRefPoint to get correct movementX/movementY values. r=smaug.
Add pointermove handling in UpdateLastRefPointOfMouseEvent to update mLastRefPoint of pointermove events.

MozReview-Commit-ID: DC7HyKsLE8y
2017-09-15 13:51:10 +08:00
Stone Shih c93aae82ac Bug 1375146 - Revise sending drag event. r=smaug 2017-09-19 15:41:52 +08:00
Sebastian Hengst aa78440a09 merge mozilla-inbound to mozilla-central. r=merge a=merge
MozReview-Commit-ID: EE6DcCgHufi
2017-10-09 11:19:20 +02:00
Nicholas Nethercote 8a68e6fb83 Bug 1403868 (part 4) - Reduce tools/profiler/public/*.h to almost nothing in non-MOZ_GECKO_PROFILER builds. r=mstange.
Currently the Gecko Profiler defines a moderate amount of stuff when
MOZ_GECKO_PROFILER is undefined. It also #includes various headers, including
JS ones. This is making it difficult to separate Gecko's media stack for
inclusion in Servo.

This patch greatly simplifies how things are exposed. The starting point is:

- GeckoProfiler.h can be #included unconditionally;

- everything else from the profiler must be guarded by MOZ_GECKO_PROFILER.

In practice this introduces way too many #ifdefs, so the patch loosens it by
adding no-op macros for a number of the most common operations.

The net result is that #ifdefs and macros are used a bit more, but almost
nothing is exposed in non-MOZ_GECKO_PROFILER builds (including
ProfilerMarkerPayload.h and GeckoProfiler.h), and understanding what is exposed
is much simpler than before.

Note also that in BHR, ThreadStackHelper is now entirely absent in
non-MOZ_GECKO_PROFILER builds.
2017-10-04 09:11:18 +11:00
Stone Shih 65989090f1 Bug 1405909 - disable test_pointerevent_pointerlock_supercedes_capture-manual.html. r=smaug.
MozReview-Commit-ID: Gus0UQSlJFE
2017-10-06 10:01:39 +08:00
Sebastian Hengst e7f32cc32f Backed out changeset c608c6fd9a9a (bug 1400143) for failing mochitest dom/events/test/pointerevents/pointerlock/test_pointerevent_pointerlock_supercedes_capture-manual.html on Windows 7 without e10s. r=backout 2017-10-08 11:53:23 +02:00
Nicholas Nethercote d225f7151b Bug 1400460 - Rename nsIAtom as nsAtom. r=hiro.
(Path is actually r=froydnj.)

Bug 1400459 devirtualized nsIAtom so that it is no longer a subclass of
nsISupports. This means that nsAtom is now a better name for it than nsIAtom.

MozReview-Commit-ID: 91U22X2NydP

--HG--
rename : xpcom/ds/nsIAtom.h => xpcom/ds/nsAtom.h
extra : rebase_source : ac3e904a21b8b48e74534fff964f1623ee937c67
2017-10-03 09:05:19 +11:00
Stone Shih 0e0138ce5b Bug 1400143 - [Pointer Event] Update pointerevent's mLastRefPoint to get correct movementX/movementY values. r=smaug.
Add pointermove handling in UpdateLastRefPointOfMouseEvent to update mLastRefPoint of pointermove events.

MozReview-Commit-ID: DC7HyKsLE8y
2017-09-15 13:51:10 +08:00
Stone Shih 6abd59db95 Bug 1404921 - Set movementX/Y to zero for all mouse events except mousemove. r=smaug.
MozReview-Commit-ID: 6BG9oBG2Mjb
2017-09-18 15:17:00 +08:00
Stone Shih 1256250b3f Bug 1404896 - Separate the pointer lock implementations from GenerateMouseEnterExit to new functions. r=smaug.
So that it's easier to reuse the implementation for handling pointer events.

MozReview-Commit-ID: LIZoPjuq9ji
2017-09-18 15:07:41 +08:00
Sebastian Hengst b834f0d177 merge autoland to mozilla-central. r=merge a=merge
MozReview-Commit-ID: 7Ez95T2ivfR
2017-10-07 10:37:39 +02:00
Stone Shih c0799cfa99 Bug 1404255 - [Pointer Event] Turn off active state or remove current pointer from active pointers when handling pointercancel. r=masayuki
MozReview-Commit-ID: 60FEfcvtxRd

--HG--
extra : rebase_source : 51382328396fab12e8deb4c01968e8594753dbc3
2017-09-29 17:03:48 +08:00
Wes Kocher d8985b6e57 Merge inbound to central, a=merge
MozReview-Commit-ID: IUFdbLdYFhX
2017-10-04 16:37:59 -07:00
Masayuki Nakano 093d53d74b Bug 1404206 - Part 1: Smart Location Bar should have special inputmode value, mozAwesomebar. r=smaug, r=gijs
Smart Location Bar (a.k.a URL bar) has some features, loading inputted URL
directly, searching bookmark items and history items, and search inputted words
with registered search engine.

So, it does not make sense its inputmode is "url".  E.g., neither showing URL
specific software keyboard nor switching IME open state automatically for
typing URL may not be expected in most cases.

Unfortunately, there is no proper inputmode value for Smart Location Bar.
Therefore, this patch uses "mozAwesomebar" value and accepts the value only in
chrome documents.  This value should be handled by each native IME handler
properly.

MozReview-Commit-ID: 7vUnbpg91F2
2017-09-29 14:44:06 +09:00
Stone Shih dcc75d78ac Bug 1399740 - [Pointer Event] Handle the case that invokes setPointerCapture while the page has a locked element. r=smaug.
Spec says we should throw an exception when setting pointer capture while the page has a locked element. Also, we should release all pointer capture when a pointer lock is successfully applied on an element.

MozReview-Commit-ID: CuUIPipJWB0
2017-09-14 14:29:04 +08:00
Catalin Badea f8162c4bfd Bug 651120 - Remove index argument from content removed/appended/inserted notifications. r=peterv 2017-10-03 11:09:08 +01:00
Stone Shih 3e1919eba7 Bug 1403055 Part2: Add a test to make sure we fire pointerout and pointerleave before pointercancel. r=masayuki
MozReview-Commit-ID: H9ripAT5E2c
2017-10-03 10:18:41 +08:00
Stone Shih db10708428 Bug 1403055 Part1: Revise the implementation to fire boundary events by handling pointercancel and pointerup. r=masayuki
We don't need to call GenerateMouseEnterExit twice when handling pointercancel. The second one is redundant since we do some checks in GenerateMouseEnterExit. And we should call GenerateMouseEnterExit before removing the entry in mPointersEnterLeaveHelper, which is used in GenerateMouseEnterExit.

MozReview-Commit-ID: 844bIFkPYfj
2017-09-26 12:02:34 +08:00
Cameron McCormack 0b7960f23a Bug 1397626 - Part 3: Use SharedFontList to store font-family specified and computed values. r=xidorn
MozReview-Commit-ID: J3MNO2un2ov

--HG--
extra : rebase_source : 737943aea3d383669a7103d4e23f109889c09034
2017-10-03 12:27:45 +08:00
Jan Henning 4c9e5899c5 Bug 1398374 - Part 2 - Send an IME actionHint other than "next" for the last input element of a form. r=masayuki
Some pages might use neither a default submit element nor rely on implicit submission and instead implement their form handling with JS key event listeners.

On Android, most IMEs won't allow sending an "Enter" key press if we're using an actionHint of "next" as our default, so we now use "go"/"search" for the last single line text/number input that is not disabled.

MozReview-Commit-ID: ACC15OYtcTF

--HG--
extra : rebase_source : 5ee608ea576e31ca320c93631bdb5e25716d9199
2017-09-30 21:38:04 +02:00
Olli Pettay 478b3b1343 Bug 1405821 - Move microtask handling to CycleCollectedJSContext, r=baku 2017-10-05 18:34:12 +03:00
Nika Layzell c62dc4b532 Bug 1399626 - Part 5: Update ContentEventHandler to use the new nsIContentIterator::Init overload when possible, r=masayuki
MozReview-Commit-ID: 2Zk8zTs58hu
2017-10-02 11:58:00 -04:00
Markus Stange 488f43bd92 Bug 1402498 - Rename AsyncScrollBase to ScrollAnimationPhysics and use composition instead of inheritance. r=rhunt
MozReview-Commit-ID: 7UFf0mZsrEr

--HG--
rename : layout/generic/AsyncScrollBase.cpp => layout/generic/ScrollAnimationPhysics.cpp
rename : layout/generic/AsyncScrollBase.h => layout/generic/ScrollAnimationPhysics.h
extra : rebase_source : 66cc26ef54b31d5cfe498d8f23bc678862423aa5
2017-09-22 13:42:29 -04:00
Sebastian Hengst 5a95ac34b4 merge mozilla-central to autoland. r=merge a=merge 2017-09-29 11:49:46 +02:00
Masayuki Nakano 7f281b641d Bug 1403026 - Make IMEStateManager release all string buffer of its static members at XPCOM shutdown r=smaug
IMEStateManager has a static instance of InputContext which has some nsString
instances.  Then, their members will be released after XPCOM shutdown and
that is detected as unexpected destruction.

Therefore, IMEStateManager should release them by itself at XPCOM shutdown.
Using nsTSubstring::SetCapacity(0) is the simplest way to release only the
string buffers.

MozReview-Commit-ID: LMrQxQF9xPn

--HG--
extra : rebase_source : 7cbaf19b76be8db083c10270d0ee436a1c061ea2
2017-09-28 17:31:29 +09:00
Stone Shih e628cf64e9 Bug 1316251 Part3: Trigger pointer event implementation in EventStateManager. r=masayuki
To manage pointer event "state" in ESM.

MozReview-Commit-ID: HiAwvSmVTwx
2017-09-08 11:01:22 +08:00
Stone Shih 9ea2b881c8 Bug 1316251 Part2: Revise pointer event implementation. r=masayuki
Revise the pointer event implementation, includes
- Revise the implementation to fetch preference values.
- Separate the logic to get the pointer capturing frame to PointerEventHandler.

MozReview-Commit-ID: 7pdAr0XFNT2
2017-09-06 17:28:28 +08:00
Stone Shih a1d26ab3b4 Bug 1316251 Part1: Separate pointer event implementation from PresShell. r=masayuki
This patch moves pointer event related implementations to a new class.

MozReview-Commit-ID: FdBYl7vYC5I
2017-09-06 15:47:49 +08:00
Stone Shih 6cbc21aa58 Bug 1355497: Ignore preventDefault on pointerdown by WebExtensions. r=smaug.
Prevent default on pointerdown will stop firing the subsequent mouse events. Ignore the case that preventDefault by WebExtensions to avoid breaking some websites.

MozReview-Commit-ID: 9ztW1WfEg9a
2017-07-10 16:42:01 +08:00
Nicholas Nethercote dfd3b7e7aa Bug 1400459 (part 2) - Devirtualize nsIAtom. r=heycam.
This patch merges nsAtom into nsIAtom. For the moment, both names can be used
interchangeably due to a typedef. The patch also devirtualizes nsIAtom, by
making it not inherit from nsISupports, removing NS_DECL_NSIATOM, and dropping
the use of NS_IMETHOD_. It also removes nsIAtom's IIDs.

These changes trigger knock-on changes throughout the codebase, changing the
types of lots of things as follows.

- nsCOMPtr<nsIAtom> --> RefPtr<nsIAtom>

- nsCOMArray<nsIAtom> --> nsTArray<RefPtr<nsIAtom>>
  - Count() --> Length()
  - ObjectAt() --> ElementAt()
  - AppendObject() --> AppendElement()
  - RemoveObjectAt() --> RemoveElementAt()

- ns*Hashtable<nsISupportsHashKey, ...> -->
  ns*Hashtable<nsRefPtrHashKey<nsIAtom>, ...>

- nsInterfaceHashtable<T, nsIAtom> --> nsRefPtrHashtable<T, nsIAtom>
  - This requires adding a Get() method to nsRefPtrHashtable that it lacks but
    nsInterfaceHashtable has.

- nsCOMPtr<nsIMutableArray> --> nsTArray<RefPtr<nsIAtom>>
  - nsArrayBase::Create() --> nsTArray()
  - GetLength() --> Length()
  - do_QueryElementAt() --> operator[]

The patch also has some changes to Rust code that manipulates nsIAtom.

MozReview-Commit-ID: DykOl8aEnUJ

--HG--
extra : rebase_source : 254404e318e94b4c93ec8d4081ff0f0fda8aa7d1
2017-09-26 08:33:21 +10:00
Nicholas Nethercote 49963dad55 Bug 1402772 - Change nsIEventListenerChange::changedListenerNames to a count of a11y-affecting elements. r=smaug.
nsIEventListenerChange::changedListenerNames is an nsIArray attribute that
contains nsIAtoms. Bug 1396693 made it `noscript` to help with nsIAtom
deCOMtamination (bug 1392883) but more changes are needed: that array
eventually needs to be changed to nsTArray<RefPtr<nsIAtom>>.

Turns out the attribute has a single use, in a11y code. That code merely
iterates over the list and counts how many atoms it contains that match
"onclick", "onmousedown", and "onmouseup".

So this patch moves that counting functionality inside nsEventListenerChange by
changing the attribute to `countOfEventListenerChangesAffectingAccessibility`.
This saves us from having to expose the array of atoms via XPIDL.

--HG--
extra : rebase_source : db8b628998d45209ab724555a74efe90f431d3ae
2017-09-25 16:38:04 +10:00
Michael Layzell 615d87dfaf Bug 1384915 - Part 4: Update RawRange to use RangeBoundaries, r=masayuki 2017-09-25 18:14:43 -04:00
Michael Layzell 74e8b70a80 Bug 1384915 - Part 3: Avoid using node indices in IMEContentObserver, r=masayuki
MozReview-Commit-ID: 4iaNideXEFl
2017-09-25 18:14:42 -04:00
Michael Layzell 9601431bf2 Bug 1384915 - Part 2: Make NodePosition a wrapper around RangeBoundary, r=masayuki 2017-09-25 18:14:42 -04:00
Ryan VanderMeulen 145892ce27 Bug 1400586 - Skip dom/events/test/test_bug607464.html on e10s runs across all platforms. 2017-09-25 09:02:21 -04:00
Boris Zbarsky 600cbb309f Bug 1401848. Remove NS_IMPL_EVENT_HANDLER and its consumers. r=smaug
All of the objects these event handlers hang off of use webidl bindings now.

MozReview-Commit-ID: 3OdVDlcU67I
2017-09-22 18:07:05 -04:00
Stone Shih 580c8e42f6 Bug 1344108 Part3: Enable pointerevent_sequence_at_implicit_release_on_drag-manual.html. r=smaug.
MozReview-Commit-ID: AsMJc5Hpu3X
2017-02-09 17:01:03 +08:00
Florian Quèze bcf7d1dd27 Bug 1400528 - make test_bug574663.html wait until the 'blank' attribute has actually been removed, r=mconley. 2017-09-22 00:50:54 +02:00
Kris Maglione f37317cad0 Bug 1369533: Return dead wrappers rather than null for dead CallbackObject values. r=bz
We don't have access to an appropriate context to create the dead wrapper in
when the callback is nuked, so instead, this patch creates a new dead wrapper
in the caller compartment each time the property is accessed. This is the same
behavior we'd get when trying to re-wrap a cross-compartment dead wrapper, so
it's consistent with the way we handle these situations elsewhere.

MozReview-Commit-ID: 3cMeR4z8EOe

--HG--
extra : rebase_source : 7e8cf4a195ef64deb7677ce4ac9818d342815667
2017-09-04 17:21:06 -07:00
Stone Shih 459eddec0a Bug 1292134: Disable pointerevent_touch-action-span-test_touch-manual because of intermittent failures. r=kats. 2017-09-15 10:38:11 +08:00
Florian Quèze 3e165cf69a Bug 1379587 - fix tests that rely on scrolling on a not-yet-painted browser, r=mconley. 2017-09-15 23:43:56 +02:00
Nicholas Nethercote 2ef37710e7 Bug 1395828 (part 4) - Remove nsIParserService/nsParserService. r=mrbkap.
It a stateless wrapper around static methods in nsHTMLTags and nsHTMLElement,
and hence an unnecessary layer of indirection that just adds complexity and
slowness. This patch removes it, cutting almost 300 lines of code.

This requires making nsElementTable.h an exported header, to expose the
nsHTMLElement methods.

--HG--
extra : rebase_source : abbcb8e5001389affbf717092213b898673db07f
2017-09-05 20:19:06 +10:00
Michael Layzell 44f1d8fa25 Bug 1396976 - Flush IME document changes when entering nested Document Update, r=masayuki 2017-09-13 11:45:49 -04:00
Michael Layzell 5dff36164d Bug 1398883 - Disable the DataTransfer::Protected state for Firefox 57, r=baku
This isn't a super essential feature, and is just a change to try to bring us in
line with chromium and the spec. As this has apparent web compat issues, and
DataTransfer is a hard to test area, this patch moves the changes behind a pref,
which we can come back to turning on after we ship 57.
2017-09-13 11:45:48 -04:00
Andrea Marchesini 57228a9b15 Bug 1359017 - onmessageerror for WindowEventHandlers in case StructuredClone algorithm fails when deserializing, r=masayuki, r=smaug 2017-09-13 05:59:06 +02:00
Sebastian Hengst 66969c6b7b Backed out changeset 7b45c1aebf7f (bug 1359017) 2017-09-13 08:56:13 +02:00
Andrea Marchesini 68fed142b9 Bug 1359017 - onmessageerror for WindowEventHandlers in case StructuredClone algorithm fails when deserializing, r=masayuki, r=smaug 2017-09-13 05:59:06 +02:00
Sebastian Hengst f155e6119f Backed out changeset e28d6869f6a0 (bug 1359017) 2017-09-12 14:16:31 +02:00
Andrea Marchesini 92ba78b8c0 Bug 1359017 - onmessageerror for WindowEventHandlers in case StructuredClone algorithm fails when deserializing, r=masayuki, r=smaug 2017-09-12 11:57:26 +02:00
Wes Kocher b5fe3d1dc7 Merge m-c to autoland, a=merge
MozReview-Commit-ID: zTrDLmRmnn
2017-09-08 13:42:01 -07:00
Wes Kocher 2a30786cad Merge inbound to central, a=merge
MozReview-Commit-ID: 4FEkd1x2GD
2017-09-08 13:36:31 -07:00
Michael Layzell fc5a62297d Bug 1199729 - Part 6: Add some comments to DataTransfer to clarify use of methods, r=baku 2017-09-08 11:05:08 -04:00
Michael Layzell f09d1b11ca Bug 1199729 - Part 5: Update tests for new DataTransfer behaviour, r=baku 2017-09-08 11:05:08 -04:00
Michael Layzell 63ecbc4c55 Bug 1199729 - Part 4: Update EventUtils to simulate drag events more accurately, r=baku 2017-09-08 11:05:08 -04:00
Michael Layzell 18e36b497a Bug 1199729 - Part 3: Clear the DataTransfer after handling Drag and Clipboard events, r=baku 2017-09-08 11:05:07 -04:00
Michael Layzell f116f4037e Bug 1199729 - Part 2: Respect Protected mode in content documents, r=baku 2017-09-08 11:05:07 -04:00
Michael Layzell 9cfa67ef65 Bug 1199729 - Part 1: Add the Protected mode to DataTransfer, r=baku 2017-09-08 11:05:06 -04:00
Masayuki Nakano e1f1db7272 Bug 1396725 - IMEStateManager doesn't need to manage whether menu keyboard listener is installed in different process r=smaug
Currently, IMEStateManager::OnChangeFocusInternal() tries to sync the state
whether menu keyboard listener is installed between itself and active remote
process -- When menu keyboard listener is installed, it posts a message to
_only_ active remote process.  When menu keyboard listener is uninstalled,
it posts a message to _only_ active remote process.  So, it's not guaranteed
that active remote process at installing and uninstalling may be different.
If it's different, IMEStateManager in the old remote process believes that
menu keyboard listener is still installed.  This is what the cause of IME
unavailable in a remote process.

Current approach must be wrong.  IMEStateManager should manage menu keyboard
listener state only in the process which the listener is installed in.  Then,
when menu keyboard listener is uninstalled, IMEStateManager needs to restore
the latest input context in the remote process without asking the remote
process.

Therefore, this patch does:

* stops IMEStateManager::OnChangeFocusInternal() posting message when menu
  keyboard listener is installed and uninstalled.
* removes the message sender and receiver from PBrowser.
* cache the latest input context of active remote process in
  IMEStateManager::SetInputContextForChildProcess().
* make IMEStateManager::SetInputContextForChildProcess() not set input context
  when menu keyboard listener is installed in the process.
* tries to restore latest input context in the remote process in
  IMEStateManager::OnChangeFocusInternal().  If there is no cached input
  context, it does nothing and waits next SetInputContextForChildProcess() call.
* clears the cache when IMEStateManager::OnChangeFocusInternal() changes
  active remote process to different one or nullptr.

So, this must improve performance at activating and inactivating memubar and
opening and closing popup menu in the main process.

MozReview-Commit-ID: EelKSPlaXdw

--HG--
extra : rebase_source : db7334b3c0d3ce87868450ee3179692027975bd6
2017-09-07 11:46:08 +09:00
Xidorn Quan 32fe2f2b94 Bug 1397711 - Null-check widget of keyboard event before invoking its PostHandleKeyEvent. r=masayuki
MozReview-Commit-ID: KTniEBMvw9q

--HG--
extra : rebase_source : 3fa266b0097ee94f83c6567d5cebd66f41369d17
2017-09-07 22:07:34 +10:00
Olli Pettay 2e8b602108 Bug 1377131 - Try to trigger collector slices at times which disturb page js less (at least with iframes loaded after the top level page has been loaded), r=mccr8,bz
When triggering an iframe load or starting to parse a document for an iframe, the main thread may often have some time before the new page has been created. Try to trigger CC/GC slice at such point in order to avoid collector later when page is already executing its JS

--HG--
extra : rebase_source : 806df0af1dbaefb1761134eca0bb7c6ade6ac1a9
2017-09-06 18:18:11 +01:00
Nicholas Nethercote 712013de72 Bug 1396693 - Make nsIEventListenerChange::changedListenerNames noscript. r=smaug.
This is required for deCOMtamination. The patch removes the only script use of
this attribute, which is a low-importance one in a test.

--HG--
extra : rebase_source : 65c29043fbd77e60b21398216593cc9788723dd5
2017-09-05 11:52:54 +10:00
Makoto Kato b7d709c044 Bug 1397791 - Move StartBatchChanges and EndBatchChanges from nsISelectionPrivate to Selection. r=smaug
There is no reason to keep StartBatchChanges and EndBatchChanges in nsISelectionPrivate since this is noscript method.  And if moving it to Selection, we can remove virtual keyword.

MozReview-Commit-ID: Go6njiW3r2x

--HG--
extra : rebase_source : cb5bfce8312de7d49496e5f841e9786ff16102f6
2017-09-08 12:10:44 +09:00
Masayuki Nakano 4ce89d8f61 Bug 1369072 - part3: nsXBLPrototypeHandler::DispatchXBLCommand() should use controller of visible window r=smaug
With previous change, KeyboardEvent is dispatched even when invisible window
has focus.  However, nsRootWindow::GetControllerForCommand() returns controller
for focused window even when the window is invisible because it uses
nsFocusManager::GetFocusedDescendant() to retrieve focused window.

Perhaps, we can assume that users won't expect to do something with invisible
window when they type some keys.  Then, nsRootWindow::GetControllerForCommand()
should return controller for visible ancestor window if focused window is
invisible.

This patch makes nsFocusManager::GetFocusedDescendant() can return only visible
descendants.  However, it already has a bool argument.  Therefore, it should
have a flag instead of adding new flag.  Most changes of this patch is replacing
its callers.

Then, nsRootWindow::GetControllerForCommand() and nsRootWindow::GetControllers()
should have a bool flag if it should return controller(s) for visible window.
This patch adds a bool flag for it.  Fortunately, the interface isn't scriptable.

Finally, this patch makes nsXBLPrototypeHandler::DispatchXBLCommand() and
EventStateManager::DoContentCommandEvent() retrieve controller for visible
window since they are always handles user input.

MozReview-Commit-ID: GygttTHuKRm

--HG--
extra : rebase_source : 1341273c4606298cb9b890b9312d9f5c8a75d144
2017-09-07 22:54:49 +09:00
Masayuki Nakano a69ee36518 Bug 1369072 - part0: Add automated test for testing key event handlers to scroll parent document when an iframe element has or had focus r=smaug
When an <iframe> element has focus and its sub document isn't scrollable, the
parent document should be scrolled instead.

MozReview-Commit-ID: 5LSVDHDQGtI

--HG--
extra : rebase_source : 0b22a426ef0e4ab662c941f6bc759679c1b92b19
2017-09-05 15:18:02 +09:00
Masayuki Nakano 3221029e49 Bug 1396302 - IMEStateManager::OnChangeFocusInternal() should check oldWidget's IME notification requests rather than sFocusedIMEWidget r=m_kato
In some cases, sFocusedIMEWidget may be nullptr but oldWidget still has
composition since IMEStateManager doesn't guarantee that NOTIFY_IME_OF_BLUR
is sent after REQUEST_TO_COMMIT_COMPOSITION nor REQUEST_TO_CANCEL_COMPOSITION.

Therefore, when it tries to clean up old widget's composition, it should refer
the old widget's IME notification requests.

MozReview-Commit-ID: 8kZvJbHfs5z

--HG--
extra : rebase_source : 3a1aab1023ab36e3668efd93b95fb5c8ccf2f21d
2017-09-04 17:37:40 +09:00
Stone Shih 35110f00e9 Bug 1389086 Part2: Use once event listeners to avoid they are triggered after the test is done. r=smaug.
MozReview-Commit-ID: JrYXWs2yhSO
2017-08-31 16:55:39 +08:00
Stone Shih 35fc5fd478 Bug 1389086 Part1: Remove windows line ending in the test file. r=smaug.
MozReview-Commit-ID: 6JHn14XXDLM
2017-09-01 10:12:54 +08:00
Sebastian Hengst a56d428b1f merge mozilla-inbound to mozilla-central. r=merge a=merge
MozReview-Commit-ID: Gf0QPFp52Bj
2017-08-30 11:05:16 +02:00
Andrew McCreight 78807d8776 Bug 1391005 - Eliminate NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION_INHERITED. r=peterv
Replace it with NS_INTERFACE_MAP_BEGIN_CYCLE_COLLECTION, because it
has been the same for a while.

MozReview-Commit-ID: 5agRGFyUry1

--HG--
extra : rebase_source : 5388c56b2f6905c6ef969150f0c5b77bf247624d
2017-08-29 16:02:48 -07:00
Stone Shih 22e157686e Bug 1292134 - Revise touch-action related test cases to wait for the scroll event to avoid resetting scrollLeft break the following scroll behaviors. r=kats.
MozReview-Commit-ID: JidGiZmyzk5
2017-08-17 13:45:00 +08:00
Masayuki Nakano 5c2c570f9b Bug 1393816 - part1: Cache a range until new range is created in Selection r=smaug
When setting value of <input type="text">, nsTextEditorState removes all
ranges of normal selection first.  Then, TextEditor sets the value.  Finally,
TextEditor collapses the selection at the end of the text.

In bug 1386471, we got that there are some problems to remove the call of
Selection::RemoveAllRanges() in nsTextEditorState.  Therefore, we need another
approach to improve Selection::Collapse().

The approach of this patch is, when removing all ranges from normal selection,
Selection can cache an nsRange instance if there is an instance which is not
referenced from other than the Selection (i.e., it'll be removed when
Selection::Clear() is called).  Then, Selection::Collapse() can reuse it.  With
this fix, Selection::Collapse() can reduce allocation cost and may reduce some
other cost like adding it to mutation observer.

However, keeping nsRange instance may cause increasing mutation observer's cost
since nsRange will be adjusted its start node/offset and end node/offset with
mutation observer to guarantee that the range is always valid.  So, we can
cache such range only when the caller (or its callee) will set selection range
later.  Therefore, this patch adds Selection::RemoveAllRangesTemporarily()
and make only nsTextEditorState::SetValue() and
ContentEventHandler::OnSelectionEvent() use it.

MozReview-Commit-ID: FjWrbz4S1ld

--HG--
extra : rebase_source : 83677640525e0b1a84bdd7fce63ff4704b9cc22b
2017-08-25 19:21:39 +09:00
Masayuki Nakano e3529fd155 Bug 1375502 - part2: Add nsIContentIterator::Init(nsINode*, uint32_t, nsINode*, uint32_t) r=mats
nsIContentIterator::Init() takes nsRange but it's too expensive for some users.
So, there should be another Init() which can be specified a range in DOM tree
with 2 pairs of nsINode* and uint32_t.

MozReview-Commit-ID: 6JXic0KOM2d

--HG--
extra : rebase_source : 28ff355a2aa0dcb5d65495806ef8c67f1da642ea
2017-06-26 17:26:27 +09:00
Masayuki Nakano acde25fb18 Bug 1375502 - part1: ContentEventHandler shouldn't use nsRange for temporary use r=mats
Allocating and initializing nsRange is too expensive especially for temporary
use.  However, ContentEventHandler uses nsRange only for representing two DOM
points.  So, it should use simpler helper class, RawRange, for reducing some
unnecessary runtime cost.

Note that this still uses nsRange for initializing nsIContentIterator.  This
will be fixed by the following patch.

MozReview-Commit-ID: 5TUy6yJf7HA

--HG--
extra : rebase_source : c4eb58e8f37c408c75479e6961ba9225f8bcee77
2017-06-23 13:21:47 +09:00
Eric Rahm a33f11e0f5 Bug 1391803 - Use nsStringFwd.h for forward declaring string classes. r=froydnj
We should not be declaring forward declarations for nsString classes directly,
instead we should use nsStringFwd.h. This will make changing the underlying
types easier.

--HG--
extra : rebase_source : b2c7554e8632f078167ff2f609392e63a136c299
2017-08-16 16:48:52 -07:00
Gabor Krizsanits 5acd81eb72 Bug 1376895 - Disable preloaded browser in two mochitests. r=me
nsIIOService based events when used via SpecialPowers in mochitests
combined with the preloaded browser in the same process can cause
IsSafeToRun() assertion in SchedulerGroup.h:81. To avoid that we make sure that
previous tests in the suit do not create a preloaded browser. This cannot happen
in a real life scenario.
2017-08-16 13:00:04 +02:00
Carsten "Tomcat" Book 1fc6e56a12 merge autoland to mozilla-central a=merge 2017-08-16 11:20:31 +02:00
Carsten "Tomcat" Book 786ca37886 Backed out changeset 6949fdc7f97c (bug 1376895) 2017-08-16 11:16:04 +02:00
Wes Kocher 3945278423 Merge m-c to autoland, a=merge
MozReview-Commit-ID: D96bIJACwZe
2017-08-15 19:16:12 -07:00
Bryce Van Dyk d5ec1b23bd Bug 1275856 - Update dom event tests to reflect removal of RecorderErrorEvent and new MediaRecorderErrorEvent. r=smaug
MozReview-Commit-ID: 52YJMJncLyM

--HG--
extra : rebase_source : dc3db183c900bc7269fc85e84f599ba2ae8ab278
2017-08-11 14:03:23 +12:00
Carsten "Tomcat" Book 6b36e00b7c merge mozilla-inbound to mozilla-central a=merge 2017-08-15 11:42:11 +02:00
Aryeh Gregor 2df3e475b4 Bug 1387828 - Reinstate support for initKeyboardEvent; r=smaug
https://github.com/w3c/uievents/issues/112

This is supported by all other UAs.  In the past we had compatibility
problems when trying to add support, but it seems these might be fixed
if we make all arguments optional beyond the first.

The interface chosen for the method is from the spec, which has been
updated to match Chrome.  This is also very similar to WebKit, but the
final four arguments are different from IE.

MozReview-Commit-ID: 36AeX1JwJTt

--HG--
extra : rebase_source : 28b298d370f0f9a5ab4090a71a2aae91f1d90025
2017-08-06 16:52:39 +03:00
Chung-Sheng Fu 7a392d6952 Bug 1382499 - Enhance fingerprinting resistance for Touch API r=arthuredelstein,bz
MozReview-Commit-ID: 8nzOkvIvwrD

--HG--
extra : rebase_source : 15cfa77ffc639838d6345fa4bffc7079d8d198e7
2017-07-31 17:30:38 +08:00
Masayuki Nakano 9467d56cf9 Bug 1388647 - part1: IMEStateManager::OnChangeFocusInternal() shouldn't request to commit composition with sFocusedIMETabParent r=m_kato
When a remote process has focus and it loses focus,
IMEStateManager::OnChangeFocusInternal() sends NOTIFY_IME_OF_BLUR via
IMEStateManager::NotifyIMEOfBlurForChildProcess().  Therefore,
sFocusedIMETabParent and sFocusedIMEWidget are set to nullptr here. So, if a
window becomes active, REQUEST_IME_TO_COMMIT_COMPOSITION in
IMEStateManager::OnChangeFocusInternal() won't work because
IMEStateManager::NotifyIME() ignores the request because of coming from wrong
process.

Therefore, IMEStateManager::OnChangeFocusInternal() needs to send
REQUEST_TO_COMMIT_COMPOSITION with proper process information which is only
stored by TextComposition instance.

MozReview-Commit-ID: KNEvOoQtK1E

--HG--
extra : rebase_source : 2d0c9297a6ffd3e7883130c80deec0479212148e
2017-08-09 18:04:28 +09:00
Stone Shih c6b5aece03 Bug 1351148 Part7: Revise window_wheel_default_action.html to wait event 'FullZoomChange' and then check the result. r=smaug.
MozReview-Commit-ID: E56dfMIxtSl
2017-07-07 11:48:42 +08:00
Stone Shih 98ad196e24 Bug 1389086: Disable intermittent failed test case test_bug1323158.html. r=bevis.
MozReview-Commit-ID: LtXZ17ScNaY
2017-08-14 16:02:06 +08:00
Gabor Krizsanits 2322764f34 Bug 1376895 - Disable preloaded browser in two mochitests. r=me
nsIIOService based events when used via SpecialPowers in mochitests
combined with the preloaded browser in the same process can cause
IsSafeToRun() assertion in SchedulerGroup.h:81. To avoid that we make sure that
previous tests in the suit do not create a preloaded browser. This cannot happen
in a real life scenario.
2017-08-15 14:04:54 +02:00
Stone Shih de7f705042 Bug 1351148 Part2: Add a priority queue for input events. r=smaug.
MozReview-Commit-ID: 5ud1Ex9UNVo
2017-03-21 15:44:12 +08:00
Masatoshi Kimura dec070e4cf Bug 1389460 - Remove @deprecated nsIDOMEventTarget.DispatchDOMEvent. r=smaug
MozReview-Commit-ID: E88DZK5sfwx

--HG--
extra : rebase_source : 64e1a47c9366a970f20ec459dde9b379a207e802
2017-08-07 02:28:52 +09:00
Wes Kocher eb3058e466 Backed out 3 changesets (bug 1382499) for eslint failures a=backout
Backed out changeset 0ebb9924affa (bug 1382499)
Backed out changeset c25b50b0edc5 (bug 1382499)
Backed out changeset 1dcdc22d4919 (bug 1382499)

MozReview-Commit-ID: 9rygU1QF1kb
2017-08-11 13:49:34 -07:00
Chung-Sheng Fu c28d4be7b3 Bug 1382499 - Enhance fingerprinting resistance for Touch API r=arthuredelstein,bz
MozReview-Commit-ID: 8nzOkvIvwrD

--HG--
extra : rebase_source : 15cfa77ffc639838d6345fa4bffc7079d8d198e7
2017-07-31 17:30:38 +08:00
Sebastian Hengst b3269bec34 Backed out changeset 685802013f43 (bug 1389460) for OS X bustage at widget/cocoa/nsMenuX.mm:364: no member named 'DispatchDOMEvent' in 'nsIContent'. r=backout 2017-08-11 17:46:42 +02:00
Masatoshi Kimura 58d29db70b Bug 1389460 - Remove @deprecated nsIDOMEventTarget.DispatchDOMEvent. r=smaug
MozReview-Commit-ID: E88DZK5sfwx

--HG--
extra : rebase_source : 63300d87c0496394d3f75cb76bc47c75d640d369
2017-08-07 02:28:52 +09:00
Carsten "Tomcat" Book c329d562fb merge mozilla-inbound to mozilla-central a=merge 2017-08-09 11:37:08 +02:00
Wes Kocher 7651bde05c Merge m-c to inbound, a=merge
MozReview-Commit-ID: 9Abf0fILvvK
2017-08-08 15:16:00 -07:00
Eric Rahm 01f545fea7 Bug 1386825 - Part 1: Remove MOZ_B2G from dom. r=bkelly
MozReview-Commit-ID: 1zzP2r01B7U
2017-08-08 14:41:05 -07:00
Aryeh Gregor 82ee59d8c7 Bug 1388119 - Drop support for createEvent("ErrorEvent"/"PopStateEvent"); r=smaug
They were just dropped from the spec:

https://github.com/whatwg/dom/issues/362
https://github.com/whatwg/dom/pull/489

ErrorEvent we never supported anyway until it was added recently to
match the spec.  PopStateEvent is not supported by WebKit, Blink is
planning to try dropping support, our telemetry shows usage is
basically zero, and we never supported any way to initialize it anyway.

The changes to Document-createEvent.html and Document-createEvent.js are
taken from upstream.  The other wpt changes are new in this commit.

MozReview-Commit-ID: A6GzhLwL08l

--HG--
extra : rebase_source : 4bdcd605b179ea787985845e9b1c53f76ebc179a
2017-08-07 21:19:59 +03:00
Joel Maher 0003b91c8f Bug 1388356 - add pref apz.test.fails_with_native_injection for windows to allow touch based events to work in windows 10 tests. r=kats
MozReview-Commit-ID: 3QJ1aFpxGxY
2017-08-08 15:08:04 -04:00
Kan-Ru Chen 87a450cad1 Bug 1386495 - Add timeStamp to DOMEventMarkerPayload. r=mstange,smaug
MozReview-Commit-ID: B3b4laxMqQM

--HG--
extra : rebase_source : 80e41c2f9d921ddd93d41c348594895046c7af8f
2017-08-03 15:42:42 +08:00
Aryeh Gregor 39290528d2 Bug 1388069 - Support createEvent("FocusEvent"); r=smaug
This is the one event we don't support in createEvent() that Blink
doesn't want to drop support for because they see nontrivial usage:

https://www.chromestatus.com/metrics/feature/timeline/popularity/1171

Supporting it shouldn't hurt us and might make us work better on
whatever the sites are that Blink is hitting.

MozReview-Commit-ID: FbfTd6AYnDg

--HG--
extra : rebase_source : f6bbcbd04af87349064b965814571e832932c130
2017-08-07 20:52:41 +03:00
Nicholas Nethercote f941156987 Bug 1386600 - Change nsIStringBundle methods to return |AString| instead of |wstring|. r=emk,sr=dbaron.
This removes about 2/3 of the occurrences of nsXPIDLString in the tree. The
places where nsXPIDLStrings are null-checked are replaced with |rv| checks.

The patch also removes a couple of unused declarations from
nsIStringBundle.idl.

Note that nsStringBundle::GetStringFromNameHelper() was merged into
GetStringFromName(), because they both would have had the same signature.

--HG--
extra : rebase_source : ac40bc31c2a4997f2db0bd5069cc008757a2df6d
2017-08-04 14:40:52 +10:00
Jan Henning 34bb1f8a36 Bug 1266683 - Part 2 - Add private browsing mode info to InputContext. r=masayuki
Android now supports telling an IME that it shouldn't store user-entered content into it's dictionary/language model/etc. and we want to automatically enable this in private browsing.

As the code that handles input on Android doesn't have any notion of tabs (and therefore of the difference between normal and private tabs), the best way to get that info across is to retrieve it directly within the IMEStateManager from the corresponding document and store it in the inputContext, which is then passed to Java for Fennec to handle.
Implementing this within Gecko also has the benefit that this part of the code can be used by other platforms as well should they want to support similar features in the future.

MozReview-Commit-ID: DsxjC4Ma7DR

--HG--
extra : rebase_source : f0940cb40170ab32cf5a172d07a61d083427be8a
2017-07-30 19:45:03 +02:00
Sebastian Hengst 39ccebaf18 merge mozilla-inbound to mozilla-central. r=merge a=merge
MozReview-Commit-ID: 9IxbB2vCH4S
2017-08-05 11:55:25 +02:00
Kate McKinley 092434c08c Bug 1376651 - Pass the nsIScriptElement instead of allocating a string every time r=ckerschb
Change the interface to GetAlowsInline to take an nsISupports* instead
of a string, and pass the nsIScriptElement directly. If we don't have an
element, then pass nullptr or the mock string created as an
nsISupportsString.

MozReview-Commit-ID: pgIMxtplsi

--HG--
extra : rebase_source : 4691643bb67ff6c78a74a4886a04c4816cff6219
2017-07-27 11:01:24 -07:00
Jim Mathies 57d9bf0aee Bug 1360666 - Update IME state when nsObjectLoadingContent content changes type from 'loading' to a valid content type. r=masayuki
MozReview-Commit-ID: JC3YGS75gpN
2017-08-03 14:07:14 -05:00
Olli Pettay f785d80029 Bug 1385666, ensure layout is flushed when editor gets focus, r=masayuki
--HG--
extra : rebase_source : 2dd86e64001fa48469a93849516e26c41c9163e4
2017-08-03 19:36:58 +03:00
Jessica Jong 47209070af Bug 1385478 - Part 2: Change Required/IsRequired() to look at NS_EVENT_STATE_REQUIRED instead. r=bz
In order to speed up Required/IsRequired(), instead of querying for the
@required attribute, we're now using the NS_EVENT_STATE_REQUIRED flag to know
whether an element's value is required.

For this to work correctly, we need to set NS_EVENT_STATE_REQUIRED earlier,
that is, in AfterSetAttr(), before any consumer of IsRequired(). We also need
to update or clear our required states when input type changes, since we may
have changed from a required input type to a non-required input type or
vice versa.

Note that NS_EVENT_STATE_REQUIRED/OPTIONAL is now part of the
EXTERNALLY_MANAGED_STATES.

MozReview-Commit-ID: Bjiby9GqJSB
2017-08-03 01:27:00 -04:00
Wes Kocher 8de77914f5 Backed out changeset bcd223309de8 (bug 1360666) for asserting in stylo reftests a=backout
MozReview-Commit-ID: HH3rwDwvYyz
2017-08-02 18:14:56 -07:00
Jim Mathies 37050ac3cc Bug 1360666 - Update IME state when nsObjectLoadingContent content changes type from 'loading' to a valid content type. r=masayuki
MozReview-Commit-ID: 2cjJ5SvJsTa
2017-08-02 15:31:55 -05:00
Ryan Hunt c38e071dbe Bug 1385071 - Add another method to EventTarget for detecting only non-passive key listeners. r=smaug
This is for adding a pref that will allow web content to have key listeners
and use keyboard APZ, if they are marked passive. This commit also reworks
the function names and comments to make them more accurate.

MozReview-Commit-ID: LGDaVQOK1CS

--HG--
extra : rebase_source : a6bb4b7fff3488dea62b9114aa164814c74561a4
2017-07-27 19:46:44 -04:00
Kestrel 91cfa95229 Bug 918780 - Add new PopupControlState for permitting file/color picker popup regardless of dom_allowed_events. r=smaug
MozReview-Commit-ID: 1GbjQ6IkMsv

--HG--
extra : rebase_source : 4ea11b78007d9ab67a932536843b3e12175732b3
2016-04-24 04:49:00 +01:00
Sebastian Hengst 915c63c332 merge mozilla-central to mozilla-inbound. r=merge a=merge 2017-07-31 11:28:37 +02:00
Nicholas Nethercote 72c884bf74 Bug 1384835 (part 3, attempt 2) - Remove the Preferences::Get*CString() variants that return nsAdoptingCString. r=froydnj.
--HG--
extra : rebase_source : d317b25be2ec21d1a60d25da3689e46cdce0b649
2017-07-31 14:28:48 +10:00