Skip to content

Support for GMaps v3: MarkerOptions.optimized / support for aPNG and aGIF markers #78

@th23

Description

@th23

Hi together,

as this framework is the basis for the Geo Mashup plugin integrating Google Maps with WordPress I was playing around with the customization.

I found out, that since v3.4 of the GMaps API, there is a parameter called "MarkerOptions.optimized" which needs to be defined false upon using an animated PNG or animated GIF as a marker icon.

To achieve this, I propose to modify "js/mxn/mxn.googlev3.core.js" of the framework:

AFTER

                options.shadow = new google.maps.MarkerImage(this.iconShadowUrl);
            }
        }

ADD

        if(typeof(this.attributes['iconOptimized']) !== 'undefined') {
            options.optimized = this.attributes['iconOptimized'] ? true : false;
        }

This change allows users to define "iconOptimized: false" with marker options to be able to use aPNG/ aGIF files.

Hope this helps developing this framework further :-)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions