Commit Graph

23756 Commits

Author SHA1 Message Date
Cosmin Sabou
0f45148664 Backed out changeset 531593bacc4e (bug 1448040) for Android build bustages on HangAnnotations.h. CLOSED TREE
--HG--
extra : rebase_source : ea3618023c548a8ca6ca14749633c194606af52f
2018-06-07 19:22:31 +03:00
Doug Thayer
87bf13e093 Bug 1448040 - Remove HangMonitor/ChromeHangs r=Nika
Fairly straightforward, just a blanket removal. Haven't heard
anything on dev-platform or fx-data-dev regarding this removal,
so I think it's likely safe to remove on Nightly, and we can
revert if anyone makes a fuss.

As part of removing the HangMonitor, I renamed a few things and
reorganized the namespaces to not depend on a HangMonitor
namespace. Hopefully this doesn't produce too much noise in the
diff, it just seemed appropriate to move everything around
rather than keep dangling vestiges of the old system.

MozReview-Commit-ID: 8C8NFnOP5GU

--HG--
extra : rebase_source : 59e4a6ced7d14d2a01c0b79e944078ea84cae523
2018-04-29 18:21:20 -07:00
Coroiu Cristina
d2f82e1f42 Merge inbound to mozilla-central a=merge 2018-06-07 12:47:31 +03:00
Dan Glastonbury
7811112058 Bug 1465307 - P1: Extend StyleComplexColor to support additive blending. r=hiro,xidorn
Refactored StyleComplexColor to support "complex" blending between
background (numeric) color and foreground color (currentColor).
Made explicit the distinction between numeric, currentColor and a
complex blend in Gecko and Stylo.

This is to support SMIL animation, for example, of the form:

     <animate from="rgb(10,20,30)" by="currentColor" ... />

MozReview-Commit-ID: IUAK8P07gtm

--HG--
extra : rebase_source : d3648101c6f65479b21e6f02945731cd5bb57663
2018-05-23 15:23:26 +10:00
Ting-Yu Chou
dd7965dec0 Bug 1401883 - don't hold unnecessary references to the Windows app shell; r=jimm
When runnables are posted to the main thread's event loop, the event
loop notifies any thread observers that this has been done.  The app
shell registers itself as just such a runnable, and posts messages to
the native event loop that processing native events needs to be done.

On Windows, this posting takes an extra reference to the app shell, to
keep it alive until the message is processed by the native event loop,
since app shell code needs to be invoked during that processing.  The
processing releases this extra reference, so everything stays balanced.

Except that it's possible for messages to be posted to the native event
loop, and then browser shutdown happens.  Those messages are not
processed and the associated references taken are not released.  This
imbalance means that in debug builds, we appear to be leaking the app
shell, and that leaking results in intermittent oranges.

This intermittent orange has manifested itself in a variety of ways over
the years, depending on how big the app shell itself was (since that
changes the number of bytes leaked) and how many leak-checked things the
app shell was holding on to.  This bug is merely the latest
manifestation; the last serious work on analyzing the phenomenon and
fixing it was done in bug 1220517.

The solution proposed in that bug was that we simply stop the extra
reference counting; when the app shell is destroyed normally, we
shouldn't be processing the native event loop any more anyway.  So even
if the native event loop is holding (freed) pointers to the app shell,
we'd never execute the callback and perform a use-after-free.  Reading
through the code suggests that this *ought* to be the case, but the
potential for shooting ourselves in the foot seems awfully high.

In any event, this is not a problem unique to Windows; we have seen this
same sort of thing happen on OS X.  See nsAppShell::ProcessGeckoEvents
in widget/cocoa/nsAppShell.mm.

Here we propose a slightly different solution: we keep track of the
number of native event callbacks we have scheduled, incrementing when we
schedule, and decrementing when we actually run one.  When the app shell
is destroyed, we simply set the number of outstanding events to zero,
and we prohibit the callback from accessing the app shell if there are
no outstanding events.  This solution is analogous to dropping the extra
reference counting, but avoids potential badness if we do wind up
processing native events after the app shell is destroyed.
2018-06-06 11:05:18 -04:00
Randall Barker
2c2e0b614f Bug 1465816 - Add initial code needed to support gfxVRExternal on android r=kip,jchen
MozReview-Commit-ID: 9rXXqIvyvhp
2018-06-05 18:33:01 -07:00
Cosmin Sabou
2c1302b895 Backed out changeset 66a3146a7fce (bug 1465816) for frequent reftest failures on draw_rect.html. CLOSED TREE 2018-06-06 00:28:56 +03:00
Randall Barker
4b62519e23 Bug 1465816 - Add initial code needed to support gfxVRExternal on android r=kip,jchen
MozReview-Commit-ID: 9rXXqIvyvhp
2018-06-05 12:34:15 -07:00
Miko Mynttinen
4c85ef17cc Bug 1465060 - Part 1: Fix warnings for std::move() use r=froydnj
MozReview-Commit-ID: HpdFXqQdIOO

--HG--
extra : rebase_source : 1e7eea4f2d4ec16ec0c559a8afb26976ddbf4d07
2018-06-01 17:59:07 +02:00
arthur.iakab
7e765f798b Backed out 2 changesets (bug 1465060) for build bustages on security/sandbox/linux/reporter/SandboxReporter.cpp
Backed out changeset 7c8905b6b226 (bug 1465060)
Backed out changeset 10446073eca8 (bug 1465060)
2018-06-03 19:25:41 +03:00
Miko Mynttinen
8d9dc85cd4 Bug 1465060 - Part 1: Fix warnings for std::move() use r=froydnj
MozReview-Commit-ID: HpdFXqQdIOO

--HG--
extra : rebase_source : 619d0e0ff63a2453c80f0c4d9beb906d43fa9b01
2018-06-01 17:59:07 +02:00
Andreea Pavel
4ced6e8b2d Merge mozilla-central to autoland. a=merge 2018-06-03 07:27:01 +03:00
Mats Palmgren
8f2a5e19c9 Bug 1466330 - Make nsITheme::GetWidgetBorder return the border directly instead of using an out-param (idempotent patch). r=emilio 2018-06-02 19:10:48 +02:00
Emilio Cobos Álvarez
1e9c395548 Bug 1466168: Remove mozilla::Forward in favor of std::forward. r=froydnj
Same approach as the other bug, mostly replacing automatically by removing
'using mozilla::Forward;' and then:

  s/mozilla::Forward/std::forward/
  s/Forward</std::forward</

The only file that required manual fixup was TestTreeTraversal.cpp, which had
a class called TestNodeForward with template parameters :)

MozReview-Commit-ID: A88qFG5AccP
2018-06-02 09:33:26 +02:00
Boris Zbarsky
c7f378d7ab Bug 1465875 part 1. Eliminate pointless QIs to nsIDOMNSEditableElement. r=qdot
We expose the relevant APIs on textarea and input elements anyway
(chromeonly).  The QIs will throw on a non-input or non-textarea element, but
none of these consumers expect that to happen.
2018-06-01 22:35:22 -04:00
Csoregi Natalia
468205953d Merge inbound to mozilla-central. a=merge 2018-06-02 01:01:33 +03:00
Emilio Cobos Álvarez
fffb25b74f Bug 1465585: Switch from mozilla::Move to std::move. r=froydnj
This was done automatically replacing:

  s/mozilla::Move/std::move/
  s/ Move(/ std::move(/
  s/(Move(/(std::move(/

Removing the 'using mozilla::Move;' lines.

And then with a few manual fixups, see the bug for the split series..

MozReview-Commit-ID: Jxze3adipUh
2018-06-01 10:45:27 +02:00
Martin Stransky
6d3e29e131 Bug 1464808 - [Wayland] Emulate gdk_drag_context_get_actions(), nsWaylandDragContext::GetSelectedDragAction returns available D&D actions when no one is selected by user, r=jhorak
MozReview-Commit-ID: 586XiJXYZ3D

--HG--
extra : rebase_source : 32d006922cf93f2048f0dda236a69f730fc0f8a0
2018-06-01 12:24:17 +02:00
Noemi Erli
1fd69fa2bc Backed out 18 changesets (bug 1462784) for failures in devtools/client/performance/test/unit/test_tree-model-08.js on a CLOSED TREE
Backed out changeset a74d36598442 (bug 1462784)
Backed out changeset c8192175f360 (bug 1462784)
Backed out changeset cde492240e99 (bug 1462784)
Backed out changeset 8c8d30fa406c (bug 1462784)
Backed out changeset ad3802ffb780 (bug 1462784)
Backed out changeset 2fe10732076c (bug 1462784)
Backed out changeset 268a72b7c3c4 (bug 1462784)
Backed out changeset 4055eb6c3bc6 (bug 1462784)
Backed out changeset 3901070e2e60 (bug 1462784)
Backed out changeset 2faf787fbbdf (bug 1462784)
Backed out changeset 8f06963c7c6f (bug 1462784)
Backed out changeset 036e6f64e224 (bug 1462784)
Backed out changeset e670f156a603 (bug 1462784)
Backed out changeset cd39588aece4 (bug 1462784)
Backed out changeset 2ac65d100fa2 (bug 1462784)
Backed out changeset ea05ff70a51d (bug 1462784)
Backed out changeset 8a06c0ba42f7 (bug 1462784)
Backed out changeset 52ed9a039ad2 (bug 1462784)
2018-06-01 01:06:29 +03:00
Noemi Erli
614b78ae36 Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-06-01 00:58:09 +03:00
Markus Stange
bdb6a5f828 Bug 1462784 - Annotate idle stacks in the native event loop on Linux. r=froydnj
MozReview-Commit-ID: 3Q2A7ytsn1Y

--HG--
extra : rebase_source : 83271e841a84fc2ac7a2fdd5cc66812fb09f61f1
2018-05-18 18:59:47 -04:00
Markus Stange
358ae08897 Bug 1462784 - Annotate idle stacks in the native event loop on Windows. r=froydnj
MozReview-Commit-ID: A0c3ZLLkLUC

--HG--
extra : rebase_source : 9e6c0c0f2fad67fa60f06dbea38b66e3b2ebea6e
2018-05-18 18:59:05 -04:00
Markus Stange
81465bc0d6 Bug 1462784 - Annotate idle stacks in the native event loop on macOS. r=spohl
MozReview-Commit-ID: HD48iBTT8EN

--HG--
extra : rebase_source : 28e5e421b82e2f25fbc806804d36686907cfdd9e
2018-05-16 13:31:02 -04:00
Markus Stange
d521b4678d Bug 1462784 - Add an IDLE category. r=njn
MozReview-Commit-ID: JJ30AhXofBr

--HG--
extra : rebase_source : d79d4da6d51a5dd7259cf015ee1f3678d59ac3bd
2018-05-18 18:15:46 -04:00
Markus Stange
d80822de42 Bug 1462784 - Relabel various other stuff as being OTHER. r=njn
Any more specific work that is happening in these methods will have its own
specific category labeling in that specific code. The instances touched in this
patch are more on the outside and don't really know what kind of code is going
to be running inside.

MozReview-Commit-ID: 47NO1DZzkdH

--HG--
extra : rebase_source : 35362bc94068103367f46b23a14cb3831cd86990
2018-05-18 17:58:43 -04:00
Markus Stange
2d4663fe41 Bug 1462784 - Remove EVENTS category. r=njn
Categories are useful to indicate: This much % of time was spent in this category.

The EVENTS category isn't a very good match for this. This category is currently
only set on labels of functions that handle the processing of an event. But
those functions are usually closer to the base of the stack, and the actual CPU
work during the processing of an event is usually in another category closer to
the top of the stack, e.g. in JS if we're running an event handler, or in LAYOUT
if we're hit testing the position of the event.

This changeset removes the EVENTS category and replaces all uses of it with the
OTHER category.

MozReview-Commit-ID: JPm5hQiBkvp

--HG--
extra : rebase_source : 34fb2ca94151403a6d7ffd5a8b840f00a8bb4afb
2018-05-18 17:36:30 -04:00
Kartikaya Gupta
b81f4d85c3 Bug 1321069 - Redirect the end event of a long-tap sequence back to the content window. r=karlt
In the case of a long-tap touch sequence, a new popup window (the
contextmenu) is spawned while the sequence is ongoing. The touch-end of
the sequence ends up getting delivered to the popup window, instead of
the original content window, and that causes the touch-handling
machinery state in the content window to get out of sync with reality.
This patch detects this scenario and redirects the touch events on the
popup window back to the original content window.

MozReview-Commit-ID: L2vvKLlogRA

--HG--
extra : rebase_source : fd4c36c93e45d05155d415f6470e12979b9a675b
2018-05-30 09:49:23 -04:00
Csoregi Natalia
0c87942d7d Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-05-30 12:27:51 +03:00
Csoregi Natalia
83a923ef7a Merge inbound to mozilla-central. a=merge 2018-05-30 12:25:03 +03:00
Boris Zbarsky
6213894581 Bug 1455676 part 3. Remove nsIDOMNode usage from widget/. r=qdot 2018-05-29 22:58:48 -04:00
Masayuki Nakano
80b5c54449 Bug 1464016 - TextInputHandler should not clear alt/ctrl/meta modifiers of eKeyPress event before sending TextEventDispatcher r=m_kato
If a key combination causes text input, we need to dispatch keypress
events without alt/ctrl/meta modifiers since TextEditor won't handle
keyepress events whose altKey, ctrlKey or metaKey is true as inputting
text.

Currently, TextEventDispatcher sets mCharCode of eKeyPress event from
mKeyValue.  Then, when altKey, ctrlKey or metaKey is true, it'll call
WillDispatchKeyboardEvent() and then, TextInputHandler needs to reset
the charCode value from native event information.

However, the problem is, TextInputHandler::InsertText() is called
with control character when control key is pressed and InsertText()
clears the modifier information before sending eKeyPress event to
TextEvenDispatcher so that TextEventDispatcher won't call
WillDispatchKeyboardEvent() even though control key is actually
pressed.  Therefore, TextInputHandler cannot adjust charCode value
and modifier flags in some cases such as control + option + 'a'.

This patch makes InsertText() stop clearing the modifiers and
makes WillDispatchKeyboardEvent() do it instead.  This procedure
is expected by TextEventDispatcher.

MozReview-Commit-ID: Ig6qgRBeQDh

--HG--
extra : rebase_source : 446e8af0e921946f3409d26ede70446248317673
2018-05-24 20:59:48 +09:00
Xidorn Quan
661ed3d065 Bug 1463993 - Add a rendering test for scrollbar color properties. r=heycam
MozReview-Commit-ID: 442pfDQUUUs

--HG--
extra : rebase_source : 6e336c36f61d7772023e641ca84751c7ddd2b018
2018-05-29 16:37:35 +10:00
Markus Stange
27976ff026 Bug 1461118 - Null-check mGeckoChild after calling DispatchInputEvent. r=spohl
MozReview-Commit-ID: 4bfe8TM4GuS

--HG--
extra : rebase_source : 472e531f56b6a63b7cc8c5fc9faeef6b4abb76c0
2018-05-28 18:00:35 -04:00
Masayuki Nakano
1d38d6b282 Bug 1458845 - Make TextEventDispatcher dispatch keypress event even if altKey is true on macOS r=smaug
On macOS, option key is mapped to alt key, and it works like AltGr key on
the other platforms.  Since our editor doesn't accept keypress events as
typing printable character if one of altKey, ctrlKey and metaKey of the
events is true, widget for macOS sets those attributes to false when an
editor has focus.  On the other hand, if no editor has focus, our widget
does not do this hack so that altKey and ctrlKey values of keypress events
are always same as actual user operation and this is same behavior as the
other browsers.  Therefore, we need to keep setting altKey of keypress
events to true if no editor has focus but we need to dispatch keypress
events even on content unless the charCode is 0.

So, only on macOS, WidgetKeyboardEvent::IsInputtingText() does not need
to check altKey state.

MozReview-Commit-ID: 4DMgdOfLqvQ

--HG--
extra : rebase_source : 18db91c0d77c6910a206e6c767e6f3b5cfd1c2ab
2018-05-23 22:27:17 +09:00
Dorel Luca
d54a3b06aa Backed out changeset da12c077747f (bug 1448040) for Android build bustage on build/src/obj-firefox/dist/include/mozilla/HangAnnotations.h. CLOSED TREE
--HG--
extra : amend_source : 683201b5a47af3cb7fdcb7426c65f1c9ed713186
2018-05-25 20:13:26 +03:00
Doug Thayer
9765bdd0e0 Bug 1448040 - Remove HangMonitor/ChromeHangs r=Nika
Fairly straightforward, just a blanket removal. Haven't heard
anything on dev-platform or fx-data-dev regarding this removal,
so I think it's likely safe to remove on Nightly, and we can
revert if anyone makes a fuss.

As part of removing the HangMonitor, I renamed a few things and
reorganized the namespaces to not depend on a HangMonitor
namespace. Hopefully this doesn't produce too much noise in the
diff, it just seemed appropriate to move everything around
rather than keep dangling vestiges of the old system.

MozReview-Commit-ID: 8C8NFnOP5GU

--HG--
extra : rebase_source : a8840bd26f4b01b756ffa72345ababb625048550
2018-04-29 18:21:20 -07:00
Brendan Dahl
962180171e Bug 1332040 - Dispatch resize after fullscreen transistion for headless. r=jrmuizel
MozReview-Commit-ID: Lo17bhJsnww

--HG--
extra : rebase_source : 6266e9141d8bf99ec4dbaaf6b909e6c02ef9b9d6
2018-05-20 17:00:57 -07:00
Xidorn Quan
ee0c05df56 Bug 1463687 - Apply scrollbar style of root element to scrollbars of viewport. r=heycam
MozReview-Commit-ID: GWmhehtqO1U

--HG--
extra : rebase_source : 18e73bb269c9a0b1fd7d3c4ab25f4ad788d1a065
2018-05-24 16:34:58 +10:00
Martin Stransky
7cc5f69e7a Bug 1463753 - [DragAndDrop] Update mTarget(Wayland)DragContext unconditionally and check its validity after that, r=jhorak
MozReview-Commit-ID: KiNaPDDVvLu

--HG--
extra : rebase_source : 2614c6e33b5a49f809cff5d4590d5f7f4053e808
2018-05-24 11:51:17 +02:00
Noemi Erli
303e1e01d9 Backed out changeset ac922efad9fd (bug 1463687) for failures in build/build/src/layout/base/nsLayoutUtils.cpp on a CLOSED TREE 2018-05-24 13:55:51 +03:00
Xidorn Quan
f34d64c3c5 Bug 1463687 - Apply scrollbar style of root element to scrollbars of viewport. r=heycam
MozReview-Commit-ID: GWmhehtqO1U

--HG--
extra : rebase_source : 76e460a6f57a4caa852ee1ada1c8e213c598bbd1
2018-05-24 16:34:58 +10:00
Markus Stange
a5f551f7c4 Bug 1461635 - Enforce a minimum widget size of 1x1 for toolbar separators. r=spohl
MozReview-Commit-ID: Gc5TC5DGUI

--HG--
extra : rebase_source : 185ad305189e47877bf6765f12917f5307b3b329
2018-05-23 11:55:41 -04:00
Tooru Fujisawa
0eaac17a4a Bug 1378585 - Remove unused nsDragDropEventStatus enum. r=masayuki 2018-05-31 15:15:48 +09:00
Csoregi Natalia
2f779be8d9 Merge mozilla-central to autoland. a=merge CLOSED TREE 2018-06-02 01:03:45 +03:00
Markus Stange
9930a8e72c Bug 1462784 - Annotate idle stacks in the native event loop on Linux. r=froydnj
MozReview-Commit-ID: 3Q2A7ytsn1Y

--HG--
extra : rebase_source : 34c6c678570924bc0e5955a0f8545f1ab1df0d02
2018-05-18 18:59:47 -04:00
Markus Stange
c154c90490 Bug 1462784 - Annotate idle stacks in the native event loop on Windows. r=froydnj
MozReview-Commit-ID: A0c3ZLLkLUC

--HG--
extra : rebase_source : deab79f008225eadfbf301d094e928d9aeff452b
2018-05-18 18:59:05 -04:00
Markus Stange
fdb7675018 Bug 1462784 - Annotate idle stacks in the native event loop on macOS. r=spohl
MozReview-Commit-ID: HD48iBTT8EN

--HG--
extra : rebase_source : 4f34c1b4de30ec5d94a07aa9bab3bd301041c7d6
2018-05-16 13:31:02 -04:00
Markus Stange
c545b8d1ba Bug 1462784 - Add an IDLE category. r=njn
MozReview-Commit-ID: JJ30AhXofBr

--HG--
extra : rebase_source : 0e94fb43e57411281fd57eea54815aef4558b6df
2018-05-18 18:15:46 -04:00
Markus Stange
423ce68542 Bug 1462784 - Relabel various other stuff as being OTHER. r=njn
Any more specific work that is happening in these methods will have its own
specific category labeling in that specific code. The instances touched in this
patch are more on the outside and don't really know what kind of code is going
to be running inside.

MozReview-Commit-ID: 47NO1DZzkdH

--HG--
extra : rebase_source : 344c380ddaaf42a1fd820a26b762c61ee9e2d524
2018-05-18 17:58:43 -04:00
Markus Stange
abf5056ead Bug 1462784 - Remove EVENTS category. r=njn
Categories are useful to indicate: This much % of time was spent in this category.

The EVENTS category isn't a very good match for this. This category is currently
only set on labels of functions that handle the processing of an event. But
those functions are usually closer to the base of the stack, and the actual CPU
work during the processing of an event is usually in another category closer to
the top of the stack, e.g. in JS if we're running an event handler, or in LAYOUT
if we're hit testing the position of the event.

This changeset removes the EVENTS category and replaces all uses of it with the
OTHER category.

MozReview-Commit-ID: JPm5hQiBkvp

--HG--
extra : rebase_source : 66f8ee003d2f70111f4cff16d6e2d906ef4bf10b
2018-05-18 17:36:30 -04:00