Skip to content
This repository has been archived by the owner on Mar 9, 2024. It is now read-only.

ContentProvider not found #26

Closed
bigvanstudio opened this issue Jul 30, 2018 · 4 comments
Closed

ContentProvider not found #26

bigvanstudio opened this issue Jul 30, 2018 · 4 comments

Comments

@bigvanstudio
Copy link

bigvanstudio commented Jul 30, 2018

I am testing the plugin on Android and when I try to share a video, noting occurs. Using the monitor app to check the console, when I try to share the video, the log shows something like "ContentProvider not found!".

I added this AndroidManifest.xml in the Assets/Plugins directory:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.unity3d.player" xmlns:tools="http://schemas.android.com/tools" android:installLocation="preferExternal">
  <supports-screens android:smallScreens="true" android:normalScreens="true" android:largeScreens="true" android:xlargeScreens="true" android:anyDensity="true" />
  <application android:theme="@style/UnityThemeSelector" android:icon="@drawable/app_icon" android:label="@string/app_name">
    <activity android:name="com.unity3d.player.UnityPlayerActivity" android:label="@string/app_name">
      <intent-filter>
        <action android:name="android.intent.action.MAIN" />
        <category android:name="android.intent.category.LAUNCHER" />
      </intent-filter>
      <meta-data android:name="unityplayer.UnityActivity" android:value="true" />
    </activity>
    <provider android:name="com.yasirkula.unity.UnitySSContentProvider" android:authorities="[here I put my bundle indentifier]" android:exported="false" android:grantUriPermissions="true" />
  </application>
</manifest>

The same message is shown in the console and the video can not be shared. I have been struggling with this all the day and I do not find the problem..

Any idea?

Many thanks in advance!!

@dvillaseca
Copy link

dvillaseca commented Aug 1, 2018

you have to define the android:authorities variable
you can find it on PlayerSettings(android)->other settings->packagename

@yasirkula
Copy link
Owner

You have to put AndroidManifest.xml into the Assets/Plugins/Android directory.

@brijesh-brk
Copy link

There may be missplacement of Manifest.xml.
Make sure above file must be in Asset/Plugin/Android alongwith proper provider tag.

@yasirkula
Copy link
Owner

With the latest release, ContentProvider is automatically added to the AndroidManifest with a unique authorities string. So hopefully we will no longer encounter this issue.

P.S. Asset Store version isn't updated yet, only the GitHub version is up-to-date.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants