replace the Purchase Thank You settings button with Upgrade to Pro
This commit is contained in:
parent
df2ab51618
commit
0329816a4e
3 changed files with 10 additions and 13 deletions
|
@ -41,7 +41,7 @@ android {
|
|||
}
|
||||
|
||||
dependencies {
|
||||
implementation 'com.simplemobiletools:commons:5.3.3'
|
||||
implementation 'com.simplemobiletools:commons:5.3.6'
|
||||
}
|
||||
|
||||
Properties props = new Properties()
|
||||
|
|
|
@ -1,10 +1,7 @@
|
|||
package com.simplemobiletools.draw.activities
|
||||
|
||||
import android.os.Bundle
|
||||
import com.simplemobiletools.commons.extensions.beVisibleIf
|
||||
import com.simplemobiletools.commons.extensions.isThankYouInstalled
|
||||
import com.simplemobiletools.commons.extensions.launchPurchaseThankYouIntent
|
||||
import com.simplemobiletools.commons.extensions.updateTextColors
|
||||
import com.simplemobiletools.commons.extensions.*
|
||||
import com.simplemobiletools.draw.R
|
||||
import com.simplemobiletools.draw.extensions.config
|
||||
import kotlinx.android.synthetic.main.activity_settings.*
|
||||
|
@ -19,7 +16,7 @@ class SettingsActivity : SimpleActivity() {
|
|||
override fun onResume() {
|
||||
super.onResume()
|
||||
|
||||
setupPurchaseThankYou()
|
||||
setupUpgradeToPro()
|
||||
setupCustomizeColors()
|
||||
setupUseEnglish()
|
||||
setupPreventPhoneFromSleeping()
|
||||
|
@ -29,10 +26,10 @@ class SettingsActivity : SimpleActivity() {
|
|||
updateTextColors(settings_holder)
|
||||
}
|
||||
|
||||
private fun setupPurchaseThankYou() {
|
||||
settings_purchase_thank_you_holder.beVisibleIf(!isThankYouInstalled())
|
||||
settings_purchase_thank_you_holder.setOnClickListener {
|
||||
launchPurchaseThankYouIntent()
|
||||
private fun setupUpgradeToPro() {
|
||||
settings_upgrade_to_pro_holder.beGoneIf(isAProApp())
|
||||
settings_upgrade_to_pro_holder.setOnClickListener {
|
||||
launchUpgradeToProIntent()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
android:orientation="vertical">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/settings_purchase_thank_you_holder"
|
||||
android:id="@+id/settings_upgrade_to_pro_holder"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/medium_margin"
|
||||
|
@ -24,13 +24,13 @@
|
|||
android:paddingBottom="@dimen/activity_margin">
|
||||
|
||||
<com.simplemobiletools.commons.views.MyTextView
|
||||
android:id="@+id/settings_purchase_thank_you"
|
||||
android:id="@+id/settings_upgrade_to_pro"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerVertical="true"
|
||||
android:paddingStart="@dimen/medium_margin"
|
||||
android:paddingLeft="@dimen/medium_margin"
|
||||
android:text="@string/purchase_simple_thank_you"/>
|
||||
android:text="@string/upgrade_to_pro"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
|
|
Loading…
Reference in a new issue