getScreenInfos method

Future<List<ScreenInfo>> getScreenInfos()

Returns device's screen configuration. In headful mode, the physical screens configuration is returned, whereas in headless mode, a virtual headless screen configuration is provided instead.

Implementation

Future<List<ScreenInfo>> getScreenInfos() async {
  var result = await _client.send('Emulation.getScreenInfos');
  return (result['screenInfos'] as List)
      .map((e) => ScreenInfo.fromJson(e as Map<String, dynamic>))
      .toList();
}