mirror of
https://github.com/love2d/love-android.git
synced 2026-08-19 20:20:25 +02:00
Fix *.love file association in Nougat and later.
Note that the file association is rather hacky but I can't find any method which is compatible in Nougat and later as file:// URI is banned there.
This commit is contained in:
@@ -3,7 +3,7 @@
|
|||||||
android:installLocation="auto" xmlns:android="http://schemas.android.com/apk/res/android">
|
android:installLocation="auto" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
<uses-permission android:name="android.permission.INTERNET"/>
|
<uses-permission android:name="android.permission.INTERNET"/>
|
||||||
<uses-permission android:name="android.permission.VIBRATE"/>
|
<uses-permission android:name="android.permission.VIBRATE"/>
|
||||||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" android:maxSdkVersion="18" />
|
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
||||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" android:maxSdkVersion="18" />
|
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" android:maxSdkVersion="18" />
|
||||||
|
|
||||||
<!-- OpenGL ES 2.0 -->
|
<!-- OpenGL ES 2.0 -->
|
||||||
@@ -35,6 +35,22 @@
|
|||||||
<data android:pathPattern=".*\\.love" />
|
<data android:pathPattern=".*\\.love" />
|
||||||
<data android:host="*" />
|
<data android:host="*" />
|
||||||
</intent-filter>
|
</intent-filter>
|
||||||
|
<intent-filter>
|
||||||
|
<action android:name="android.intent.action.VIEW" />
|
||||||
|
<category android:name="android.intent.category.DEFAULT" />
|
||||||
|
<category android:name="android.intent.category.BROWSABLE" />
|
||||||
|
<data android:scheme="content" />
|
||||||
|
<data android:host="*" />
|
||||||
|
<data android:mimeType="application/x-love-game" />
|
||||||
|
</intent-filter>
|
||||||
|
<intent-filter>
|
||||||
|
<action android:name="android.intent.action.VIEW" />
|
||||||
|
<category android:name="android.intent.category.DEFAULT" />
|
||||||
|
<category android:name="android.intent.category.BROWSABLE" />
|
||||||
|
<data android:scheme="content" />
|
||||||
|
<data android:host="*" />
|
||||||
|
<data android:mimeType="*/*" />
|
||||||
|
</intent-filter>
|
||||||
</activity>
|
</activity>
|
||||||
<activity
|
<activity
|
||||||
android:name="org.love2d.android.DownloadActivity"
|
android:name="org.love2d.android.DownloadActivity"
|
||||||
|
|||||||
@@ -67,6 +67,10 @@ public class GameActivity extends SDLActivity {
|
|||||||
Log.d("GameActivity", "Vibration disabled: could not get vibration permission.");
|
Log.d("GameActivity", "Vibration disabled: could not get vibration permission.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// These 2 variables must be reset or it will use the existing value.
|
||||||
|
gamePath = "";
|
||||||
|
storagePermissionUnnecessary = false;
|
||||||
|
|
||||||
handleIntent(this.getIntent());
|
handleIntent(this.getIntent());
|
||||||
|
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
|
|||||||
Reference in New Issue
Block a user