creator improvements

This commit is contained in:
Phillip Thelen 2017-04-10 18:48:06 +02:00
parent 3283cd8187
commit b3b84b193b
6 changed files with 20 additions and 5 deletions

View 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>

View 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>

View 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/brand_400" android:width="3dp" />
<size android:height="50dp" android:width="50dp" />
</shape>

View file

@ -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>

View file

@ -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);
}

View file

@ -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;