diff --git a/Habitica/build.gradle b/Habitica/build.gradle
index 0a8f0de1d..d5818f57c 100644
--- a/Habitica/build.gradle
+++ b/Habitica/build.gradle
@@ -151,7 +151,7 @@ android {
multiDexEnabled true
resConfigs "en", "bg", "de", "en-rGB", "es", "fr", "hr-rHR", "in", "it", "iw", "ja", "ko", "lt", "nl", "pl", "pt-rBR", "pt-rPT", "ru", "tr", "zh", "zh-rTW"
- versionCode 2324
+ versionCode 2330
versionName "2.4"
}
diff --git a/Habitica/res/layout/activity_gift1get1_info.xml b/Habitica/res/layout/activity_gift1get1_info.xml
index 562718df5..7834af30f 100644
--- a/Habitica/res/layout/activity_gift1get1_info.xml
+++ b/Habitica/res/layout/activity_gift1get1_info.xml
@@ -4,7 +4,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
xmlns:tools="http://schemas.android.com/tools"
- android:background="@color/gray_700">
+ android:background="@color/white">
+ android:layout_alignParentStart="true"
+ android:layout_marginStart="-5dp"/>
+ android:layout_alignParentEnd="true"
+ android:layout_marginEnd="-5dp" />
+ android:layout_marginBottom="22dp"
+ android:layout_marginStart="15dp"
+ android:layout_marginEnd="15dp"/>
+ android:lineSpacingExtra="1dp"
+ android:layout_marginStart="15dp"
+ android:layout_marginEnd="15dp"/>
\ No newline at end of file
diff --git a/Habitica/res/layout/promo_gift_one_get_one.xml b/Habitica/res/layout/promo_gift_one_get_one.xml
index 7467bbfe3..d320e4e4f 100644
--- a/Habitica/res/layout/promo_gift_one_get_one.xml
+++ b/Habitica/res/layout/promo_gift_one_get_one.xml
@@ -37,7 +37,7 @@
android:layout_width="wrap_content"
android:layout_height="32dp"
android:minWidth="110dp"
- android:text="@string/send_gift"
+ android:text="@string/learn_more"
style="@style/HabiticaButton.White"
android:textSize="14sp"
android:textColor="@color/teal_50"
diff --git a/Habitica/res/navigation/navigation.xml b/Habitica/res/navigation/navigation.xml
index 0f4c2ff51..a7ba44d50 100644
--- a/Habitica/res/navigation/navigation.xml
+++ b/Habitica/res/navigation/navigation.xml
@@ -150,6 +150,11 @@
app:argType="boolean"
android:defaultValue="true" />
+
+ Subscribe now to get an exclusive set now and receive new items every month!
Subscribe now to get this %s and receive new items every month! Receive the Royal Purple Jackalope pet when you become a new subscriber.
- Discover even more items in Habitica with a 2x bonus daily drop rate.
+ Discover even more items in Habitica with a 2x bonus daily drop cap.25 Gem cap30 Gem cap35 Gem cap
@@ -922,7 +922,8 @@
How it worksTap ‘Gift a Subscription’ and type in the username of the account you’d like to gift to. From there, pick the sub length you’d like to gift and check out. Your account will automatically be rewarded with the same level of subscription you just gifted.Limitations
- This promotion only applies when you gift to another Habitican. If you or your gift recipient already have a subscription, the gifted subscription will add months of credit that will only be used after the current subscription is cancelled expires.
+ This promotion only applies when you gift to another Habitican. If you or your gift recipient already have a subscription, the gifted subscription will add months of credit that will only be used after the current subscription is cancelled or expires.Limited eventDec 17 to Jan 6
+ Learn more
diff --git a/Habitica/src/main/java/com/habitrpg/android/habitica/data/local/implementation/RealmInventoryLocalRepository.kt b/Habitica/src/main/java/com/habitrpg/android/habitica/data/local/implementation/RealmInventoryLocalRepository.kt
index 10e39f733..d831b2f65 100644
--- a/Habitica/src/main/java/com/habitrpg/android/habitica/data/local/implementation/RealmInventoryLocalRepository.kt
+++ b/Habitica/src/main/java/com/habitrpg/android/habitica/data/local/implementation/RealmInventoryLocalRepository.kt
@@ -315,7 +315,7 @@ class RealmInventoryLocalRepository(realm: Realm, private val context: Context)
override fun getLatestMysteryItem(): Flowable {
return realm.where(Equipment::class.java)
- .beginsWith("key", "armor_mystery_2")
+ .contains("key", "mystery_2")
.sort("key", Sort.DESCENDING)
.findAll()
.asFlowable()
diff --git a/Habitica/src/main/java/com/habitrpg/android/habitica/helpers/NotificationOpenHandler.kt b/Habitica/src/main/java/com/habitrpg/android/habitica/helpers/NotificationOpenHandler.kt
index 13034393e..eadbedfee 100644
--- a/Habitica/src/main/java/com/habitrpg/android/habitica/helpers/NotificationOpenHandler.kt
+++ b/Habitica/src/main/java/com/habitrpg/android/habitica/helpers/NotificationOpenHandler.kt
@@ -23,6 +23,7 @@ class NotificationOpenHandler {
PushNotificationManager.GIFT_ONE_GET_ONE_PUSH_NOTIFICATION_KEY -> openSubscriptionScreen()
PushNotificationManager.CHAT_MENTION_NOTIFICATION_KEY -> handleChatMessage(intent.getStringExtra("type"), intent.getStringExtra("groupID"))
PushNotificationManager.GROUP_ACTIVITY_NOTIFICATION_KEY -> handleChatMessage(intent.getStringExtra("type"), intent.getStringExtra("groupID"))
+ PushNotificationManager.G1G1_PROMO_KEY -> openGiftOneGetOneInfoScreen()
}
}
@@ -42,6 +43,10 @@ class NotificationOpenHandler {
MainNavigationController.navigate(R.id.partyFragment)
}
+ private fun openGiftOneGetOneInfoScreen() {
+ MainNavigationController.navigate(R.id.giftOneGetOneInfoActivity)
+ }
+
private fun openQuestDetailSCreen(partyId: String?, questKey: String?) {
if (partyId == null || questKey == null ||partyId.isNotEmpty() || questKey.isNotEmpty()) {
return
diff --git a/Habitica/src/main/java/com/habitrpg/android/habitica/helpers/notifications/PushNotificationManager.kt b/Habitica/src/main/java/com/habitrpg/android/habitica/helpers/notifications/PushNotificationManager.kt
index bb68371b3..7354b0dc2 100644
--- a/Habitica/src/main/java/com/habitrpg/android/habitica/helpers/notifications/PushNotificationManager.kt
+++ b/Habitica/src/main/java/com/habitrpg/android/habitica/helpers/notifications/PushNotificationManager.kt
@@ -115,6 +115,7 @@ class PushNotificationManager(var apiClient: ApiClient, private val sharedPrefer
const val GIFT_ONE_GET_ONE_PUSH_NOTIFICATION_KEY = "gift1get1"
const val CHAT_MENTION_NOTIFICATION_KEY = "chatMention"
const val GROUP_ACTIVITY_NOTIFICATION_KEY = "groupActivity"
+ const val G1G1_PROMO_KEY = "g1g1Promo"
private const val DEVICE_TOKEN_PREFERENCE_KEY = "device-token-preference"
}
}
diff --git a/Habitica/src/main/java/com/habitrpg/android/habitica/ui/views/insufficientCurrency/InsufficientGemsDialog.kt b/Habitica/src/main/java/com/habitrpg/android/habitica/ui/views/insufficientCurrency/InsufficientGemsDialog.kt
index 99398d050..a890a1b2f 100644
--- a/Habitica/src/main/java/com/habitrpg/android/habitica/ui/views/insufficientCurrency/InsufficientGemsDialog.kt
+++ b/Habitica/src/main/java/com/habitrpg/android/habitica/ui/views/insufficientCurrency/InsufficientGemsDialog.kt
@@ -43,8 +43,6 @@ class InsufficientGemsDialog(context: Context) : InsufficientCurrencyDialog(cont
super.onCreate(savedInstanceState)
imageView.setImageResource(R.drawable.gems_84)
textView.setText(R.string.insufficientGems)
-
-
addCloseButton()
}