From f641426d9ff5c25a876942f28197864e0ba1f3be Mon Sep 17 00:00:00 2001 From: althafvly Date: Wed, 16 Nov 2022 11:19:16 +0530 Subject: [PATCH] camera: Remove donation related items - Donation links are broken anyways --- .../sourceforge/opencamera/MainActivity.java | 13 --------- .../opencamera/MyPreferenceFragment.java | 28 ------------------- app/src/main/res/xml/preferences.xml | 6 ---- 3 files changed, 47 deletions(-) diff --git a/app/src/main/java/net/sourceforge/opencamera/MainActivity.java b/app/src/main/java/net/sourceforge/opencamera/MainActivity.java index d96073feb..8c66d6398 100644 --- a/app/src/main/java/net/sourceforge/opencamera/MainActivity.java +++ b/app/src/main/java/net/sourceforge/opencamera/MainActivity.java @@ -666,16 +666,6 @@ public class MainActivity extends AppCompatActivity { alertDialog.setTitle(R.string.whats_new); alertDialog.setMessage(R.string.whats_new_text); alertDialog.setPositiveButton(android.R.string.ok, null); - alertDialog.setNegativeButton(R.string.donate, new DialogInterface.OnClickListener() { - @Override - public void onClick(DialogInterface dialog, int which) { - if (MyDebug.LOG) - Log.d(TAG, "donate"); - // if we change this, remember that any page linked to must abide by Google Play developer policies! - Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse(MainActivity.DonateLink)); - startActivity(browserIntent); - } - }); showAlertDialog(alertDialog, "whats new dialog dismissed"); } } @@ -5518,9 +5508,6 @@ public class MainActivity extends AppCompatActivity { this.supports_force_video_4k = false; } - // if we change this, remember that any page linked to must abide by Google Play developer policies! - public static final String DonateLink = "https://play.google.com/store/apps/details?id=harman.mark.donation"; - public Preview getPreview() { return this.preview; } diff --git a/app/src/main/java/net/sourceforge/opencamera/MyPreferenceFragment.java b/app/src/main/java/net/sourceforge/opencamera/MyPreferenceFragment.java index 116646c3b..b43d8249b 100644 --- a/app/src/main/java/net/sourceforge/opencamera/MyPreferenceFragment.java +++ b/app/src/main/java/net/sourceforge/opencamera/MyPreferenceFragment.java @@ -1000,34 +1000,6 @@ public class MyPreferenceFragment extends PreferenceFragment implements OnShared }); } - { - final Preference pref = findPreference("preference_donate"); - pref.setOnPreferenceClickListener(new OnPreferenceClickListener() { - @Override - public boolean onPreferenceClick(Preference arg0) { - if( pref.getKey().equals("preference_donate") ) { - if( MyDebug.LOG ) - Log.d(TAG, "user clicked to donate"); - /*Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse(MainActivity.getDonateMarketLink())); - try { - startActivity(browserIntent); - } - catch(ActivityNotFoundException e) { - // needed in case market:// not supported - if( MyDebug.LOG ) - Log.d(TAG, "can't launch market:// intent"); - browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse(MainActivity.getDonateLink())); - startActivity(browserIntent); - }*/ - Intent browserIntent = new Intent(Intent.ACTION_VIEW, Uri.parse(MainActivity.DonateLink)); - startActivity(browserIntent); - return false; - } - return false; - } - }); - } - { final Preference pref = findPreference("preference_debug_info"); pref.setOnPreferenceClickListener(new OnPreferenceClickListener() { diff --git a/app/src/main/res/xml/preferences.xml b/app/src/main/res/xml/preferences.xml index 54e183574..6019e4588 100644 --- a/app/src/main/res/xml/preferences.xml +++ b/app/src/main/res/xml/preferences.xml @@ -1271,12 +1271,6 @@ android:icon="@drawable/ic_preference_help" /> - -