Repository: flutter
Issue: windows.locales returns different value depending on how app is run
Labels: framework,a: internationalization,d: api docs,P2,team-framework,triaged-framework

I was check the value of `window.locals` in different time of app running:

> 
 1. App start.
 2. `window.onLocaleChanged()` get called.
 3. User interact.

## Steps to Reproduce
1. Create new flutter project.
2. Update `main.dart` file as bellow.
3. Running app with debugging will see result 1.
4. Kill the app & directly open the app will see result 2.

```dart
import 'dart:async';
import 'dart:ui';
import 'package:flutter/material.dart';

void main() => runApp(MyApp());

class MyApp extends StatefulWidget {
  @override
  State<StatefulWidget> createState() => MyAppState();
}

class MyAppState extends State<MyApp> {
  var text = "empty";
  var textStreamController = StreamController<String>();

  @override
  void dispose() {
    textStreamController.close();
    super.dispose();
  }

  @override
  void initState() {
    super.initState();

    var localList = window.locales;      //<-----   this after: app start
    print(localList);

    text = 'Flutter Demo Home Page:${localList ?? "null"}';
    textStreamController.sink.add(text);

    window.onLocaleChanged = () {
      localList = window.locales;         //<-----   this after: onLocaleChanged
      text = 'Flutter Demo Home Page(New):${localList ?? "null"}';
      textStreamController.sink.add(text);
    };
  }

  void onClick() {
    var localList = window.locales;        //<-----   this after: user interact
    text = 'Flutter Demo Home Page(Click):${localList ?? "null"}';
    textStreamController.sink.add(text);
    showToast(localList ?? 'null');
  }

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Material(
        child: Center(
          child: Column(
            mainAxisAlignment: MainAxisAlignment.center,
            children: <Widget>[
              Text(text),
              StreamBuilder(
                stream: textStreamController.stream,
                builder: (context, AsyncSnapshot<String> snapshot) {
                  return Text(
                    '${snapshot.data}',
                    style: TextStyle(color: Colors.green),
                  );
                },
              ),
              FlatButton(
                onPressed: onClick,
                color: Colors.blue,
                child: Text('Click'),
              )
            ],
          ),
        ),
      ),
    );
  }
}

```

### The result when app `debug & running`:
[![enter image description here][1]][1][![enter image description here][2]][2]
### The result when `app stop debug & running`
[![enter image description here][3]][3][![enter image description here][4]][4]

## Is this as expected as design ? 

>   
 - The locals don't have initial value when `directly run` ?
 - The locals have initial value when `debugging` ?

  [1]: https://i.stack.imgur.com/iti9G.png
  [2]: https://i.stack.imgur.com/pJf17.png
  [3]: https://i.stack.imgur.com/30qaG.png
  [4]: https://i.stack.imgur.com/uGUjH.png