Skip to content
Code-Schnipsel Gruppen Projekte
Commit 0bcf2ee9 erstellt von Florian Bogner's avatar Florian Bogner
Dateien durchsuchen

style: Codestyle and documentation

Übergeordneter e5c4fe67
No related branches found
No related tags found
Keine zugehörigen Merge Requests gefunden
<?php
/**
* Activates the plugin
*
* @param pluginName
*
*/
QUI::$Ajax->registerFunction(
'package_quiqqer_ckeditor4_ajax_activatePlugin',
function ($pluginName) {
......
<?php
/**
* Deactivates the plugin
*
* @param pluginName
*
*/
QUI::$Ajax->registerFunction(
'package_quiqqer_ckeditor4_ajax_deactivatePlugin',
function ($pluginName) {
......
<?php
/**
* Retrieves data about the active plugins
*
* Returnformat:
* array(
* 'plugins' => array('plugin1','plugin2','plugin3'...),
* 'pluginpath' => 'path/to/plugins'
* )
*
* @param pluginName
*
*/
QUI::$Ajax->registerFunction(
'package_quiqqer_ckeditor4_ajax_getPluginData',
function () {
......
<?php
/**
* Gets all plugins and their state
*/
QUI::$Ajax->registerFunction(
'package_quiqqer_ckeditor4_ajax_getPlugins',
function () {
......
<?php
QUI::$Ajax->registerFunction(
'package_quiqqer_ckeditor4_ajax_installPlugin',
function ($pluginName) {
$PluginManager = new \QUI\Ckeditor4\Plugins\Manager();
},
array('pluginName')
);
<?php
QUI::$Ajax->registerFunction(
'package_quiqqer_ckeditor4_ajax_uninstallPlugin',
function ($pluginName) {
$PluginManager = new \QUI\Ckeditor4\Plugins\Manager();
},
array('pluginName')
);
......@@ -46,6 +46,11 @@ define('package/quiqqer/ckeditor4/bin/Editor', [
'$onInstanceReadyListener'
],
/**
* Control Constructor
* @param Manager
* @param options
*/
initialize: function (Manager, options) {
this.parent(Manager, options);
......@@ -447,108 +452,6 @@ define('package/quiqqer/ckeditor4/bin/Editor', [
}
},
// /**
// * Generate the extra plugins option in dependence of the toolbar
// * @param toolbar
// */
// $parseToolbarToPlugins: function (toolbar) {
// var extra = [],
// buttonList = [];
//
// if (typeOf(toolbar) == 'array') {
// buttonList = toolbar.flatten();
// }
//
// for (var i = 0, len = buttonList.length; i < len; i++) {
// switch (buttonList[i]) {
// case 'Templates':
// extra.push('templates');
// break;
//
// case 'Find':
// case 'Replace':
// extra.push('find');
// break;
//
// case 'SelectAll':
// extra.push('selectall');
// break;
//
// case 'Form':
// case 'Checkbox':
// case 'Radio':
// case 'TextField':
// case 'Textarea':
// case 'Select':
// case 'Button':
// case 'ImageButton':
// case 'HiddenField':
// extra.push('forms');
// break;
//
// case 'CreateDiv':
// extra.push('div');
// break;
//
// case 'JustifyLeft':
// case 'JustifyCenter':
// case 'JustifyRight':
// case 'JustifyBlock':
// extra.push('justify');
// break;
//
// case 'BidiLtr':
// case 'BidiRtl':
// extra.push('bidi');
// break;
//
// case 'Language':
// extra.push('language');
// break;
//
// case 'Link':
// case 'Unlink':
// case 'Anchor':
// extra.push('link');
// break;
//
// case 'Flash':
// extra.push('flash');
// break;
//
// case 'Smiley':
// extra.push('smiley');
// break;
//
// case 'PageBreak':
// extra.push('pagebreak');
// break;
//
// case 'Iframe':
// extra.push('iframe');
// break;
//
// case 'Font':
// case 'FontSize':
// extra.push('font');
// break;
//
// case 'BGColor':
// case 'TextColor':
// extra.push('colorbutton');
// break;
// }
// }
//
// //extra.push('wordcount');
//
// extra = extra.unique();
//
//
// return extra.join(',');
// }
// ,
/**
* edit the image dialog
*
......
......@@ -21,6 +21,10 @@ define('package/quiqqer/ckeditor4/bin/controls/settings/Plugins', [
options: {},
/**
* Control constructor
* @param options
*/
initialize: function (options) {
this.parent(options);
......@@ -38,7 +42,9 @@ define('package/quiqqer/ckeditor4/bin/controls/settings/Plugins', [
});
},
/**
* Eventhandler onCreate
*/
$onCreate: function () {
var self = this;
......@@ -149,6 +155,9 @@ define('package/quiqqer/ckeditor4/bin/controls/settings/Plugins', [
this.$Grid.resize();
},
/**
* Refreshes the plugin table
*/
refresh: function () {
var self = this;
......@@ -183,6 +192,10 @@ define('package/quiqqer/ckeditor4/bin/controls/settings/Plugins', [
});
},
/**
* Toggles the state of the selected plugin
* @returns {*}
*/
$toggleState: function () {
var self = this;
return new Promise(function (resolve) {
......@@ -229,6 +242,11 @@ define('package/quiqqer/ckeditor4/bin/controls/settings/Plugins', [
});
},
/**
* Disable the plugin with the given name
* @param name
* @returns {*}
*/
$disablePlugin: function (name) {
return new Promise(function (resolve, reject) {
......@@ -240,6 +258,11 @@ define('package/quiqqer/ckeditor4/bin/controls/settings/Plugins', [
});
},
/**
* Enable the plugin with the given name
* @param name
* @returns {*}
*/
$enablePlugin: function (name) {
return new Promise(function (resolve, reject) {
QUIAjax.post("package_quiqqer_ckeditor4_ajax_activatePlugin", resolve, {
......@@ -250,7 +273,6 @@ define('package/quiqqer/ckeditor4/bin/controls/settings/Plugins', [
});
}
}
);
});
\ No newline at end of file
0% oder .
You are about to add 0 people to the discussion. Proceed with caution.
Bearbeitung dieser Nachricht zuerst beenden!
Bitte registrieren oder zum Kommentieren