Skip to content

[Request]: [device_info_plus] add flag to AndroidDeviceInfo to indicate Android app running in Google Play Games on PC #3702

@ekuleshov

Description

@ekuleshov

Plugin

device_info_plus

Use case

Android apps/games could run on the Google Play Games on PC, i.e. on Windows.
https://developer.android.com/games/playgames/overview

So, a Flutter app build for Android and distributed through Google Play store could run on Windows PC and to fully support input and other things required by Google Play Games the app may need to know if it is running in this environment.

Proposal

The request is to introduce a new flag like AndroidDeviceInfo.isGooglePlayGames (somewhat similar to IosDeviceInfo.isiOSAppOnMac). The value is a simple check:

PackageManager pm = getPackageManager();
boolean isPC = pm.hasSystemFeature("com.google.android.play.feature.HPE_EXPERIENCE")

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions