Skip to content

Commit

Permalink
Bug 1638064 - Removed toolkit.cosmeticAnimations.enabled pref and rep…
Browse files Browse the repository at this point in the history
…laced it with "prefers-reduced-motion" in CFRPageActions r=dao

Differential Revision: https://phabricator.services.mozilla.com/D76761
  • Loading branch information
AllegroFox committed May 28, 2020
1 parent b8c2533 commit 0bb753a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions browser/components/newtab/lib/CFRPageActions.jsm
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ const SUMO_BASE_URL = Services.urlFormatter.formatURLPref(
);
const ADDONS_API_URL =
"https://services.addons.mozilla.org/api/v3/addons/addon";
const ANIMATIONS_ENABLED_PREF = "toolkit.cosmeticAnimations.enabled";

const DELAY_BEFORE_EXPAND_MS = 1000;
const CATEGORY_ICONS = {
Expand Down Expand Up @@ -476,7 +475,7 @@ class PageAction {

animationContainer.toggleAttribute(
"animate",
Services.prefs.getBoolPref(ANIMATIONS_ENABLED_PREF, true)
!this.window.matchMedia("(prefers-reduced-motion: reduce)").matches
);
animationContainer.removeAttribute("paused");

Expand Down

0 comments on commit 0bb753a

Please sign in to comment.