getDevicePixelRatio method

double getDevicePixelRatio()

Implementation

double getDevicePixelRatio() {
  final views = PlatformDispatcher.instance.views;
  return views.isEmpty ? 1.0 : views.first.devicePixelRatio;
}