Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Daydream android SkipPermissionsDialog setting

Discussion in 'Daydream' started by zurrix, Dec 7, 2016.

  1. zurrix

    zurrix

    Joined:
    Aug 6, 2014
    Posts:
    15
    The daydream app exported from unity are currently build with
    <meta-data android:name="unityplayer.SkipPermissionsDialog" android:value="true" /> in AndroidManifest.xml

    But my app need these two permissions:

    <uses-permission android:name="android.permission.RECORD_AUDIO" />
    <uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />

    then it means that user will manually go to "Settings->Apps-> AppName-> Permissions" to allow these permissions.
    Is there anyway to not skip PermissionsDialog in daydream app?
     
  2. joejo

    joejo

    Unity Technologies

    Joined:
    May 26, 2016
    Posts:
    958
    You can create a custom AndroidManifest.xml in Assets/Plugins/Android where you can add these permissions and I believe override the SkipPermissionsDialog. This will then be merged into the AndroidManifest.xml in the APK.

    Having said that, this was done this way for a purpose. If you are in the Daydream VR Launcher and your headset on it would be considered a bad experience to have to take it off and remove the device just to clear the alerts. User experience is important not just in the application but in the use of the device, viewer and controller as well.
     
  3. zurrix

    zurrix

    Joined:
    Aug 6, 2014
    Posts:
    15
    Is there a plan for VR version permissions dialog?
     
  4. joejo

    joejo

    Unity Technologies

    Joined:
    May 26, 2016
    Posts:
    958
    My understanding is yes, but I have no information I can share with you about it. :-(
     
  5. fmielke

    fmielke

    Joined:
    Oct 17, 2016
    Posts:
    35
    I think the described steps "Settings->Apps-> AppName-> Permissions" from zurrix are more unsatisfactory than passing the permission dialog by one touch "Accept". Or did I understand something wrong?
     
  6. zurrix

    zurrix

    Joined:
    Aug 6, 2014
    Posts:
    15
    There's update with GVR 1.1, a demo about permissions included.
     
    fmielke likes this.
  7. fmielke

    fmielke

    Joined:
    Oct 17, 2016
    Posts:
    35
    @zurrix The built PermissionsDemo as apk doesn't work. Does it for you? If I click UI "Request Permission" the app asks me to take the phone out of the headset. If I do this, the animation is still the same. If I turn the phone to vertical, there is a button "RETURN TO VR". If I click it, I am back to the cubes with UI.