mirror of
https://github.com/sudoxnym/habitica-android.git
synced 2026-07-18 12:02:23 +00:00
fix login incentive notification
This commit is contained in:
parent
d5daaf1bb6
commit
ebd3b1f93e
2 changed files with 8 additions and 13 deletions
|
|
@ -1,24 +1,19 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:orientation="vertical"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
>
|
||||
android:gravity="center_horizontal">
|
||||
|
||||
<com.facebook.drawee.view.SimpleDraweeView
|
||||
android:layout_width="60dp"
|
||||
android:layout_height="60dp"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:id="@+id/imageView" />
|
||||
|
||||
|
||||
<TextView
|
||||
android:text=""
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/imageView"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_marginTop="50dp"
|
||||
android:layout_marginLeft="25dp"
|
||||
android:layout_marginRight="25dp"
|
||||
|
|
@ -28,8 +23,6 @@
|
|||
android:text=""
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/you_earned_message"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_marginTop="50dp"
|
||||
android:id="@+id/next_unlock_message" />
|
||||
|
||||
|
|
@ -37,10 +30,8 @@
|
|||
android:text="@string/see_you_tomorrow"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/next_unlock_message"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_marginTop="50dp"
|
||||
android:id="@+id/confirm_button"
|
||||
style="@style/Widget.AppCompat.Button.Borderless.Colored" />
|
||||
|
||||
</RelativeLayout>
|
||||
</LinearLayout>
|
||||
|
|
@ -1,6 +1,7 @@
|
|||
package com.habitrpg.android.habitica.helpers;
|
||||
|
||||
import android.support.annotation.Nullable;
|
||||
import android.support.v4.content.ContextCompat;
|
||||
import android.support.v7.app.AlertDialog;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
|
|
@ -70,15 +71,18 @@ public class PopupNotificationsManager {
|
|||
DataBindingUtils.loadImage(imageView, imageKey);
|
||||
|
||||
TextView youEarnedTexView = (TextView) view.findViewById(R.id.you_earned_message);
|
||||
youEarnedTexView.setTextColor(ContextCompat.getColor(context, R.color.textColorLight));
|
||||
youEarnedTexView.setText(youEarnedMessage);
|
||||
|
||||
String message = context.getString(R.string.nextPrizeUnlocks, notification.data.nextRewardAt);
|
||||
TextView nextUnlockTextView = (TextView) view.findViewById(R.id.next_unlock_message);
|
||||
nextUnlockTextView.setTextColor(ContextCompat.getColor(context, R.color.textColorLight));
|
||||
nextUnlockTextView.setText(message);
|
||||
|
||||
Button confirmButton = (Button) view.findViewById(R.id.confirm_button);
|
||||
confirmButton.setTextColor(ContextCompat.getColor(context, R.color.brand_300));
|
||||
|
||||
AlertDialog.Builder builder = new AlertDialog.Builder(HabiticaApplication.currentActivity)
|
||||
AlertDialog.Builder builder = new AlertDialog.Builder(HabiticaApplication.currentActivity, R.style.AlertDialogTheme)
|
||||
.setTitle(title)
|
||||
.setView(view)
|
||||
.setMessage("");
|
||||
|
|
|
|||
Loading…
Reference in a new issue