Top

Test still connected

Répondu

Commentaires

2 commentaires

  • Pascal BORSCHNECK

    Hi Alexandre,

     

    I'll ask the Android team to have a look.

     

    Best regards,
    Pascal

    0
    Actions pour les commentaires Permalien
  • Pascal BORSCHNECK

    Hi,

    I got a reply.

    For the moment, before allowing partners/dev to add needed certificates for PUSH for the company/appId on prod server, the only way is to not go in DOZE mode.

    Here is a part of code:

    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M)
    {
        String packageName = getPackageName();
        PowerManager pm = (PowerManager) getSystemService(Context.POWER_SERVICE);
        if (!pm.isIgnoringBatteryOptimizations(packageName))
        {
            Intent intent = new Intent(Settings.ACTION_REQUEST_IGNORE_BATTERY_OPTIMIZATIONS);
            intent.setData(Uri.parse("package:" + packageName));

            if (!getPackageManager().queryIntentActivities(intent, 0).isEmpty())
                startActivity(intent);
        }
    }

    Please stay tuned for updates by subscribing to the newsletter from the Rainbow API Hub Web site https://hub.openrainbow.com (click on « Subscribe to the Rainbow API HUB Newsletter »).

    Best regards,
    Pascal

    0
    Actions pour les commentaires Permalien

Vous devez vous connecter pour laisser un commentaire.

  • Demandez à la Communauté

    Vous avez besoin d'aide? Posez vos questions à la Communauté et obtenez des réponses d'autres utilisateurs Rainbow.

    Poster un message