Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-12077

Custom app icons and splash screens not working in cordova-android v6.0.0

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Fixed
    • None
    • None
    • None
    • None
    • cordova v6.4.0, cordova-android v6.0.0, cordova-plugin-splashscreen@4.0.0

    Description

      With the latest cordova-android v6.0.0 release, which is pinned to cordova v6.4.0, custom app icons and splash screens no longer work.

      It appears as though the custom app icons and splash screens are copied into the ./res folder and not into the ./platforms/android/res folder.

      Others have mentioned the same bug - please refer to the comments at the bottom of your blog post announcement of the cordova-android v6.0.0 release (http://cordova.apache.org/announcements/2016/10/24/android-release.html).

      My config.xml file refers to the app icons & splash screens as follows:

      <platform name="android">
      <allow-intent href="market:*" />
      <icon src="icon/android/icon-ldpi.png" density="ldpi"/>
      <icon src="icon/android/icon-mdpi.png" density="mdpi"/>
      <icon src="icon/android/icon-hdpi.png" density="hdpi"/>
      <icon src="icon/android/icon-xhdpi.png" density="xhdpi"/>
      <icon src="icon/android/icon-xxhdpi.png" density="xxhdpi"/>
      <icon src="icon/android/icon-xxxhdpi.png" density="xxxhdpi"/>
      <splash src="screen/android/splash-land-ldpi.9.png" density="land-ldpi"/>
      <splash src="screen/android/splash-land-mdpi.9.png" density="land-mdpi"/>
      <splash src="screen/android/splash-land-hdpi.9.png" density="land-hdpi"/>
      <splash src="screen/android/splash-land-xhdpi.9.png" density="land-xhdpi"/>
      <splash src="screen/android/splash-land-xxhdpi.9.png" density="land-xxhdpi"/>
      <splash src="screen/android/splash-land-xxxhdpi.9.png" density="land-xxxhdpi"/>
      <splash src="screen/android/splash-port-hdpi.9.png" density="port-hdpi"/>
      <splash src="screen/android/splash-port-ldpi.9.png" density="port-ldpi"/>
      <splash src="screen/android/splash-port-mdpi.9.png" density="port-mdpi"/>
      <splash src="screen/android/splash-port-xhdpi.9.png" density="port-xhdpi"/>
      <splash src="screen/android/splash-port-xxhdpi.9.png" density="port-xxhdpi"/>
      <splash src="screen/android/splash-port-xxxhdpi.9.png" density="port-xxxhdpi"/>
      </platform>

      Attachments

        1. 2016-10-30_213127.png
          370 kB
          Colin Bau

        Issue Links

          Activity

            gmawson Graeme Mawson added a comment -

            Forgot to mention - this appears to be related to CB-8722

            gmawson Graeme Mawson added a comment - Forgot to mention - this appears to be related to CB-8722
            githubbot ASF GitHub Bot added a comment -

            GitHub user dpogue opened a pull request:

            https://github.com/apache/cordova-android/pull/343

            CB-12077: Fix paths for Android icons/splashscreens

                1. Platforms affected
                  Android
                1. What does this PR do?
                  Fix icons and splashscreens defined in config.xml copying into the project to override the default Cordova ones.
                1. What testing has been done on this change?
                  Tested locally with cordova-cli

            You can merge this pull request into a Git repository by running:

            $ git pull https://github.com/dpogue/cordova-android fix-icons

            Alternatively you can review and apply these changes as the patch at:

            https://github.com/apache/cordova-android/pull/343.patch

            To close this pull request, make a commit to your master/trunk branch
            with (at least) the following in the commit message:

            This closes #343


            commit db198eba9ada727025e63c8709c78f17ee0cecea
            Author: Darryl Pogue <darryl@ayogo.com>
            Date: 2016-10-28T20:05:01Z

            CB-12077: Fix paths for Android icons/splashscreens


            githubbot ASF GitHub Bot added a comment - GitHub user dpogue opened a pull request: https://github.com/apache/cordova-android/pull/343 CB-12077 : Fix paths for Android icons/splashscreens Platforms affected Android What does this PR do? Fix icons and splashscreens defined in config.xml copying into the project to override the default Cordova ones. What testing has been done on this change? Tested locally with cordova-cli You can merge this pull request into a Git repository by running: $ git pull https://github.com/dpogue/cordova-android fix-icons Alternatively you can review and apply these changes as the patch at: https://github.com/apache/cordova-android/pull/343.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #343 commit db198eba9ada727025e63c8709c78f17ee0cecea Author: Darryl Pogue <darryl@ayogo.com> Date: 2016-10-28T20:05:01Z CB-12077 : Fix paths for Android icons/splashscreens
            githubbot ASF GitHub Bot added a comment -

            Github user codecov-io commented on the issue:

            https://github.com/apache/cordova-android/pull/343

              1. [Current coverage](https://codecov.io/gh/apache/cordova-android/pull/343?src=pr) is 35.21% (diff: 0.00%)
                > Merging 343(https://codecov.io/gh/apache/cordova-android/pull/343?src=pr) into [master](https://codecov.io/gh/apache/cordova-android/branch/master?src=pr) will not change coverage

            ```diff
            @@ master #343 diff @@
            ==========================================
            Files 12 12
            Lines 1028 1028
            Methods 202 202
            Messages 0 0
            Branches 169 169
            ==========================================
            Hits 362 362
            Misses 666 666
            Partials 0 0
            ```

            > Powered by [Codecov](https://codecov.io?src=pr). Last update [1f06176...db198eb](https://codecov.io/gh/apache/cordova-android/compare/1f06176149a49dd5a28e491c948ea98200ed6c1f...db198eba9ada727025e63c8709c78f17ee0cecea?src=pr)

            githubbot ASF GitHub Bot added a comment - Github user codecov-io commented on the issue: https://github.com/apache/cordova-android/pull/343 [Current coverage] ( https://codecov.io/gh/apache/cordova-android/pull/343?src=pr ) is 35.21% (diff: 0.00%) > Merging 343 ( https://codecov.io/gh/apache/cordova-android/pull/343?src=pr ) into [master] ( https://codecov.io/gh/apache/cordova-android/branch/master?src=pr ) will not change coverage ```diff @@ master #343 diff @@ ========================================== Files 12 12 Lines 1028 1028 Methods 202 202 Messages 0 0 Branches 169 169 ========================================== Hits 362 362 Misses 666 666 Partials 0 0 ``` > Powered by [Codecov] ( https://codecov.io?src=pr ). Last update [1f06176...db198eb] ( https://codecov.io/gh/apache/cordova-android/compare/1f06176149a49dd5a28e491c948ea98200ed6c1f...db198eba9ada727025e63c8709c78f17ee0cecea?src=pr )
            bau720123 Colin Bau added a comment -

            I have the totally same problem
            after use cordova-android 6.0
            everytime I use "cordova build android --release"
            the icon and splashscreen can not copy to "platforms\android\res\" anymore (see my screenshot)
            but it is never happen before version 6.0.0

            bau720123 Colin Bau added a comment - I have the totally same problem after use cordova-android 6.0 everytime I use "cordova build android --release" the icon and splashscreen can not copy to "platforms\android\res\" anymore (see my screenshot) but it is never happen before version 6.0.0

            Commit 854946e313c6b00e0087e9aa432fad664083c96a in cordova-android's branch refs/heads/master from dpogue
            [ https://git-wip-us.apache.org/repos/asf?p=cordova-android.git;h=854946e ]

            CB-12077: Fix paths for Android icons/splashscreens

            This closes #343

            jira-bot ASF subversion and git services added a comment - Commit 854946e313c6b00e0087e9aa432fad664083c96a in cordova-android's branch refs/heads/master from dpogue [ https://git-wip-us.apache.org/repos/asf?p=cordova-android.git;h=854946e ] CB-12077 : Fix paths for Android icons/splashscreens This closes #343
            githubbot ASF GitHub Bot added a comment -

            Github user asfgit closed the pull request at:

            https://github.com/apache/cordova-android/pull/343

            githubbot ASF GitHub Bot added a comment - Github user asfgit closed the pull request at: https://github.com/apache/cordova-android/pull/343
            githubbot ASF GitHub Bot added a comment -

            Github user mattroth commented on the issue:

            https://github.com/apache/cordova-android/pull/343

            Does anyone have a work around? How can I update cordova-android on my development machine with this above fix prior to the next release?

            githubbot ASF GitHub Bot added a comment - Github user mattroth commented on the issue: https://github.com/apache/cordova-android/pull/343 Does anyone have a work around? How can I update cordova-android on my development machine with this above fix prior to the next release?
            githubbot ASF GitHub Bot added a comment -

            Github user jcesarmobile commented on the issue:

            https://github.com/apache/cordova-android/pull/343

            you can use cordova-android from master with `cordova platform add android@https://github.com/apache/cordova-android` or the previous version with `cordova platform add android@5.2.2`

            githubbot ASF GitHub Bot added a comment - Github user jcesarmobile commented on the issue: https://github.com/apache/cordova-android/pull/343 you can use cordova-android from master with `cordova platform add android@ https://github.com/apache/cordova-android ` or the previous version with `cordova platform add android@5.2.2`
            jcesarmobile jcesarmobile added a comment -

            Fixed in cordova-android 6.1.0

            jcesarmobile jcesarmobile added a comment - Fixed in cordova-android 6.1.0
            githubbot ASF GitHub Bot added a comment -

            Github user rodrigograca31 commented on the issue:

            https://github.com/apache/cordova-android/pull/343

            Notes:
            This issue is solved in `cordova-android 6.1.0` but if you try `cordova platform update android` at this moment doesn't update to `6.1.0`, if you are experiencing this problem edit your `config.xml` and change `6.0.0` to `6.1.0` (and test to make sure no other problems exist because of this change...)

            githubbot ASF GitHub Bot added a comment - Github user rodrigograca31 commented on the issue: https://github.com/apache/cordova-android/pull/343 Notes: This issue is solved in `cordova-android 6.1.0` but if you try `cordova platform update android` at this moment doesn't update to `6.1.0`, if you are experiencing this problem edit your `config.xml` and change `6.0.0` to `6.1.0` (and test to make sure no other problems exist because of this change...)
            githubbot ASF GitHub Bot added a comment -

            Github user rodrigograca31 commented on the issue:

            https://github.com/apache/cordova-android/pull/343

            Notes:
            This issue is solved in `cordova-android 6.1.0` but if you try `cordova platform update android` at this moment doesn't update to `6.1.0`.

            Run
            ```bash
            cordova platform update android@6.1.0 --save
            cordova platform rm android
            cordova platform add android
            ```
            to solve this issue.

            githubbot ASF GitHub Bot added a comment - Github user rodrigograca31 commented on the issue: https://github.com/apache/cordova-android/pull/343 Notes: This issue is solved in `cordova-android 6.1.0` but if you try `cordova platform update android` at this moment doesn't update to `6.1.0`. Run ```bash cordova platform update android@6.1.0 --save cordova platform rm android cordova platform add android ``` to solve this issue.

            People

              dpogue Darryl Pogue
              gmawson Graeme Mawson
              Votes:
              7 Vote for this issue
              Watchers:
              12 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: