Class: MMap.Marker.Images
Marker who does image in slide and displays it.
Extends:
MMap.Marker.Core
Method: constructor
Syntax:
var myMarker = new MMap.Marker.Images(options);
Arguments:
- options - (mixed) Option of marker
Options:
- map - (Map) Map object that displays marker
- className - (string) Style applied to marker (class name of CSS)
- images - (array) Image information displayed in marker
- current - (number) Number of image displayed when initial
- interval - (number) Sense to do image in slide
- duration - (number) Duration of animation
- autoplay - (boolean) When true is set, the slide does the image by the automatic operation. Default is true.
- position - (LatLng) Coordinates position of marker
- zIndex - (number) The order of displaying marker
- visible - (boolean) State of display of marker
- active - (boolean) Active state of marker
- onClick - (function) When the marker is clicked, it is generated.
- onDblClick - (function) When the marker is double-clicked, it is generated.
- onMouseOver - (function) It is generated at mouse over time of the marker.
- onMouseOut - (function) It is generated at the mouse out of the marker.
- onMouseUp - (function) When the mouse of the marker improves, it is generated.
- onMouseDown - (function) When the mouse of the marker is downed, it is generated.
- onVisibleChanged - (function) When the marker's display changes, it is generated.
- onZIndexChanged - (function) When the order of displaying the marker changes, it is generated.
- onPositionChanged - (function) When the display coordinates of the marker are changed, it is generated.
- onCurrentChanged - (function) When the image changes, it is generated.
- onActive - (function) When the marker becomes active, it is generated.
images
Array of object with following information
- title - (number) Title of image
- image - (boolean) URL of image
- url - (boolean) URL
Method: setCurrent
The specified image is set to a present image.
Syntax:
marker.setCurrent(1);
Arguments:
- index - (number) Number of image
Method: getCurrent
A present image number is returned.
Syntax:
marker.getCurrent();
Returns:
(number) Image information set to image
Method: getCurrentImage
Information in a present image is acquired.
Syntax:
marker.getCurrentImage();
Returns:
(object) - Information in present image
Method: getImages
The image information set to the image is acquired.
Syntax:
var images = marker.getImages();
Returns:
(array) Image information set to image
Method: setImages
The image is set to the marker.
Syntax:
marker.setImages(images);
Arguments:
- images - (array) Set image
Returns:
(object) marker object
Method: addImage
The image is added to the marker.
Syntax:
marker.addImage(image);
Arguments:
- image - (object) Information in added image
Returns:
(object) marker object
Method: addImages
The image is added to two or more markers.
Syntax:
var images = [{
title: 'demo3',
image: '../Demos/images/demo/img03.jpg',
url: 'http://sharedhat.com'
}, {
title: 'demo4',
image: '../Demos/images/demo/img04.jpg',
url: 'http://sharedhat.com'
}];
marker.addImages(images);
Arguments:
- images - (array) Added image
Method: removeImage
The image is deleted from the marker.
Syntax:
marker.removeImage(image);
Arguments:
- image - (object) Image deleted from marker
Method: removeImages
Two or more images are deleted from the marker.
Syntax:
//When you enumerate the marker
marker.removeImages(image1, image2);
//When specifying it by the array
var images = [image1, image2];
marker.removeImages(images);
Arguments:
- images - (mixed) Image deleted from marker
Method: isStart
The state of the slide of the image of the marker is returned.
Syntax:
if (marker.isStart()) {
console.log('It is executing it.');
}
Returns:
(boolean) State of beginning of slide
Method: start
The slide of the image is begun.
Syntax:
marker.start();
Method: stop
The slide of the image is stopped.
Syntax:
marker.stop();