Repository: flutter
Issue: Strange behaviour of MediaQuery.of(context).size on locked screen
Labels: framework,f: scrolling,has reproducible steps,P3,team-framework,triaged-framework,found in release: 3.13,found in release: 3.15

### 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. Run the code on Android with locked screen
2. Unlock screen when the code installed to the device


### Expected results

"text" in the upper left corner

### Actual results

the screen is empty

### Code sample

<details><summary>Code sample</summary>

```dart
import 'package:flutter/material.dart';

class Application extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: ListView.builder(
        itemCount: 1,
        itemBuilder: (context, index) {
          return SizedBox(
            height: MediaQuery.of(context).size.height / 4,
            width: MediaQuery.of(context).size.width / 4,
            child: Text("text"),
          );
        },
      ),
    );
  }
}

void main() async {
  runApp(MaterialApp(home: Application()));
}

```

</details>


### Screenshots or Video

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


### Logs

<details><summary>Logs</summary>

```console
Launching lib\main.dart on itel S661LPN in debug mode...
Picked up _JAVA_OPTIONS: -Xmx2048M
√  Built build\app\outputs\flutter-apk\app-debug.apk.
Connecting to VM Service at ws://127.0.0.1:59155/l-CwFGFfycg=/ws
I/ActivityThread(29027): smart_link is  not supported!!!
D/IMGGralloc(29027): Gralloc Register  w:720, h:1612, f:0x1, usage:0xb00, ui64Stamp:153624, sSize:4657152, line = 2335
D/IMGGralloc(29027): Gralloc Register  w:720, h:1612, f:0x1, usage:0xb00, ui64Stamp:153659, sSize:4657152, line = 2335```

</details>


### Flutter Doctor output

<details><summary>Doctor output</summary>

```console
[√] Flutter (Channel stable, 3.13.3, on Microsoft Windows [Version 10.0.19045.3448], locale
    en-US)
    • Flutter version 3.13.3 on channel stable at c:\flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 2524052335 (3 weeks ago), 2023-09-06 14:32:31 -0700
    • Engine revision b8d35810e9
    • Dart version 3.1.1
    • DevTools version 2.25.0

[√] 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\brand17\AppData\Local\Android\sdk
    • Platform android-33-ext4, build-tools 33.0.2
    • Java binary at: C:\Program Files\Android\Android Studio\jbr\bin\java
    • Java version OpenJDK Runtime Environment (build 11.0.15+0-b2043.56-9505619)
    • All Android licenses accepted.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe

[√] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.5.0)
    • Visual Studio at C:\Program Files\Microsoft Visual Studio\2022\Community
    • Visual Studio Community 2022 version 17.5.33414.496
    • Windows 10 SDK version 10.0.22000.0

[√] Android Studio (version 2022.1)
    • 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 version "11.0.15" 2022-04-19

[√] VS Code (version 1.82.2)
    • VS Code at C:\Users\brand17\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 3.72.0

[√] Connected device (4 available)
    • itel S661LPN (mobile) • 078453724R000308 • android-arm64  • Android 11 (API 30)        
    • Windows (desktop)     • windows          • windows-x64    • Microsoft Windows [Version 
      10.0.19045.3448]
    • Chrome (web)          • chrome           • web-javascript • Google Chrome
      116.0.5845.188
    • Edge (web)            • edge             • web-javascript • Microsoft Edge
      116.0.1938.62

[√] Network resources
    • All expected network resources are available.

• No issues found!
```

</details>