This method is never called. It is the last use of
nsPluginHost::GetInst() and various other non-static methods, so
remove them all.
Differential Revision: https://phabricator.services.mozilla.com/D191192
This is a simple mistake of the previous patch. The code path is originally for
a left click handling. Therefore, there is no check whether the click point is
in a selection range because in that case, left click should collapse selection.
However, the selection should not be collapse when it's a right click in a
selection range because the context menu target is the selection range.
The `ui.mouse.right_click.collapse_selection.stop_if_non_collapsed_selection`
pref is set to `true` by default. Therefore, the existence of a non-collapsed
selection has hidden this bug. However, if it's set to `false`, this always
happens. Additionally, editor does not set ancestor limiter of selection if the
root element is editable [1]. I think that we can now remove this special path,
but it's risky. Therefore, this patch just adds the new check into the method.
1. https://searchfox.org/mozilla-central/rev/ce4599d3d4e20e34cb6db68f255c3dff1aec246b/editor/libeditor/EditorBase.cpp#5448,5450-5451
Differential Revision: https://phabricator.services.mozilla.com/D193529
This patch removes the old docshell timeline and timeline markers codebase and replaces them with equivalent Gecko profiler marker. This patch also fixes Bug 1834143, which is a subset of 1421651.
Differential Revision: https://phabricator.services.mozilla.com/D184217
This patch removes the old docshell timeline and timeline markers codebase and replaces them with equivalent Gecko profiler marker. This patch also fixes Bug 1834143, which is a subset of 1421651.
Differential Revision: https://phabricator.services.mozilla.com/D184217
Sorry this is not a particularly easy patch to review. But it should be
mostly straight-forward.
I kept Document::Dispatch mostly for convenience, but could be
cleaned-up too / changed by SchedulerGroup::Dispatch. Similarly maybe
that can just be NS_DispatchToMainThread if we add an NS_IsMainThread
check there or something (to preserve shutdown semantics).
Differential Revision: https://phabricator.services.mozilla.com/D190450
The preference "test.events.async.enabled" controls the usage of
widget events in general, but Marionette doesn't support all of
them yet. To get widget events enabled for web-platform tests
those unsupported event types need to still synthesize the event.
Differential Revision: https://phabricator.services.mozilla.com/D188296
The preference "test.events.async.enabled" controls the usage of
widget events in general, but Marionette doesn't support all of
them yet. To get widget events enabled for web-platform tests
those unsupported event types need to still synthesize the event.
Differential Revision: https://phabricator.services.mozilla.com/D188296
To allow remote settings client to set fingerprinting overrides from
Javascript, we need to implement nsIRFPService for nsRFPService.
This patch changes the return format of nsRFPService::GetOrCreate() to
match the singleton implementation of nsIRFPService. As a result of it,
we need to change the first init call in nsContentUtils because we
cannot forward a already_AddRefed<> to mozilla::Unused. It will cause a
memory leak.
Differential Revision: https://phabricator.services.mozilla.com/D182809
To allow remote settings client to set fingerprinting overrides from
Javascript, we need to implement nsIRFPService for nsRFPService.
This patch changes the return format of nsRFPService::GetOrCreate() to
match the singleton implementation of nsIRFPService. As a result of it,
we need to change the first init call in nsContentUtils because we
cannot forward a already_AddRefed<> to mozilla::Unused. It will cause a
memory leak.
Differential Revision: https://phabricator.services.mozilla.com/D182809
This patch removes the static pointer to nsIIOService in nsContentUtils,
replacing it to calls to mozilla::components::IO::Service.
It also makes nsScriptSecurityManager::sIOService a StaticRefPtr.
Differential Revision: https://phabricator.services.mozilla.com/D188714
This patch removes the static pointer to nsIIOService in nsContentUtils,
replacing it to calls to mozilla::components::IO::Service.
It also makes nsScriptSecurityManager::sIOService a StaticRefPtr.
Differential Revision: https://phabricator.services.mozilla.com/D188714
This makes it cheaper to copy the nsAttrValue, which improves innerHTML times on Speedometer
because it reduces the time spent creating and destroying valueForAfterSetAttr.
It will also make it possible to reuse eAtomArray values across elements.
This patch adds a copying operation in AllocClassMatchingInfo which is needed
now that the MiscContainer's mValue.mAtomArray is immutable. This is a bit
unfortunate: In the past, this was doing one atom array allocation, and now
it's doing two; one during parsing and one during the copy. However, I would
expect that most calls to getElementsByClassName only supply a single class
name and not a set of space-separated class names, but I haven't measured it.
If this copy turns out to make things slower, we can probably avoid it by
adding a way to parse a string into an AtomArray directly without going
through nsAttrValue.
Before: https://share.firefox.dev/3DAhLzm
After: https://share.firefox.dev/456TMTM
Differential Revision: https://phabricator.services.mozilla.com/D183810
This considerably improves the testcase in bug 1834003, because it
reduces the amount of memory we need to look at when checking the
listeners at the nsWindowRoot. At the moment, nsWindowRoot has 156
listeners for 94 different event types, all from JSWindowActor event
listeners.
Having a separate array per event type also matches what Blink and Webkit do.
Differential Revision: https://phabricator.services.mozilla.com/D183431
This considerably improves the testcase in bug 1834003, because it
reduces the amount of memory we need to look at when checking the
listeners at the nsWindowRoot. At the moment, nsWindowRoot has 156
listeners for 94 different event types, all from JSWindowActor event
listeners.
Having a separate array per event type also matches what Blink and Webkit do.
Differential Revision: https://phabricator.services.mozilla.com/D183431
This considerably improves the testcase in bug 1834003, because it
reduces the amount of memory we need to look at when checking the
listeners at the nsWindowRoot. At the moment, nsWindowRoot has 156
listeners for 94 different event types, all from JSWindowActor event
listeners.
Having a separate array per event type also matches what Blink and Webkit do.
Differential Revision: https://phabricator.services.mozilla.com/D183431
Before this patch, we would have called listeners added with both
addEventListener("end", ...) and addEventListener("endEvent", ...).
Now we will just call listeners added with the latter and ignore the
former.
This change only affects listeners added with addEventListener.
For attribute handlers and IDL property listeners, we still use
onbegin/onrepeat/onend as before.
The new behavior matches Blink, simplifies the code, and will let us
improve performance by storing event listeners in a map keyed by event
type atom (bug 1834370).
Differential Revision: https://phabricator.services.mozilla.com/D184532