mirror of
https://github.com/sudoxnym/habitica-android.git
synced 2026-04-14 19:56:32 +00:00
creator improvements
This commit is contained in:
parent
3283cd8187
commit
b3b84b193b
6 changed files with 20 additions and 5 deletions
4
Habitica/res/drawable/ic_check_white_18dp.xml
Normal file
4
Habitica/res/drawable/ic_check_white_18dp.xml
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android" android:height="18dp" android:viewportHeight="24.0" android:viewportWidth="24.0" android:width="18dp">
|
||||
<path android:fillColor="#FFFFFF" android:pathData="M9,16.17L4.83,12l-1.42,1.41L9,19 21,7l-1.41,-1.41z"/>
|
||||
</vector>
|
||||
5
Habitica/res/drawable/setup_customization_flower_bg.xml
Normal file
5
Habitica/res/drawable/setup_customization_flower_bg.xml
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="oval">
|
||||
<stroke android:color="@color/days_gray" android:width="2dp" />
|
||||
<size android:height="50dp" android:width="50dp" />
|
||||
</shape>
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="oval">
|
||||
<stroke android:color="@color/brand_400" android:width="3dp" />
|
||||
<size android:height="50dp" android:width="50dp" />
|
||||
</shape>
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<dimen name="setup_vertical_spacing">20dp</dimen>
|
||||
<dimen name="setup_vertical_spacing">28dp</dimen>
|
||||
<dimen name="customization_drawer_subcategory_height">130dp</dimen>
|
||||
<dimen name="customization_drawer_category_height">100dp</dimen>
|
||||
<dimen name="customization_drawer_caret_margin">91dp</dimen>
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ public class TaskSetupAdapter extends RecyclerView.Adapter<TaskSetupAdapter.Task
|
|||
|
||||
Context context;
|
||||
|
||||
public TaskViewHolder(View itemView) {
|
||||
TaskViewHolder(View itemView) {
|
||||
super(itemView);
|
||||
|
||||
ButterKnife.bind(this, itemView);
|
||||
|
|
@ -73,7 +73,7 @@ public class TaskSetupAdapter extends RecyclerView.Adapter<TaskSetupAdapter.Task
|
|||
|
||||
itemView.setOnClickListener(this);
|
||||
|
||||
icon = ContextCompat.getDrawable(context, R.drawable.ic_check);
|
||||
icon = ContextCompat.getDrawable(context, R.drawable.ic_check_white_18dp);
|
||||
icon.setColorFilter(ContextCompat.getColor(context, R.color.brand_100), PorterDuff.Mode.MULTIPLY);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -186,9 +186,9 @@ public class AvatarSetupFragment extends BaseFragment {
|
|||
activateButton(hairButton);
|
||||
this.activeCategory = "hair";
|
||||
this.subCategoryTabs.removeAllTabs();
|
||||
this.subcategories = Arrays.asList("color", "bangs", "ponytail");
|
||||
this.subCategoryTabs.addTab(subCategoryTabs.newTab().setText(R.string.avatar_hair_color));
|
||||
this.subcategories = Arrays.asList("bangs", "color", "ponytail");
|
||||
this.subCategoryTabs.addTab(subCategoryTabs.newTab().setText(R.string.avatar_hair_bangs));
|
||||
this.subCategoryTabs.addTab(subCategoryTabs.newTab().setText(R.string.avatar_hair_color));
|
||||
this.subCategoryTabs.addTab(subCategoryTabs.newTab().setText(R.string.avatar_hair_ponytail));
|
||||
loadCustomizations();
|
||||
}
|
||||
|
|
@ -225,6 +225,7 @@ public class AvatarSetupFragment extends BaseFragment {
|
|||
EventBus.getDefault().post(command);
|
||||
}
|
||||
|
||||
@Nullable
|
||||
private String chooseRandomKey(List<SetupCustomization> customizations, boolean weighFirstOption) {
|
||||
if (customizations.size() == 0) {
|
||||
return null;
|
||||
|
|
|
|||
Loading…
Reference in a new issue