Apple-Touch-Icon sizes #34

Closed
darogina opened this Issue Oct 15, 2012 · 1 comment

Comments

Projects
None yet
2 participants

If multiple touch icons, all with different sizes, are supplied in the document but the iDevice is not retina then no touchIcon is displayed. I believe the following section of code is the culprit.

    if ( icons.length ) {
        for ( i = 0, l = icons.length; i < l; i++ ) {
            sizes = icons[i].getAttribute('sizes');

            if ( sizes ) {
                if ( isRetina && sizes == '114x114' ) {
                    touchIcon = icons[i].href;
                    break;
                }
            } else {
                touchIcon = icons[i].href;
            }
        }

        touchIcon = '<span style="background-image:url(' + touchIcon + ')" class="addToHomeTouchIcon"></span>';
    }

JaredSartin added a commit to JaredSartin/add-to-homescreen that referenced this issue Dec 29, 2012

cubiq added a commit that referenced this issue Jan 18, 2013

Owner

cubiq commented Jan 18, 2013

fixed in a hopefully better way. thanks for pointing this out.

@cubiq cubiq closed this Jan 18, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment