cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Davide (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CB-9417) <icon src="icon.png"/> is ignored
Date Wed, 09 Nov 2016 08:17:58 GMT

    [ https://issues.apache.org/jira/browse/CB-9417?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15650157#comment-15650157
] 

Davide commented on CB-9417:
----------------------------

This function worked in cordova 5.4.1 but does not work in 6.4.0 and it was an oversight on
our part and it's now live in our app. At least it is free advertisement for cordova.

> <icon src="icon.png"/> is ignored
> ---------------------------------
>
>                 Key: CB-9417
>                 URL: https://issues.apache.org/jira/browse/CB-9417
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: Android
>         Environment: Android
>            Reporter: Sebastien Lorber
>              Labels: triaged
>
> I don't know for iOS but for Android with CLI 5.1.1 it does not work.
> Normally when I reference an unexisting image, the build process outputs a cp command
error:
> {code}
>     sebastien@sebastien-xps:cordova (dev *+$%)$ cordova run android --device
>     cp: no such file or directory: /home/sebastien/Desktop/Stample-react/cordova/res/www/stample_splash.png
> {code}
> But in this case there's no error at all, because I suspect Cordova to not do any CP
at all. All icon src without a density are ignored, including:
> {code}
> <icon src="icon.png"/> 
> <icon src="icon.png" platform="android"/>
> <platform name="android">
>         <icon src="icon.png" />
>         <icon src="icon.png" density="" />
> </platform>
> {code}
> So the only solution for Android is to always use a density.
> {code}
>     <platform name="android">
>         <icon src="www/stample_icon.png" density="ldpi" />
>         <icon src="www/stample_icon.png" density="mdpi" />
>         <icon src="www/stample_icon.png" density="hdpi" />
>         <icon src="www/stample_icon.png" density="xhdpi" />
>         <splash src="www/stample_splash.png" density="land-hdpi"/>
>         <splash src="www/stample_splash.png" density="land-ldpi"/>
>         <splash src="www/stample_splash.png" density="land-mdpi"/>
>         <splash src="www/stample_splash.png" density="land-xhdpi"/>
>         <splash src="www/stample_splash.png" density="port-hdpi"/>
>         <splash src="www/stample_splash.png" density="port-ldpi"/>
>         <splash src="www/stample_splash.png" density="port-mdpi"/>
>         <splash src="www/stample_splash.png" density="port-xhdpi"/>
>     </platform>
> {code}
> This works fine for me and many others according to StackOverflow upvotes here: http://stackoverflow.com/questions/17820492/how-to-add-app-icon-within-phonegap-projects
> However, this never changes the picture in the APK with path "res/drawable/icon.png":
this file will never be able to be replaced by a custom icon when using the config.xml declarations.
> Note this bug has already been mentionned here: https://issues.apache.org/jira/browse/CB-2606



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


Mime
View raw message