mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
8f23fa99a5
The 'admin' module will be split off from 'framework', where 'framework' only provides (mostly) frontend-agnostic PHP classes. For example, HTMLEditorField.php has a TinyMCEConfig.php driver, but doesn't come with its own JS includes.
33 lines
624 B
JavaScript
33 lines
624 B
JavaScript
/**
|
|
* plugin.js
|
|
*
|
|
* Released under LGPL License.
|
|
* Copyright (c) 1999-2015 Ephox Corp. All rights reserved
|
|
*
|
|
* License: http://www.tinymce.com/license
|
|
* Contributing: http://www.tinymce.com/contributing
|
|
*/
|
|
|
|
/*global tinymce:true */
|
|
|
|
tinymce.PluginManager.add('print', function(editor) {
|
|
editor.addCommand('mcePrint', function() {
|
|
editor.getWin().print();
|
|
});
|
|
|
|
editor.addButton('print', {
|
|
title: 'Print',
|
|
cmd: 'mcePrint'
|
|
});
|
|
|
|
editor.addShortcut('Meta+P', '', 'mcePrint');
|
|
|
|
editor.addMenuItem('print', {
|
|
text: 'Print',
|
|
cmd: 'mcePrint',
|
|
icon: 'print',
|
|
shortcut: 'Meta+P',
|
|
context: 'file'
|
|
});
|
|
});
|