// JavaScript Document
// [zenphoto album="sports-mecaniques/gp-france" image="2010-05-23_gp-france-2010_5321.jpg"]
// ed.selection.setContent('[mylink]' + ed.selection.getContent() + '[/mylink]');
//image : url+'/mylink.png',

tinymce.create('tinymce.plugins.zp', {
    init : function(editor, url) {
        editor.addButton('zp', {
            title : 'Zenphoto',
            image : url+'/zenphoto.gif',
            onclick : function() {
                 editor.selection.setContent('[zenphoto album="" image=""]');
 				editor.undoManager.add();
            }
        });
    },
    createControl : function(n, cm) {
        return null;
    },
});
tinymce.PluginManager.add('zp', tinymce.plugins.zp);



/*
tinymce.create('tinymce.plugins.spoil',{
    init : function(editor,url){
        editor.addButton('spoiler',{
            title : 'Ajouter un Spoiler',
            image : url + '/zenphoto.gif',
            onclick : function(){
                editor.selection.setContent('[spoiler]'+editor.selection.getContent()+'[/spoiler]')
            }
        })
    },
    createControl : function(n,cm){
        return null;
    }
});
tinymce.PluginManager.add('spoiler',tinymce.plugins.spoil);
*/