diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml index 3fb0ce0..f6467a4 100644 --- a/.github/FUNDING.yml +++ b/.github/FUNDING.yml @@ -1 +1 @@ -custom: ["https://paypal.me/jnthnkl"] +custom: ["https://www.paypal.com/donate/?hosted_button_id=RE3PM6W85N5HW"] diff --git a/README.md b/README.md index 64453ba..c25fb3f 100644 --- a/README.md +++ b/README.md @@ -84,7 +84,7 @@ curl -X GET "https://sapio.ovh/api/upload/files?filters\[name\]\[\$eq\]=com.open # ☕ Coffee -If you want to offer me a coffee for the maintenance of the server part: https://paypal.me/jnthnkl +If you want to offer me a coffee for the maintenance of the server part: [Donate](https://www.paypal.com/donate/?hosted_button_id=RE3PM6W85N5HW) # 👏 Credits diff --git a/app/src/main/java/com/klee/sapio/ui/view/MainActivity.kt b/app/src/main/java/com/klee/sapio/ui/view/MainActivity.kt index 2a0c5a6..cd6354c 100644 --- a/app/src/main/java/com/klee/sapio/ui/view/MainActivity.kt +++ b/app/src/main/java/com/klee/sapio/ui/view/MainActivity.kt @@ -1,6 +1,7 @@ package com.klee.sapio.ui.view import android.content.Intent +import android.net.Uri import android.os.Bundle import android.view.Menu import android.view.MenuInflater @@ -16,6 +17,10 @@ class MainActivity : AppCompatActivity() { private lateinit var mBinding: ActivityMainBinding + companion object { + const val DONATE_URL = "https://www.paypal.com/donate/?hosted_button_id=RE3PM6W85N5HW" + } + override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) @@ -51,6 +56,10 @@ class MainActivity : AppCompatActivity() { startActivity(intent) return true } + R.id.donate -> { + startActivity(Intent(Intent.ACTION_VIEW, Uri.parse(DONATE_URL))) + return true + } else -> super.onOptionsItemSelected(item) } } diff --git a/app/src/main/res/menu/menu.xml b/app/src/main/res/menu/menu.xml index 823ddba..da9bf54 100644 --- a/app/src/main/res/menu/menu.xml +++ b/app/src/main/res/menu/menu.xml @@ -2,4 +2,6 @@
diff --git a/app/src/main/res/values-fr/strings.xml b/app/src/main/res/values-fr/strings.xml index 810897b..49019f8 100644 --- a/app/src/main/res/values-fr/strings.xml +++ b/app/src/main/res/values-fr/strings.xml @@ -24,6 +24,7 @@