diff --git a/.idea/misc.xml b/.idea/misc.xml index 02a7102c..d84d1f1a 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -1,4 +1,3 @@ - diff --git a/app/src/main/java/nethical/digipaws/ui/fragments/anti_uninstall/SetupPasswordModeFragment.kt b/app/src/main/java/nethical/digipaws/ui/fragments/anti_uninstall/SetupPasswordModeFragment.kt index 40ca2ae4..71b613dc 100644 --- a/app/src/main/java/nethical/digipaws/ui/fragments/anti_uninstall/SetupPasswordModeFragment.kt +++ b/app/src/main/java/nethical/digipaws/ui/fragments/anti_uninstall/SetupPasswordModeFragment.kt @@ -6,6 +6,7 @@ import android.os.Bundle import android.view.LayoutInflater import android.view.View import android.view.ViewGroup +import android.widget.Toast import androidx.fragment.app.Fragment import com.google.android.material.dialog.MaterialAlertDialogBuilder import nethical.digipaws.Constants @@ -31,12 +32,36 @@ class SetupPasswordModeFragment : Fragment() { super.onViewCreated(view, savedInstanceState) binding.btnNextPass.setOnClickListener { + val password = binding.password.text.toString() + val confirmPassword = binding.confirmPassword.text.toString() + + if (password.isEmpty()) { + binding.textInputLayout3.error = getString(R.string.password_cannot_be_empty) + return@setOnClickListener + } else { + binding.textInputLayout3.error = null + } + + if (confirmPassword.isEmpty()) { + binding.confirmPasswordLayout.error = getString(R.string.confirm_password_cannot_be_empty) + return@setOnClickListener + } else { + binding.confirmPasswordLayout.error = null + } + + if (password != confirmPassword) { + binding.confirmPasswordLayout.error = getString(R.string.passwords_do_not_match) + return@setOnClickListener + } else { + binding.confirmPasswordLayout.error = null + } + MaterialAlertDialogBuilder(requireContext()) .setTitle(getString(R.string.alert)) .setMessage(getString(R.string.are_you_sure_you_want_to_turn_on_anti_uninstall_there_is_no_turning_back)) .setPositiveButton(getString(R.string.i_understand)) { _, _ -> - setupPasswordMode() + setupPasswordMode(password) } .setNegativeButton(getString(R.string.cancel)) { _, dialog -> requireActivity().finish() @@ -56,12 +81,12 @@ class SetupPasswordModeFragment : Fragment() { } - private fun setupPasswordMode() { + private fun setupPasswordMode(password: String) { val editor = activity?.getSharedPreferences("anti_uninstall", Context.MODE_PRIVATE)?.edit() editor?.apply() { putBoolean("is_anti_uninstall_on", true) - putString("password", binding.password.text.toString()) + putString("password", password) putInt("mode", Constants.ANTI_UNINSTALL_PASSWORD_MODE) putBoolean("is_configuring_blocked", binding.cbBlockChanges.isChecked) commit() diff --git a/app/src/main/res/layout/fragment_setup_password_mode.xml b/app/src/main/res/layout/fragment_setup_password_mode.xml index b75efc84..a0d1d613 100644 --- a/app/src/main/res/layout/fragment_setup_password_mode.xml +++ b/app/src/main/res/layout/fragment_setup_password_mode.xml @@ -41,6 +41,20 @@ + + + + + + تلاش مجدد زمان آغاز: %1$d:%2$d زمان پایان باید بعد از زمان آغاز گذشته باشد! - زمان پایان: %02d:%02d - زمان آغاز: %02d:%02d + زمان پایان: %1$02d:%2$02d + زمان آغاز: %1$02d:%2$02d مشخص کردن ساعت‌های تقلب شما هنوز %1$d روز تا باز کردن ضد پاک‌شدن دارید افزودن یک واژه کلیدی جدید @@ -158,4 +158,5 @@ برنامه‌ریزی یک سرقت لطفاً مجوز نمایش روی سایر برنامه‌ها را برای دسترسی به این ویژگی فراهم کنید دیجی‌پاز را پیدا کنید و روی فعال‌سازی فشار دهید + اگر این گزینه را فعال کنید، تا زمانی که ضد حذف را حذف نکنید، نمی‌توانید پیکربندی‌هایی مانند افزودن برنامه‌ها، کلمات کلیدی مسدود شده و موارد دیگر را تغییر دهید. تغییرات موجود شما برای کل دوره استفاده خواهد شد. diff --git a/app/src/main/res/values-fr/strings.xml b/app/src/main/res/values-fr/strings.xml index 1419b507..f636bf2e 100644 --- a/app/src/main/res/values-fr/strings.xml +++ b/app/src/main/res/values-fr/strings.xml @@ -117,8 +117,8 @@ Réésayer Temps de début: %1$d:%2$d Temps de fin doit être après que le temps de début soit passé! - Temps de fin: %02d:%02d - Temps de début: %02d:%02d + Temps de fin: %1$02d:%2$02d + Temps de début: %1$02d:%2$02d Specifiez les heures de triche Vous avez encore %1$d jours avant de débloquer l\'Anti-Désinstaller Ajouter un nouveau mot-clé diff --git a/app/src/main/res/values-pt-rBR/strings.xml b/app/src/main/res/values-pt-rBR/strings.xml index 1580ad6f..2f443787 100644 --- a/app/src/main/res/values-pt-rBR/strings.xml +++ b/app/src/main/res/values-pt-rBR/strings.xml @@ -115,8 +115,8 @@ Ativar isso desbloquearia o seguinte no DigiPaws:\n1. Contar o número de reels/ Repetir Hora de início: %1$d:%2$d A hora de término deve ser depois que a hora de início tiver passado! - Hora de término: %02d:%02d - Hora de início: %02d:%02d + Hora de término: %1$02d:%2$02d + Hora de início: %1$02d:%2$02d Especificar horas de trapaça Você ainda tem %1$d dias para desbloquear o anti-uninstall Adicionar uma nova palavra-chave diff --git a/app/src/main/res/values-tr/strings.xml b/app/src/main/res/values-tr/strings.xml index a50c14e9..eb8ad1fc 100644 --- a/app/src/main/res/values-tr/strings.xml +++ b/app/src/main/res/values-tr/strings.xml @@ -118,8 +118,8 @@ Tekrar Dene Başlangıç Zamanı: %1$d:%2$d Bitiş saati, başlangıç saatinden sonra olmalıdır! - Bitiş Zamanı: %02d:%02d - Başlangıç Zamanı: %02d:%02d + Bitiş Zamanı: %1$02d:%2$02d + Başlangıç Zamanı: %1$02d:%2$02d Kaçamak Saatlerini Belirt Kaldırma korumasının kilidini açmadan önce %1$d gününüz daha var Yeni bir anahtar kelime ekle diff --git a/app/src/main/res/values-zh-rCN/strings.xml b/app/src/main/res/values-zh-rCN/strings.xml index 150bd95d..eedf7abb 100644 --- a/app/src/main/res/values-zh-rCN/strings.xml +++ b/app/src/main/res/values-zh-rCN/strings.xml @@ -114,8 +114,8 @@ Retry Start Time: %1$d:%2$d End time must be after start time has passed! - End Time: %02d:%02d - Start Time: %02d:%02d + End Time: %1$02d:%2$02d + Start Time: %1$02d:%2$02d Specify Cheat Hours %1$d 天后你才能关闭防卸载 添加新关键词 diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index df031ed7..58f1bee4 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -21,7 +21,7 @@ Manage Keyword Packs Enable Keyword Blocker Accessibility Service to manage blocked keywords Grayscale Filter - Setup Filter"> + Setup Filter Usage Stats Manage Real Time Overlay Enable Usage Tracker Accessibility Service to manage trackers @@ -29,9 +29,9 @@ Add Cheat Hours Add Save - Today\'s Stats - You scrolled %2$d reels - Your average attention span was %2$d mins + Todays Stats + You scrolled %1$d reels + Your average attention span was %1$d mins View More Number of Reels Scrolled Average Attention Span @@ -47,6 +47,10 @@ Specify duration of focus mode in mins Block Adult Keywords Password + Confirm Password + Password cannot be empty + Confirm password cannot be empty + Passwords do not match Specify cooldown interval in minutes Warning message Allow viewing instagram reels sent in Instagram inbox @@ -87,9 +91,9 @@ Rest assured, all accessibility data stays securely on your device—we never share or transmit your data, ensuring your privacy is always protected. \n\n - " Enabling this would unlock the following in DigiPaws: 1. Block custom keywords 2. Block content like adult material DigiPaws needs access to accessibility data to know when you open a specific feature within an app, like a social media feed or a game. This lets DigiPaws block those features for you based on your preferences, helping you stay focused and reduce screen distractions. Rest assured, all accessibility data stays securely on your device—we never share or transmit your data, ensuring your privacy is always protected. " + Enabling this would unlock the following in DigiPaws: 1. Block custom keywords 2. Block content like adult material DigiPaws needs access to accessibility data to know when you open a specific feature within an app, like a social media feed or a game. This lets DigiPaws block those features for you based on your preferences, helping you stay focused and reduce screen distractions. Rest assured, all accessibility data stays securely on your device—we never share or transmit your data, ensuring your privacy is always protected. - " Enabling this would unlock the following in DigiPaws: 1. Anti-Uninstall (Setup required to run) DigiPaws needs access to accessibility data to know when you open a specific feature within an app, like a social media feed or a game. This lets DigiPaws block those features for you based on your preferences, helendping you stay focused and reduce screen distractions. Rest assured, all accessibility data stays securely on your device—we never share or transmit your data, ensuring your privacy is always protected. " + Enabling this would unlock the following in DigiPaws: 1. Anti-Uninstall (Setup required to run) DigiPaws needs access to accessibility data to know when you open a specific feature within an app, like a social media feed or a game. This lets DigiPaws block those features for you based on your preferences, helendping you stay focused and reduce screen distractions. Rest assured, all accessibility data stays securely on your device—we never share or transmit your data, ensuring your privacy is always protected. Digipaws Anti-Uninstall Title Close @@ -104,12 +108,12 @@ OK Anti Uninstall removed Failed - "Incorrect password. Please try again. " + Incorrect password. Please try again. Retry Start Time: %1$d:%2$d End time must be after start time has passed! - End Time: %02d:%02d - Start Time: %02d:%02d + End Time: %1$02d:%2$02d + Start Time: %1$02d:%2$02d Specify Cheat Hours You still have %1$d days to go before unlocking anti-uninstall Add a new keyword @@ -140,11 +144,11 @@ Perform actions like a back press Read content on screen This will allow digipaws to: - "Enable %1$s" + Enable %1$s DigiPaws uses Device Admin permission to enhance security and block uninstalling digipaws until a specific period. All data remains securely stored on your device and is never shared externally. Prevent uninstallation attempts until a set condition is met - DigiPaws uses the "Display over other apps" permission to show a small floating overlay on the screen. This overlay tracks the number of reels watched and the time spent, helping users be more aware of their usage in real time. + DigiPaws uses the \"Display over other apps\" permission to show a small floating overlay on the screen. This overlay tracks the number of reels watched and the time spent, helping users be more aware of their usage in real time. Show time elapsed on phone Calculate how many reels/ tiktok/ short videos you scroll per day Plan a robbery @@ -172,4 +176,5 @@ Join Telegram Guide Go back + Block making changes to blockers during this period.