Compare commits
10 Commits
e0f4ecaea8
...
67c60cd216
Author | SHA1 | Date | |
---|---|---|---|
67c60cd216 | |||
728f17474f | |||
c2ba10f4cb | |||
323ccbae66 | |||
b9b6b88665 | |||
913fba9f1d | |||
4f833bea53 | |||
a0fc0f9940 | |||
682feba303 | |||
0bdca04f01 |
@ -6,14 +6,14 @@ plugins {
|
|||||||
|
|
||||||
android {
|
android {
|
||||||
namespace 'social.snort.app'
|
namespace 'social.snort.app'
|
||||||
compileSdk 33
|
compileSdk 34
|
||||||
|
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId "social.snort.app"
|
applicationId "social.snort.app"
|
||||||
minSdk 26
|
minSdk 26
|
||||||
targetSdk 33
|
targetSdk 34
|
||||||
versionCode 13
|
versionCode 21
|
||||||
versionName "0.1.18"
|
versionName "0.3.0"
|
||||||
|
|
||||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
vectorDrawables {
|
vectorDrawables {
|
||||||
|
@ -3,16 +3,16 @@
|
|||||||
xmlns:tools="http://schemas.android.com/tools">
|
xmlns:tools="http://schemas.android.com/tools">
|
||||||
|
|
||||||
<application
|
<application
|
||||||
android:allowBackup="false"
|
|
||||||
android:name=".Snort"
|
android:name=".Snort"
|
||||||
|
android:allowBackup="false"
|
||||||
android:dataExtractionRules="@xml/data_extraction_rules"
|
android:dataExtractionRules="@xml/data_extraction_rules"
|
||||||
android:fullBackupContent="@xml/backup_rules"
|
android:fullBackupContent="@xml/backup_rules"
|
||||||
|
android:hardwareAccelerated="true"
|
||||||
android:icon="@mipmap/ic_launcher"
|
android:icon="@mipmap/ic_launcher"
|
||||||
android:label="@string/app_name"
|
android:label="@string/app_name"
|
||||||
android:roundIcon="@mipmap/ic_launcher_round"
|
android:roundIcon="@mipmap/ic_launcher_round"
|
||||||
android:supportsRtl="true"
|
android:supportsRtl="true"
|
||||||
android:theme="@style/AppTheme"
|
android:theme="@style/AppTheme"
|
||||||
android:hardwareAccelerated="true"
|
|
||||||
android:usesCleartextTraffic="true"
|
android:usesCleartextTraffic="true"
|
||||||
tools:targetApi="31">
|
tools:targetApi="31">
|
||||||
<activity
|
<activity
|
||||||
@ -23,11 +23,21 @@
|
|||||||
<action android:name="android.intent.action.MAIN" />
|
<action android:name="android.intent.action.MAIN" />
|
||||||
<category android:name="android.intent.category.LAUNCHER" />
|
<category android:name="android.intent.category.LAUNCHER" />
|
||||||
</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="https" />
|
||||||
|
<data android:host="snort.social" />
|
||||||
|
</intent-filter>
|
||||||
</activity>
|
</activity>
|
||||||
</application>
|
</application>
|
||||||
|
|
||||||
<uses-permission android:name="android.permission.INTERNET" />
|
<uses-permission android:name="android.permission.INTERNET" />
|
||||||
<uses-permission android:name="android.permission.READ_CLIPBOARD" />
|
<uses-permission android:name="android.permission.READ_CLIPBOARD" />
|
||||||
<uses-permission android:name="android.permission.WRITE_CLIPBOARD" />
|
<uses-permission android:name="android.permission.WRITE_CLIPBOARD" />
|
||||||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
<uses-permission android:name="android.permission.READ_MEDIA_IMAGES" />
|
||||||
|
<uses-permission android:name="android.permission.READ_MEDIA_VIDEO" />
|
||||||
</manifest>
|
</manifest>
|
@ -1,6 +1,7 @@
|
|||||||
package social.snort.app
|
package social.snort.app
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
|
import android.content.Intent.ACTION_VIEW
|
||||||
import android.net.Uri
|
import android.net.Uri
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.webkit.PermissionRequest
|
import android.webkit.PermissionRequest
|
||||||
@ -54,11 +55,22 @@ class MainActivity : ComponentActivity() {
|
|||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
webView.settings.domStorageEnabled = true
|
webView.settings.domStorageEnabled = true;
|
||||||
webView.settings.javaScriptEnabled = true
|
webView.settings.javaScriptEnabled = true;
|
||||||
webView.settings.databaseEnabled = true;
|
webView.settings.databaseEnabled = true;
|
||||||
|
webView.setRendererPriorityPolicy(WebView.RENDERER_PRIORITY_IMPORTANT, true);
|
||||||
setContentView(webView)
|
setContentView(webView)
|
||||||
webView.loadUrl("https://appassets.androidplatform.net/")
|
|
||||||
|
if (intent.data != null && intent.action === ACTION_VIEW) {
|
||||||
|
webView.loadUrl(
|
||||||
|
Uri.withAppendedPath(
|
||||||
|
Uri.parse("https://appassets.androidplatform.net/"),
|
||||||
|
intent.data!!.path
|
||||||
|
).toString()
|
||||||
|
)
|
||||||
|
} else {
|
||||||
|
webView.loadUrl("https://appassets.androidplatform.net/")
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onBackPressed() {
|
override fun onBackPressed() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user