Repository: flutter
Issue: AccessibilityFeatures.disableAnimations flag is not set on app startup and animations are not disabled in app running on Android 12+ device.
Labels: platform-android,engine,a: accessibility,e: OS-version specific,has reproducible steps,P2,found in release: 3.10,team-android,triaged-android,found in release: 3.13

### Is there an existing issue for this?

- [X] I have searched the [existing issues](https://github.com/flutter/flutter/issues)
- [X] I have read the [guide to filing a bug](https://flutter.dev/docs/resources/bug-reports)

### Steps to reproduce

1. On Android 12+ device disable animations from Settings > Accessibility > Remove animations.
2. Run the app **flutter run --release** (does not matter if in release, profile or debug mode, we have this bug in live app also).
3. Observe AccessibilityFeatures.disableAnimations flag is not set, animations are not removed.
4. Put the app to backgound (do not close it), and change the "Remove animations" setting off and on again from Settings > Accessibility > Remove animations.
5. Open app from recents, observe AccessibilityFeatures.disableAnimations flag is updated and set after few seconds and animations are disabled.

### Expected results

App animations are disabled on Android 12+. 

### Actual results

Animations are not disabled.

### Code sample

<details><summary>Code sample</summary>

```dart
import 'dart:ui';

import 'package:flutter/material.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Accessibility disableAnimations example',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: const SlideAnimationDemo(),
    );
  }
}

class SlideAnimationDemo extends StatefulWidget {
  const SlideAnimationDemo({super.key});

  @override
  State<SlideAnimationDemo> createState() => _SlideAnimationDemoState();
}

class _SlideAnimationDemoState extends State<SlideAnimationDemo>
    with SingleTickerProviderStateMixin, WidgetsBindingObserver {
  late AnimationController _animationController;
  late Animation<Offset> _slideAnimation;
  String features = '';

  @override
  void initState() {
    super.initState();

    WidgetsBinding.instance.addObserver(this);

    _animationController = AnimationController(
      vsync: this,
      duration: const Duration(milliseconds: 1000),
    );

    _slideAnimation = Tween<Offset>(
      begin: const Offset(-1.0, 0.0),
      end: Offset.zero,
    ).animate(CurvedAnimation(
      parent: _animationController,
      curve: Curves.easeInOut,
    ));

    features = PlatformDispatcher.instance.accessibilityFeatures.toString();
  }

  @override
  void dispose() {
    _animationController.dispose();
    WidgetsBinding.instance.removeObserver(this);
    super.dispose();
  }

  void _playAnimation() {
    if (_animationController.status == AnimationStatus.completed) {
      _animationController.reverse();
    } else {
      _animationController.forward();
    }
  }

  @override
  void didChangeAccessibilityFeatures() {
    final newFeatures =
        PlatformDispatcher.instance.accessibilityFeatures.toString();
    debugPrint("didChangeAccessibilityFeatures $newFeatures");
    setState(() {
      features = newFeatures;
    });
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: const Text('Slide animation demo'),
      ),
      body: Center(
        child: Column(
          mainAxisAlignment: MainAxisAlignment.center,
          children: [
            const SizedBox(height: 20),
            Text(features),
            const SizedBox(height: 20),
            SlideTransition(
              position: _slideAnimation,
              child: Container(
                width: 100,
                height: 100,
                color: Colors.red,
              ),
            ),
            const SizedBox(height: 20),
            ElevatedButton(
              onPressed: _playAnimation,
              child: const Text('Animate'),
            ),
          ],
        ),
      ),
    );
  }
}

```

</details>


### Screenshots or Video

<details>
<summary>Screenshots / Video demonstration</summary>

[Upload media here]

</details>


### Logs

<details><summary>Logs</summary>

```console
[Paste your logs here]
```

</details>


### Flutter Doctor output

<details><summary>Doctor output</summary>

```console
[√] Flutter (Channel stable, 3.10.6, on Microsoft Windows [Version 10.0.19044.3086], locale et-EE)
    • Flutter version 3.10.6 on channel stable at C:\Users\sande\fvm\versions\3.10.6
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision f468f3366c (8 days ago), 2023-07-12 15:19:05 -0700
    • Engine revision cdbeda788a
    • Dart version 3.0.6
    • DevTools version 2.23.1

[√] Windows Version (Installed version of Windows is version 10 or higher)

[√] Android toolchain - develop for Android devices (Android SDK version 33.0.2)
    • Android SDK at C:\Users\sande\AppData\Local\Android\sdk
    • Platform android-33, build-tools 33.0.2
    • ANDROID_HOME = C:\Users\sande\AppData\Local\Android\sdk
    • Java binary at: C:\Program Files\Android\Android Studio\jbr\bin\java      
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-b2043.56-9586694)
    • All Android licenses accepted.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe     

[√] Visual Studio - develop for Windows (Visual Studio Community 2022 17.2.3)   
    • Visual Studio at C:\Program Files\Microsoft Visual Studio\2022\Community  
    • Visual Studio Community 2022 version 17.2.32526.322
    • Windows 10 SDK version 10.0.19041.0

[√] Android Studio (version 2022.2)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin can be installed from:
       https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
       https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-b2043.56-9586694)

[√] IntelliJ IDEA Community Edition (version 2019.3)
    • IntelliJ at C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2019.3.1
    • Flutter plugin can be installed from:
       https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
       https://plugins.jetbrains.com/plugin/6351-dart

[√] IntelliJ IDEA Community Edition (version 2022.1)
    • IntelliJ at C:\Program Files\JetBrains\IntelliJ IDEA Community Edition 2022.1.1
    • Flutter plugin can be installed from:
       https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
       https://plugins.jetbrains.com/plugin/6351-dart

[√] VS Code, 64-bit edition (version 1.80.0)
    • VS Code at C:\Program Files\Microsoft VS Code
    • Flutter extension version 3.68.0

[√] Connected device (4 available)
    • Pixel 3 XL (mobile) • 8ABY0HG2L • android-arm64  • Android 12 (API 31)
    • Windows (desktop)   • windows   • windows-x64    • Microsoft Windows [Version 10.0.19044.3086]
    • Chrome (web)        • chrome    • web-javascript • Google Chrome 114.0.5735.199
    • Edge (web)          • edge      • web-javascript • Microsoft Edge 114.0.1823.55

[√] Network resources
    • All expected network resources are available.

• No issues found!
```

</details>