MooPano 0.2

Simple mootools based panorama viewer.

Based on: http://mootools.net/forge/p/zoomer

Demo: http://moopano.jeanphi.fr



Details

Author
Jean-philippe Serafin
Current version
0.2
GitHub
jean-philippe/moopano
Downloads
2183
Category
Interface
Tags
Report
GitHub Issues

Releases


Dependencies

  • core/1.3.2: *

How to use

Simple panorama:

window.addEvent('load', function(){
    /* simple panorama */
    var simple = new MooPano('simple-panorama', {
        big: 'images/big.jpg',
    });
});

Panorama with markers:

window.addEvent('load', function(){
    /* marked panorama */
    var marked = new MooPano('marked-panorama', {
        big: 'images/big.jpg',
        points: {
            'chateau': new MooPano.Marker({title: 'le château', top: 40, left: 90}),
            'cite': new MooPano.Marker({title: 'la cité médiévale', top: 120, left: 107}),
            'hospitalet': new MooPano.Marker({title: 'l\'hôspitalet', top: 49, left: 821})
        }
    });
    Object.each(marked.options.points, function(point, id){
        document.id(id).addEvents({
            mouseenter: function(e){
                marked.displayPoint(id);
            },
            mouseleave: function(e){
                marked.hidePoint(id);
                marked.stopZoom();
            },
            click: function(e){
                marked.zoomToCenter({
                    x: marked.options.points[id].options.left,
                    y: marked.options.points[id].options.top
                });
                marked.displayPoint(id);
                e.stop();
            } 
        });
    });
});

Discuss

A note on comments here: These comments are moderated. No comments will show up until they are approved. Comments that are not productive (i.e. inflammatory, rude, etc) will not be approved.

Found a bug in this plugin? Please report it this repository's Github Issues.

blog comments powered by Disqus