зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1512037 - Bail out from prefersReducedMotion() if the target device is Android 4.1 or older. r=snorp
Settings.Global can't be used on such devices. Differential Revision: https://phabricator.services.mozilla.com/D14226 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
1b85c280bd
Коммит
6bebce8600
|
@ -91,6 +91,10 @@ public class GeckoSystemStateListener
|
|||
* Uses `Settings.Global` which was introduced in API version 17.
|
||||
*/
|
||||
private static boolean prefersReducedMotion() {
|
||||
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.JELLY_BEAN_MR1) {
|
||||
return false;
|
||||
}
|
||||
|
||||
ContentResolver contentResolver = sApplicationContext.getContentResolver();
|
||||
|
||||
return Settings.Global.getFloat(contentResolver,
|
||||
|
|
Загрузка…
Ссылка в новой задаче