1. #1
    Sencha Premium Member
    Join Date
    May 2012
    Posts
    25
    Vote Rating
    0
    mediademon is on a distinguished road

      0  

    Default Unanswered: Android Icons

    Unanswered: Android Icons


    I'm trying to package an app as a native android app but am struggling with icons.

    Within app.js there is this:

    Code:
    icon: {         '57': 'resources/icons/Logo57.png',
            '72': 'resources/icons/Logo72.png',
            '114': 'resources/icons/Logo114.png',
            '144': 'resources/icons/Logo144.png'
        },
    
    
        isIconPrecomposed: true,
    
    
        startupImage: {
            '320x460': 'resources/startup/320x460.jpg',
            '640x920': 'resources/startup/640x920.png',
            '768x1004': 'resources/startup/768x1004.png',
            '748x1024': 'resources/startup/748x1024.png',
            '1536x2008': 'resources/startup/1536x2008.png',
            '1496x2048': 'resources/startup/1496x2048.png'
        },
    Which is fine....except they are, according to the documentation, only for iOS devices. I have confirmed they work on iOS devices also, but when I package it for an Android device I get no app icon and no startup image.

    Does anyone know a way to do this?

    I've also tried adding the image into the packager.json file like so:

    Code:
    "iconName":"Logo_57.png",
    Not only does this only have one option and to account for different devices you need several....but it didn't work anyway.

    Any help anyone can give will be greatly appreciated.

  2. #2
    Sencha User
    Join Date
    Aug 2012
    Posts
    16
    Vote Rating
    0
    GillesK is on a distinguished road

      0  

    Default


    Same problem with me.

    I don´t understand the duplicates :
    - declaration in app.js
    - declaration in packager.json : this one seems limitative since we can reference only one icon when
    the guidelines (Android ans iOs) says to create icons of various size depending on the device resolution.

    Can somebody explain ?

  3. #3
    Sencha User
    Join Date
    Aug 2012
    Posts
    16
    Vote Rating
    0
    GillesK is on a distinguished road

      0  

    Default


    What I´ve seen in sencha touch 2.0.1.1 source code is that it will only use the 57x57 icon for Android devices.

  4. #4
    Sencha User
    Join Date
    Jul 2013
    Posts
    1
    Vote Rating
    0
    Jaegermeiste is on a distinguished road

      0  

    Default


    Would simply adding in the extra resolutions per the Android docs (https://developer.android.com/design...onography.html) work as below?

    Code:
    icon: {
            '48': 'resources/icons/Icon48.png',        // Android MDPI
            '57': 'resources/icons/Icon57.png',        // iPhone, iPod Touch
            '72': 'resources/icons/Icon72.png',        // Android HDPI, iPhone 4, new iPod Touch
            '96:' 'resources/icons/Icon96.png',        // Android XHDPI
            '114': 'resources/icons/Icon114.png',        // iPad 1
            '144': 'resources/icons/Icon144.png'    ​    // Android XXHDPI, iPad 2+
        },
    If not, where is the trouble spot in the Sencha Touch code?