0
0
Fork 0
mirror of https://github.com/YTVanced/VancedManager synced 2024-11-30 06:53:01 +00:00

enabled instant support for FAQ

This commit is contained in:
X1nto 2021-02-04 19:30:52 +04:00
parent 6a76edd101
commit d4c868c1e4

View file

@ -30,9 +30,9 @@ import com.vanced.manager.ui.fragments.SettingsFragmentDirections
import com.vanced.manager.utils.* import com.vanced.manager.utils.*
import com.vanced.manager.utils.AppUtils.faqpkg import com.vanced.manager.utils.AppUtils.faqpkg
import com.vanced.manager.utils.AppUtils.log import com.vanced.manager.utils.AppUtils.log
import com.vanced.manager.utils.AppUtils.playStorePkg
import com.vanced.manager.utils.PackageHelper.isPackageInstalled import com.vanced.manager.utils.PackageHelper.isPackageInstalled
class MainActivity : AppCompatActivity() { class MainActivity : AppCompatActivity() {
lateinit var binding: ActivityMainBinding lateinit var binding: ActivityMainBinding
@ -124,8 +124,12 @@ class MainActivity : AppCompatActivity() {
} }
} else { } else {
Intent(Intent.ACTION_VIEW).apply { Intent(Intent.ACTION_VIEW).apply {
data = Uri.parse("https://play.google.com/store/apps/details?id=$faqpkg") val uriBuilder = Uri.parse("https://play.google.com/store/apps/details")
setPackage("com.android.vending") .buildUpon()
.appendQueryParameter("id", faqpkg)
.appendQueryParameter("launch", "true")
data = uriBuilder.build()
setPackage(playStorePkg)
} }
} }
startActivity(intent) startActivity(intent)