mirror of
https://github.com/apache/cordova-android.git
synced 2025-01-31 17:32:51 +08:00
fix: support both adaptive and standard icons at the same time (#1001)
This commit is contained in:
parent
8d8600b442
commit
d5d448888d
5
bin/templates/cordova/lib/prepare.js
vendored
5
bin/templates/cordova/lib/prepare.js
vendored
@ -457,6 +457,11 @@ function updateIconResourceForAdaptive (preparedIcons, resourceMap, platformReso
|
|||||||
background = android_icons[density].background;
|
background = android_icons[density].background;
|
||||||
foreground = android_icons[density].foreground;
|
foreground = android_icons[density].foreground;
|
||||||
|
|
||||||
|
if (!background || !foreground) {
|
||||||
|
// This icon isn't an adaptive icon, so skip it
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
if (background.startsWith('@color')) {
|
if (background.startsWith('@color')) {
|
||||||
// Colors Use Case
|
// Colors Use Case
|
||||||
backgroundVal = background; // Example: @color/background_foobar_1
|
backgroundVal = background; // Example: @color/background_foobar_1
|
||||||
|
Loading…
Reference in New Issue
Block a user