Skip to content

Commit 381fca9

Browse files
committed
Backed out 4 changesets (bug 1654992, bug 1654991) for causing timeous in mask-opacity-1e.html
Backed out changeset 11f0f54c6e0a (bug 1654992) Backed out changeset a353dd5b3f08 (bug 1654991) Backed out changeset 6a7964ba549f (bug 1654991) Backed out changeset cf3bfb91d98c (bug 1654991)
1 parent 4900495 commit 381fca9

File tree

136 files changed

+424
-481
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

136 files changed

+424
-481
lines changed

accessible/base/EventQueue.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -268,7 +268,8 @@ void EventQueue::CoalesceSelChangeEvents(AccSelChangeEvent* aTailEvent,
268268

269269
void EventQueue::ProcessEventQueue() {
270270
// Process only currently queued events.
271-
const nsTArray<RefPtr<AccEvent> > events = std::move(mEvents);
271+
nsTArray<RefPtr<AccEvent> > events;
272+
events.SwapElements(mEvents);
272273

273274
uint32_t eventCount = events.Length();
274275
#ifdef A11Y_LOG

accessible/base/NotificationController.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -827,8 +827,8 @@ void NotificationController::WillRefresh(mozilla::TimeStamp aTime) {
827827
// etc. Therefore, they must be processed after relocations, since relocated
828828
// subtrees might not have been created before relocation processing and the
829829
// target might be inside a relocated subtree.
830-
const nsTArray<RefPtr<Notification>> notifications =
831-
std::move(mNotifications);
830+
nsTArray<RefPtr<Notification>> notifications;
831+
notifications.SwapElements(mNotifications);
832832

833833
uint32_t notificationCount = notifications.Length();
834834
for (uint32_t idx = 0; idx < notificationCount; idx++) {

accessible/ipc/other/DocAccessibleChild.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ static void AddRelation(Accessible* aAcc, RelationType aType,
177177
if (!targets.IsEmpty()) {
178178
RelationTargets* newRelation = aTargets->AppendElement(
179179
RelationTargets(static_cast<uint32_t>(aType), nsTArray<uint64_t>()));
180-
newRelation->Targets() = std::move(targets);
180+
newRelation->Targets().SwapElements(targets);
181181
}
182182
}
183183

docshell/base/timeline/ObservedDocShell.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ void ObservedDocShell::PopMarkers(
163163
}
164164
}
165165

166-
mTimelineMarkers = std::move(keptStartMarkers);
166+
mTimelineMarkers.SwapElements(keptStartMarkers);
167167
}
168168

169169
} // namespace mozilla

dom/animation/AnimationEventDispatcher.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,8 @@ class AnimationEventDispatcher final {
156156

157157
SortEvents();
158158

159-
EventArray events = std::move(mPendingEvents);
159+
EventArray events;
160+
mPendingEvents.SwapElements(events);
160161
// mIsSorted will be set to true by SortEvents above, and we leave it
161162
// that way since mPendingEvents is now empty
162163
for (AnimationEventInfo& info : events) {

dom/animation/KeyframeEffect.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -881,7 +881,7 @@ nsTArray<AnimationProperty> KeyframeEffect::BuildProperties(
881881
" should not be modified");
882882
#endif
883883

884-
mKeyframes = std::move(keyframesCopy);
884+
mKeyframes.SwapElements(keyframesCopy);
885885
return result;
886886
}
887887

dom/base/DOMIntersectionObserver.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,8 @@ void DOMIntersectionObserver::Disconnect() {
256256

257257
void DOMIntersectionObserver::TakeRecords(
258258
nsTArray<RefPtr<DOMIntersectionObserverEntry>>& aRetVal) {
259-
aRetVal = std::move(mQueuedEntries);
259+
aRetVal.SwapElements(mQueuedEntries);
260+
mQueuedEntries.Clear();
260261
}
261262

262263
static Maybe<nsRect> EdgeInclusiveIntersection(const nsRect& aRect,

dom/base/Document.cpp

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -6262,7 +6262,7 @@ void Document::UpdateFrameRequestCallbackSchedulingState(
62626262

62636263
void Document::TakeFrameRequestCallbacks(nsTArray<FrameRequest>& aCallbacks) {
62646264
MOZ_ASSERT(aCallbacks.IsEmpty());
6265-
aCallbacks = std::move(mFrameRequestCallbacks);
6265+
aCallbacks.SwapElements(mFrameRequestCallbacks);
62666266
mCanceledFrameRequestCallbacks.clear();
62676267
// No need to manually remove ourselves from the refresh driver; it will
62686268
// handle that part. But we do have to update our state.
@@ -8573,8 +8573,8 @@ void Document::MaybeInitializeFinalizeFrameLoaders() {
85738573

85748574
uint32_t length = mFrameLoaderFinalizers.Length();
85758575
if (length > 0) {
8576-
nsTArray<nsCOMPtr<nsIRunnable>> finalizers =
8577-
std::move(mFrameLoaderFinalizers);
8576+
nsTArray<nsCOMPtr<nsIRunnable>> finalizers;
8577+
mFrameLoaderFinalizers.SwapElements(finalizers);
85788578
for (uint32_t i = 0; i < length; ++i) {
85798579
finalizers[i]->Run();
85808580
}
@@ -11687,9 +11687,10 @@ bool Document::IsDocumentRightToLeft() {
1168711687

1168811688
class nsDelayedEventDispatcher : public Runnable {
1168911689
public:
11690-
explicit nsDelayedEventDispatcher(nsTArray<nsCOMPtr<Document>>&& aDocuments)
11691-
: mozilla::Runnable("nsDelayedEventDispatcher"),
11692-
mDocuments(std::move(aDocuments)) {}
11690+
explicit nsDelayedEventDispatcher(nsTArray<nsCOMPtr<Document>>& aDocuments)
11691+
: mozilla::Runnable("nsDelayedEventDispatcher") {
11692+
mDocuments.SwapElements(aDocuments);
11693+
}
1169311694
virtual ~nsDelayedEventDispatcher() = default;
1169411695

1169511696
NS_IMETHOD Run() override {
@@ -11721,17 +11722,16 @@ void Document::UnsuppressEventHandlingAndFireEvents(bool aFireEvents) {
1172111722

1172211723
if (aFireEvents) {
1172311724
MOZ_RELEASE_ASSERT(NS_IsMainThread());
11724-
nsCOMPtr<nsIRunnable> ded =
11725-
new nsDelayedEventDispatcher(std::move(documents));
11725+
nsCOMPtr<nsIRunnable> ded = new nsDelayedEventDispatcher(documents);
1172611726
Dispatch(TaskCategory::Other, ded.forget());
1172711727
} else {
1172811728
FireOrClearDelayedEvents(documents, false);
1172911729
}
1173011730

1173111731
if (!EventHandlingSuppressed()) {
1173211732
MOZ_ASSERT(NS_IsMainThread());
11733-
nsTArray<RefPtr<net::ChannelEventQueue>> queues =
11734-
std::move(mSuspendedQueues);
11733+
nsTArray<RefPtr<net::ChannelEventQueue>> queues;
11734+
mSuspendedQueues.SwapElements(queues);
1173511735
for (net::ChannelEventQueue* queue : queues) {
1173611736
queue->Resume();
1173711737
}
@@ -11767,8 +11767,8 @@ bool Document::SuspendPostMessageEvent(PostMessageEvent* aEvent) {
1176711767
}
1176811768

1176911769
void Document::FireOrClearPostMessageEvents(bool aFireEvents) {
11770-
nsTArray<RefPtr<PostMessageEvent>> events =
11771-
std::move(mSuspendedPostMessageEvents);
11770+
nsTArray<RefPtr<PostMessageEvent>> events;
11771+
events.SwapElements(mSuspendedPostMessageEvents);
1177211772

1177311773
if (aFireEvents) {
1177411774
for (PostMessageEvent* event : events) {

dom/base/Navigator.cpp

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -711,7 +711,8 @@ void VibrateWindowListener::RemoveListener() {
711711
void Navigator::SetVibrationPermission(bool aPermitted, bool aPersistent) {
712712
MOZ_ASSERT(NS_IsMainThread());
713713

714-
nsTArray<uint32_t> pattern = std::move(mRequestedVibrationPattern);
714+
nsTArray<uint32_t> pattern;
715+
pattern.SwapElements(mRequestedVibrationPattern);
715716

716717
if (!mWindow) {
717718
return;
@@ -786,7 +787,7 @@ bool Navigator::Vibrate(const nsTArray<uint32_t>& aPattern) {
786787
return true;
787788
}
788789

789-
mRequestedVibrationPattern = std::move(pattern);
790+
mRequestedVibrationPattern.SwapElements(pattern);
790791

791792
PermissionDelegateHandler* permissionHandler =
792793
doc->GetPermissionDelegateHandler();

dom/base/SameProcessMessageQueue.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,8 @@ void SameProcessMessageQueue::Push(Runnable* aRunnable) {
2929
}
3030

3131
void SameProcessMessageQueue::Flush() {
32-
const nsTArray<RefPtr<Runnable>> queue = std::move(mQueue);
32+
nsTArray<RefPtr<Runnable>> queue;
33+
mQueue.SwapElements(queue);
3334
for (size_t i = 0; i < queue.Length(); i++) {
3435
queue[i]->Run();
3536
}

0 commit comments

Comments
 (0)