Add final artwork and correctly read colours.
Carrie specified colours earlier, and they were added to the code. However they were not being read correctly. This changes that so that lowercase resource names (e.g. "category_games") are used instead. It also adds the final category artwork, for "Games" which was missed prior. The rest still generate colours and patterns if they don't have a colour or an image specified.
This commit is contained in:
parent
701d927e7a
commit
5b6e515a06
@ -120,7 +120,7 @@ public class CategoryController extends RecyclerView.ViewHolder implements Loade
|
||||
}
|
||||
|
||||
public static int getBackgroundColour(Context context, @NonNull String categoryName) {
|
||||
int colourId = getCategoryResource(context, categoryName, "color", false);
|
||||
int colourId = getCategoryResource(context, categoryName, "color", true);
|
||||
if (colourId > 0) {
|
||||
return ContextCompat.getColor(context, colourId);
|
||||
}
|
||||
|
BIN
app/src/main/res/drawable/category_games.png
Normal file
BIN
app/src/main/res/drawable/category_games.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 11 KiB |
Loading…
x
Reference in New Issue
Block a user