diff --git a/OsmAnd/.gitignore b/OsmAnd/.gitignore index 59c852486d..e3071e5fbf 100644 --- a/OsmAnd/.gitignore +++ b/OsmAnd/.gitignore @@ -27,6 +27,12 @@ res/drawable-large/widget_* res/drawable-large-hdpi/widget_* res/drawable-large-xhdpi/widget_* +# rendering-styles/style-icons/ +h_* +g_* +mm_* +mx_* + valgrind/ bin/ dist/ diff --git a/OsmAnd/build.gradle b/OsmAnd/build.gradle index 45dc9e96ec..4f649e8931 100644 --- a/OsmAnd/build.gradle +++ b/OsmAnd/build.gradle @@ -359,15 +359,44 @@ task copyPoiCategiry(type: Copy) { into "assets" } -task copyStyleIcons(type: Copy) { +task copyStyleIcons(type: Sync) { from "../../resources/rendering_styles/style-icons/" into "res/" - include "**/*.png" + include "**/*.png", "**/*.xml" + preserve { + include '**/*' + exclude "**/mx_*", "**/mm_*", "**/h_*" + } } -task copyWidgetIcons(type: Exec) { - if (!Os.isFamily(Os.FAMILY_WINDOWS)) { - commandLine 'sh', file("./copy_widget_icons.sh").getAbsolutePath() + +task copyWidgetIconsXhdpi(type: Sync) { + from "res/drawable-xxhdpi/" + into "res/drawable-large-xhdpi/" + include "**/widget_*.png", "**/widget_*.xml", "**/map_*.xml", "**/map_*.png" + preserve { + include '*' + exclude "**/widget_*.png", "**/widget_*.xml", "**/map_*.xml", "**/map_*.png" + } +} + +task copyWidgetIconsHdpi(type: Sync) { + from "res/drawable-xhdpi/" + into "res/drawable-large-hdpi/" + include "**/widget_*.png", "**/widget_*.xml", "**/map_*.xml", "**/map_*.png" + preserve { + include '*' + exclude "**/widget_*.png", "**/widget_*.xml", "**/map_*.xml", "**/map_*.png" + } +} + +task copyWidgetIcons(type: Sync) { + from "res/drawable-hdpi/" + into "res/drawable-large/" + include "**/widget_*.png", "**/widget_*.xml", "**/map_*.xml", "**/map_*.png" + preserve { + include '*' + exclude "**/widget_*.png", "**/widget_*.xml", "**/map_*.xml", "**/map_*.png" } } @@ -380,6 +409,8 @@ task collectExternalResources { updateNoTranslate, validateTranslate, copyWidgetIcons, + copyWidgetIconsHdpi, + copyWidgetIconsXhdpi, copyPoiCategiry, downloadWorldMiniBasemap diff --git a/OsmAnd/copy_widget_icons.sh b/OsmAnd/copy_widget_icons.sh deleted file mode 100755 index 299235327c..0000000000 --- a/OsmAnd/copy_widget_icons.sh +++ /dev/null @@ -1,6 +0,0 @@ -cp -f res/drawable-hdpi/widget_* res/drawable-large/ -cp -f res/drawable-xxhdpi/widget_* res/drawable-large-hdpi/ -cp -f res/drawable-xhdpi/widget_* res/drawable-large-xhdpi/ -cp -f res/drawable-hdpi/map_* res/drawable-large/ -cp -f res/drawable-xhdpi/map_* res/drawable-large-hdpi/ -cp -f res/drawable-xxhdpi/map_* res/drawable-large-xhdpi/