-
Notifications
You must be signed in to change notification settings - Fork 3
/
plugin.min.js
13 lines (13 loc) · 995 Bytes
/
plugin.min.js
1
2
3
4
5
6
7
8
9
10
11
12
13
/**
* QR code - a TinyMCE 4 QR code wizzard
* qrcode/plugin.js
*
*
* Plugin info: http://www.cfconsultancy.nl/
* Author: Ceasar Feijen
*
* Version: 1.0 released 15/09/2013
*/
tinymce.PluginManager.add('qrcode',function(editor){function openmanager(){var title="Create QRcode";if(typeof tinymce.settings.qrcode_title!=="undefined"&&tinymce.settings.qrcode_title){title=tinymce.settingsqrcode_title;}
win=editor.windowManager.open({title:title,file:tinyMCE.baseURL+'/plugins/qrcode/qrcode.html',filetype:'image',width:650,height:510,inline:1,buttons:[{text:'cancel',onclick:function(){this.parent().parent().close();}}]});}
editor.addButton('qrcode',{icon:true,image:tinyMCE.baseURL+'/plugins/qrcode/icon.png',tooltip:'Create QRcode',shortcut:'Ctrl+M',onclick:openmanager});editor.addShortcut('Ctrl+M','',openmanager);editor.addMenuItem('qrcode',{icon:true,image:tinyMCE.baseURL+'/plugins/qrcode/icon.png',text:'Create QRcode',shortcut:'Ctrl+M',onclick:openmanager,context:'insert'});});