Black Studio TinyMCE Widget - Version 2.0.0

Version Description

(2014-10-06) = * Total refactoring of plugin's source code * Enhanced integration with TinyMCE editor for better compatibility with other plugins * Added support for QuickTags toolbar in HTML mode * Added support for mobile devices (responsive width in widgets administration page) * Added project to GitHub * Added project to Transifex translation platform * Added many new translations thanks to WP-Translation.org team * Added several filter and action hooks * Improved code quality and security thanks to Scrutinizer service * Improved development workflow thanks to Grunt * Improved performance and user experience * A huge Thanks to @cfoellmann for his precious support and contributions

Download this release

Release Info

Developer marcochiesi
Plugin Icon 128x128 Black Studio TinyMCE Widget
Version 2.0.0
Comparing to
See all releases

Code changes from version 1.4.8 to 2.0.0

Files changed (78) hide show
  1. black-studio-tinymce-widget-legacy.css +0 -70
  2. black-studio-tinymce-widget-legacy.js +0 -131
  3. black-studio-tinymce-widget-legacy.min.js +0 -1
  4. black-studio-tinymce-widget.css +0 -7
  5. black-studio-tinymce-widget.js +0 -160
  6. black-studio-tinymce-widget.min.js +0 -1
  7. black-studio-tinymce-widget.php +238 -302
  8. css/black-studio-tinymce-widget-pre33.css +99 -0
  9. css/black-studio-tinymce-widget-pre33.min.css +2 -0
  10. css/black-studio-tinymce-widget.css +55 -0
  11. css/black-studio-tinymce-widget.min.css +2 -0
  12. includes/class-admin.php +371 -0
  13. includes/class-compatibility-plugins.php +360 -0
  14. includes/class-compatibility-wordpress.php +349 -0
  15. includes/class-compatibility.php +150 -0
  16. includes/class-text-filters.php +161 -0
  17. includes/class-widget.php +123 -0
  18. includes/deprecated.php +152 -0
  19. js/black-studio-tinymce-widget-pre33.js +244 -0
  20. js/black-studio-tinymce-widget-pre33.min.js +2 -0
  21. js/black-studio-tinymce-widget-pre39.js +278 -0
  22. js/black-studio-tinymce-widget-pre39.min.js +2 -0
  23. js/black-studio-tinymce-widget.js +311 -0
  24. js/black-studio-tinymce-widget.min.js +2 -0
  25. js/wp-page-widget.js +27 -0
  26. js/wp-page-widget.min.js +2 -0
  27. languages/black-studio-tinymce-widget-ca.mo +0 -0
  28. languages/black-studio-tinymce-widget-ca.po +84 -0
  29. languages/black-studio-tinymce-widget-da_DK.mo +0 -0
  30. languages/black-studio-tinymce-widget-da_DK.po +67 -21
  31. languages/black-studio-tinymce-widget-de_DE.mo +0 -0
  32. languages/black-studio-tinymce-widget-de_DE.po +66 -21
  33. languages/black-studio-tinymce-widget-el.mo +0 -0
  34. languages/black-studio-tinymce-widget-el.po +84 -0
  35. languages/black-studio-tinymce-widget-en_GB.mo +0 -0
  36. languages/black-studio-tinymce-widget-en_GB.po +84 -0
  37. languages/black-studio-tinymce-widget-es_ES.mo +0 -0
  38. languages/black-studio-tinymce-widget-es_ES.po +66 -38
  39. languages/black-studio-tinymce-widget-fi.mo +0 -0
  40. languages/black-studio-tinymce-widget-fi.po +85 -0
  41. languages/black-studio-tinymce-widget-fi_FI.mo +0 -0
  42. languages/black-studio-tinymce-widget-fi_FI.po +0 -37
  43. languages/black-studio-tinymce-widget-fr_FR.mo +0 -0
  44. languages/black-studio-tinymce-widget-fr_FR.po +85 -0
  45. languages/black-studio-tinymce-widget-it_IT.mo +0 -0
  46. languages/black-studio-tinymce-widget-it_IT.po +63 -32
  47. languages/black-studio-tinymce-widget-ja.mo +0 -0
  48. languages/black-studio-tinymce-widget-ja.po +84 -0
  49. languages/black-studio-tinymce-widget-ko_KR.mo +0 -0
  50. languages/black-studio-tinymce-widget-ko_KR.po +84 -0
  51. languages/black-studio-tinymce-widget-nl_NL.mo +0 -0
  52. languages/black-studio-tinymce-widget-nl_NL.po +85 -0
  53. languages/black-studio-tinymce-widget-pl_PL.mo +0 -0
  54. languages/black-studio-tinymce-widget-pl_PL.po +84 -0
  55. languages/black-studio-tinymce-widget-pt_BR.mo +0 -0
  56. languages/black-studio-tinymce-widget-pt_BR.po +84 -0
  57. languages/black-studio-tinymce-widget-ro_RO.mo +0 -0
  58. languages/black-studio-tinymce-widget-ro_RO.po +84 -0
  59. languages/black-studio-tinymce-widget-ru_RU.mo +0 -0
  60. languages/black-studio-tinymce-widget-ru_RU.po +84 -0
  61. languages/black-studio-tinymce-widget-sk_SK.mo +0 -0
  62. languages/black-studio-tinymce-widget-sk_SK.po +85 -0
  63. languages/black-studio-tinymce-widget-sv_SE.mo +0 -0
  64. languages/black-studio-tinymce-widget-sv_SE.po +65 -39
  65. languages/black-studio-tinymce-widget-tr_TR.mo +0 -0
  66. languages/black-studio-tinymce-widget-tr_TR.po +84 -0
  67. languages/black-studio-tinymce-widget-uk.mo +0 -0
  68. languages/black-studio-tinymce-widget-uk.po +84 -0
  69. languages/black-studio-tinymce-widget-zh_CN.mo +0 -0
  70. languages/black-studio-tinymce-widget-zh_CN.po +85 -0
  71. languages/black-studio-tinymce-widget.pot +66 -19
  72. languages/black-studio-tinymce-widget_sk_SK.mo +0 -0
  73. languages/black-studio-tinymce-widget_sk_SK.po +0 -37
  74. languages/black-studio-tinymce-widget_uk_UA.mo +0 -0
  75. languages/black-studio-tinymce-widget_uk_UA.po +0 -37
  76. readme.txt +301 -261
  77. screenshot-1.png +0 -0
  78. screenshot-2.png +0 -0
black-studio-tinymce-widget-legacy.css DELETED
@@ -1,70 +0,0 @@
1
- /* CSS Document */
2
-
3
- #mce_fullscreen_container {
4
- background-color: white;
5
- }
6
-
7
- #wp-black-studio-tinymce-widget-wrap {
8
- display: none;
9
- }
10
-
11
- .editor_container {
12
- background-color: #FFF;
13
- border-color: #DEDEDE;
14
- border-style: solid;
15
- border-width: 1px;
16
- border-collapse: separate;
17
- border-top-right-radius: 3px;
18
- border-top-left-radius: 3px;
19
- padding: 0 1px 1px 1px;
20
- clear: both;
21
- }
22
- .editor_toggle_buttons {
23
- margin-right: 15px;
24
- margin-top: 8px;
25
- float: right;
26
- }
27
- .editor_toggle_buttons a {
28
- background: none repeat scroll 0 0 #EBEBEB;
29
- border: 1px solid #DEDEDE;
30
- color: #777777;
31
- cursor: pointer;
32
- float: right;
33
- font: 13px/19px "Open Sans",sans-serif;
34
- margin: 5px 0 0 5px;
35
- padding: 3px 8px 4px;
36
- position: relative;
37
- top: 1px;
38
- }
39
- .editor_toggle_buttons a.active {
40
- background: none repeat scroll 0 0 #F5F5F5;
41
- border-bottom: 0 none;
42
- color: #555555;
43
- height: 20px;
44
- }
45
- .editor_toggle_buttons_legacy a.active {
46
- border-color: #CCC #CCC #E9E9E9;
47
- background-color: #E9E9E9;
48
- }
49
- .editor_media_buttons {
50
- cursor: default;
51
- padding: 8px 8px;
52
- height: 22px;
53
- }
54
- .editor_media_buttons a {
55
- cursor: pointer;
56
- text-decoration: none;
57
- color: #333;
58
- font-size: 12px;
59
- margin-right: 8px;
60
- }
61
- .editor_media_buttons img {
62
- vertical-align: middle;
63
- padding: 0 4px;
64
- }
65
- .editor_links {
66
- font-size: 10px;
67
- text-align: right;
68
- padding-top: 3px;
69
- padding-bottom: 3px;
70
- }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
black-studio-tinymce-widget-legacy.js DELETED
@@ -1,131 +0,0 @@
1
- // TinyMCE initialization parameters
2
- var tinyMCEPreInit;
3
- // Current editor (backward compatibility)
4
- var edCanvas;
5
- // Current editor
6
- var wpActiveEditor;
7
-
8
- (function($) {
9
- // Activate visual editor
10
- function black_studio_activate_visual_editor(id) {
11
- $('#'+id).addClass("mceEditor");
12
- if ( typeof( tinyMCE ) == "object" && typeof( tinyMCE.execCommand ) == "function" ) {
13
- black_studio_deactivate_visual_editor(id);
14
- if (typeof (tinyMCEPreInit.mceInit['black-studio-tinymce-widget']) == "object") { // WP 3.3+
15
- tinyMCEPreInit.mceInit[id] = tinyMCEPreInit.mceInit['black-studio-tinymce-widget'];
16
- tinyMCEPreInit.mceInit[id]["elements"] = id;
17
- try {
18
- // Instantiate new TinyMCE editor
19
- tinymce.init(tinymce.extend( {}, tinyMCEPreInit.mceInit['black-studio-tinymce-widget'], tinyMCEPreInit.mceInit[id] ));
20
- } catch(e){
21
- alert(e);
22
- }
23
- }
24
- else { // WP 3.2
25
- tinyMCE.execCommand("mceAddControl", false, id);
26
- }
27
- }
28
- }
29
- // Deactivate visual editor
30
- function black_studio_deactivate_visual_editor(id) {
31
- if ( typeof( tinyMCE ) == "object" && typeof( tinyMCE.execCommand ) == "function" ) {
32
- if (typeof(tinyMCE.get(id)) == "object") {
33
- var content = tinyMCE.get(id).getContent();
34
- tinyMCE.execCommand("mceRemoveControl", false, id);
35
- $('textarea#'+id).val(content);
36
- }
37
- }
38
- }
39
- // Activate editor deferred (used upon opening the widget)
40
- function black_studio_open_deferred_activate_visual_editor(id) {
41
- $('div.widget-inside:has(#' + id + ') input[id^=widget-black-studio-tinymce][id$=type][value=visual]').each(function() {
42
- // If textarea is visible and animation/ajax has completed (or in accessibility mode) then trigger a click to Visual button and enable the editor
43
- if ($('div.widget:has(#' + id + ') :animated').size() == 0 && typeof(tinyMCE.get(id)) != "object" && $('#' + id).is(':visible')) {
44
- $('a[id^=widget-black-studio-tinymce][id$=visual]', $(this).closest('div.widget-inside')).click();
45
- }
46
- // Otherwise wait and retry later (animation ongoing)
47
- else if (typeof(tinyMCE.get(id)) != "object") {
48
- setTimeout(function(){black_studio_open_deferred_activate_visual_editor(id);id=null;}, 100);
49
- }
50
- // If editor instance is already existing (i.e. dragged from another sidebar) just activate it
51
- else {
52
- $('a[id^=widget-black-studio-tinymce][id$=visual]', $(this).closest('div.widget-inside')).click();
53
- }
54
- });
55
- }
56
-
57
- // Activate editor deferred (used upon ajax requests)
58
- function black_studio_ajax_deferred_activate_visual_editor(id) {
59
- $('div.widget-inside:has(#' + id + ') input[id^=widget-black-studio-tinymce][id$=type][value=visual]').each(function() {
60
- // If textarea is visible and animation/ajax has completed then trigger a click to Visual button and enable the editor
61
- if ($.active == 0 && typeof(tinyMCE.get(id)) != "object" && $('#' + id).is(':visible')) {
62
- $('a[id^=widget-black-studio-tinymce][id$=visual]', $(this).closest('div.widget-inside')).click();
63
- }
64
- // Otherwise wait and retry later (animation ongoing)
65
- else if ($('div.widget:has(#' + id + ') div.widget-inside').is(':visible') && typeof(tinyMCE.get(id)) != "object") {
66
- setTimeout(function(){black_studio_ajax_deferred_activate_visual_editor(id);id=null;}, 100);
67
- }
68
- });
69
- }
70
-
71
-
72
- // Document ready stuff
73
- $(document).ready(function(){
74
- // Event handler for widget opening button
75
- $('div.widget:has(textarea[id^=widget-black-studio-tinymce]) a.widget-action').live('click', function(event){
76
- event.preventDefault();
77
- var $widget = $(this).closest('div.widget');
78
- var $text_area = $('textarea[id^=widget-black-studio-tinymce]', $widget);
79
- $('#wpbody-content').css('overflow', 'visible'); // needed for small screens
80
- $widget.css('position', 'relative').css('z-index', '100'); // needed for small screens
81
- black_studio_open_deferred_activate_visual_editor($text_area.attr('id'));
82
- });
83
- // Force BS handler of opening button to be executed before the one coming with Wordpress
84
- $(document).data("events").click.unshift($(document).data("events").click.pop());
85
- // Event handler for widget saving button
86
- $('div.widget[id*=black-studio-tinymce] input[name=savewidget]').live('click', function(event){
87
- event.preventDefault();
88
- var $widget = $(this).closest('div.widget')
89
- var $text_area = $('textarea[id^=widget-black-studio-tinymce]', $widget);
90
- if (typeof(tinyMCE.get($text_area.attr('id'))) == "object") {
91
- black_studio_deactivate_visual_editor($text_area.attr('id'));
92
- }
93
- // Event handler for ajax complete
94
- $(this).unbind('ajaxSuccess').ajaxSuccess(function(event, xhr, settings) {
95
- var $text_area = $('textarea[id^=widget-black-studio-tinymce]', $(this).closest('div.widget-inside'));
96
- black_studio_ajax_deferred_activate_visual_editor($text_area.attr('id'));
97
- });
98
- });
99
- // Force BS handler of save button to be executed before the one coming with Wordpress
100
- $(document).data("events").click.unshift($(document).data("events").click.pop());
101
- // Event handler for visual switch button
102
- $('a[id^=widget-black-studio-tinymce][id$=visual]').live('click', function(event){
103
- event.preventDefault();
104
- var $widget_inside = $(this).closest('div.widget-inside')
105
- $('input[id^=widget-black-studio-tinymce][id$=type]', $widget_inside).val('visual');
106
- $(this).addClass('active');
107
- $('a[id^=widget-black-studio-tinymce][id$=html]', $widget_inside).removeClass('active');
108
- black_studio_activate_visual_editor($('textarea[id^=widget-black-studio-tinymce]', $widget_inside).attr('id'));
109
- });
110
- // Event handler for html switch button
111
- $('a[id^=widget-black-studio-tinymce][id$=html]').live('click', function(event){
112
- event.preventDefault();
113
- var $widget_inside = $(this).closest('div.widget-inside')
114
- $('input[id^=widget-black-studio-tinymce][id$=type]', $widget_inside).val('html');
115
- $(this).addClass('active');
116
- $('a[id^=widget-black-studio-tinymce][id$=visual]', $widget_inside).removeClass('active');
117
- black_studio_deactivate_visual_editor($('textarea[id^=widget-black-studio-tinymce]', $widget_inside).attr('id'));
118
- });
119
- // Set edCanvas/wpActiveEditor variables used when adding media from media library dialog
120
- $('.editor_media_buttons a').live('click', function(){
121
- var $widget_inside = $(this).closest('div.widget-inside')
122
- edCanvas = $('textarea[id^=widget-black-studio-tinymce]', $widget_inside).get();
123
- wpActiveEditor = $('textarea[id^=widget-black-studio-tinymce]', $widget_inside).attr('id');
124
- });
125
- // Activate editor when in accessibility mode
126
- if($('body.widgets_access').size() > 0) {
127
- var $text_area = $('textarea[id^=widget-black-studio-tinymce]');
128
- black_studio_open_deferred_activate_visual_editor($text_area.attr('id'));
129
- }
130
- });
131
- })(jQuery); // end self-invoked wrapper function
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
black-studio-tinymce-widget-legacy.min.js DELETED
@@ -1 +0,0 @@
1
- var tinyMCEPreInit;var edCanvas;var wpActiveEditor;(function(c){function d(g){c("#"+g).addClass("mceEditor");if(typeof(tinyMCE)=="object"&&typeof(tinyMCE.execCommand)=="function"){b(g);if(typeof(tinyMCEPreInit.mceInit["black-studio-tinymce-widget"])=="object"){tinyMCEPreInit.mceInit[g]=tinyMCEPreInit.mceInit["black-studio-tinymce-widget"];tinyMCEPreInit.mceInit[g]["elements"]=g;try{tinymce.init(tinymce.extend({},tinyMCEPreInit.mceInit["black-studio-tinymce-widget"],tinyMCEPreInit.mceInit[g]))}catch(f){alert(f)}}else{tinyMCE.execCommand("mceAddControl",false,g)}}}function b(g){if(typeof(tinyMCE)=="object"&&typeof(tinyMCE.execCommand)=="function"){if(typeof(tinyMCE.get(g))=="object"){var f=tinyMCE.get(g).getContent();tinyMCE.execCommand("mceRemoveControl",false,g);c("textarea#"+g).val(f)}}}function a(f){c("div.widget-inside:has(#"+f+") input[id^=widget-black-studio-tinymce][id$=type][value=visual]").each(function(){if(c("div.widget:has(#"+f+") :animated").size()==0&&typeof(tinyMCE.get(f))!="object"&&c("#"+f).is(":visible")){c("a[id^=widget-black-studio-tinymce][id$=visual]",c(this).closest("div.widget-inside")).click()}else{if(typeof(tinyMCE.get(f))!="object"){setTimeout(function(){a(f);f=null},100)}else{c("a[id^=widget-black-studio-tinymce][id$=visual]",c(this).closest("div.widget-inside")).click()}}})}function e(f){c("div.widget-inside:has(#"+f+") input[id^=widget-black-studio-tinymce][id$=type][value=visual]").each(function(){if(c.active==0&&typeof(tinyMCE.get(f))!="object"&&c("#"+f).is(":visible")){c("a[id^=widget-black-studio-tinymce][id$=visual]",c(this).closest("div.widget-inside")).click()}else{if(c("div.widget:has(#"+f+") div.widget-inside").is(":visible")&&typeof(tinyMCE.get(f))!="object"){setTimeout(function(){e(f);f=null},100)}}})}c(document).ready(function(){c("div.widget:has(textarea[id^=widget-black-studio-tinymce]) a.widget-action").live("click",function(g){g.preventDefault();var i=c(this).closest("div.widget");var h=c("textarea[id^=widget-black-studio-tinymce]",i);c("#wpbody-content").css("overflow","visible");i.css("position","relative").css("z-index","100");a(h.attr("id"))});c(document).data("events").click.unshift(c(document).data("events").click.pop());c("div.widget[id*=black-studio-tinymce] input[name=savewidget]").live("click",function(g){g.preventDefault();var i=c(this).closest("div.widget");var h=c("textarea[id^=widget-black-studio-tinymce]",i);if(typeof(tinyMCE.get(h.attr("id")))=="object"){b(h.attr("id"))}c(this).unbind("ajaxSuccess").ajaxSuccess(function(k,l,j){var m=c("textarea[id^=widget-black-studio-tinymce]",c(this).closest("div.widget-inside"));e(m.attr("id"))})});c(document).data("events").click.unshift(c(document).data("events").click.pop());c("a[id^=widget-black-studio-tinymce][id$=visual]").live("click",function(g){g.preventDefault();var h=c(this).closest("div.widget-inside");c("input[id^=widget-black-studio-tinymce][id$=type]",h).val("visual");c(this).addClass("active");c("a[id^=widget-black-studio-tinymce][id$=html]",h).removeClass("active");d(c("textarea[id^=widget-black-studio-tinymce]",h).attr("id"))});c("a[id^=widget-black-studio-tinymce][id$=html]").live("click",function(g){g.preventDefault();var h=c(this).closest("div.widget-inside");c("input[id^=widget-black-studio-tinymce][id$=type]",h).val("html");c(this).addClass("active");c("a[id^=widget-black-studio-tinymce][id$=visual]",h).removeClass("active");b(c("textarea[id^=widget-black-studio-tinymce]",h).attr("id"))});c(".editor_media_buttons a").live("click",function(){var g=c(this).closest("div.widget-inside");edCanvas=c("textarea[id^=widget-black-studio-tinymce]",g).get();wpActiveEditor=c("textarea[id^=widget-black-studio-tinymce]",g).attr("id")});if(c("body.widgets_access").size()>0){var f=c("textarea[id^=widget-black-studio-tinymce]");a(f.attr("id"))}})})(jQuery);
 
black-studio-tinymce-widget.css DELETED
@@ -1,7 +0,0 @@
1
- /* CSS Document */
2
- #wp-black-studio-tinymce-widget-wrap {
3
- display: none;
4
- }
5
- #available-widgets [class*="black-studio-tinymce"] .widget-title:before {
6
- content: "\f116";
7
- }
 
 
 
 
 
 
 
black-studio-tinymce-widget.js DELETED
@@ -1,160 +0,0 @@
1
- // TinyMCE initialization parameters
2
- var tinyMCEPreInit;
3
- // Current editor
4
- var wpActiveEditor;
5
-
6
- (function( $ ) {
7
- // Activate visual editor
8
- function black_studio_activate_visual_editor(id) {
9
- $( '#' + id ).addClass( 'mceEditor' );
10
- if ( typeof tinyMCE == 'object' && typeof tinyMCE.execCommand == 'function' ) {
11
- black_studio_deactivate_visual_editor( id );
12
- tinyMCEPreInit.mceInit[id] = tinyMCEPreInit.mceInit['black-studio-tinymce-widget'];
13
- tinyMCEPreInit.mceInit[id]['selector'] = '#' + id;
14
- try {
15
- // Instantiate new TinyMCE editor
16
- tinymce.init( tinymce.extend( {}, tinyMCEPreInit.mceInit['black-studio-tinymce-widget'], tinyMCEPreInit.mceInit[id] ) );
17
- tinyMCE.execCommand( 'mceAddControl', false, id );
18
- } catch( e ) {
19
- alert( e );
20
- }
21
- if ( tinyMCE.get( id ) != null) {
22
- if ( typeof tinyMCE.get( id ).on == 'function' ) {
23
- tinyMCE.get( id ).on( 'keyup change', function() {
24
- var content = tinyMCE.get( id ).getContent();
25
- $( 'textarea#' + id ).val( content ).change();
26
- });
27
- }
28
- }
29
- }
30
- }
31
- // Deactivate visual editor
32
- function black_studio_deactivate_visual_editor( id ) {
33
- if ( typeof tinyMCE == 'object' && typeof tinyMCE.execCommand == 'function' ) {
34
- if ( tinyMCE.get( id ) != null && typeof tinyMCE.get( id ).getContent == 'function' ) {
35
- var content = tinyMCE.get( id ).getContent();
36
- // tinyMCE.execCommand('mceRemoveControl', false, id);
37
- tinyMCE.get( id ).remove();
38
- $( 'textarea#' + id ).val( content );
39
- }
40
- }
41
- }
42
- // Activate editor deferred (used upon opening the widget)
43
- function black_studio_open_deferred_activate_visual_editor( id ) {
44
- $( 'div.widget-inside:has(#' + id + ') input[id^=widget-black-studio-tinymce][id$=type][value=visual]' ).each(function() {
45
- // If textarea is visible and animation/ajax has completed (or in accessibility mode) then trigger a click to Visual button and enable the editor
46
- if ( $('div.widget:has(#' + id + ') :animated' ).size() == 0 && tinyMCE.get( id ) == null && $( '#' + id ).is( ':visible' ) ) {
47
- $( 'a[id^=widget-black-studio-tinymce][id$=tmce]', $( this ).closest( 'div.widget-inside' ) ).click();
48
- }
49
- // Otherwise wait and retry later (animation ongoing)
50
- else if ( tinyMCE.get( id ) == null ) {
51
- setTimeout(function() {
52
- black_studio_open_deferred_activate_visual_editor( id );
53
- id = null;
54
- }, 100 );
55
- }
56
- // If editor instance is already existing (i.e. dragged from another sidebar) just activate it
57
- else {
58
- $( 'a[id^=widget-black-studio-tinymce][id$=tmce]', $( this ).closest( 'div.widget-inside' ) ).click();
59
- }
60
- });
61
- }
62
-
63
- // Activate editor deferred (used upon ajax requests)
64
- function black_studio_ajax_deferred_activate_visual_editor( id ) {
65
- $( 'div.widget-inside:has(#' + id + ') input[id^=widget-black-studio-tinymce][id$=type][value=visual]' ).each(function() {
66
- // If textarea is visible and animation/ajax has completed then trigger a click to Visual button and enable the editor
67
- if ( $.active == 0 && tinyMCE.get( id ) == null && $( '#' + id ).is( ':visible' ) ) {
68
- $( 'a[id^=widget-black-studio-tinymce][id$=tmce]', $( this ).closest( 'div.widget-inside' ) ).click();
69
- }
70
- // Otherwise wait and retry later (animation ongoing)
71
- else if ( $( 'div.widget:has(#' + id + ') div.widget-inside' ).is( ':visible' ) && tinyMCE.get( id ) == null ) {
72
- setTimeout(function() {
73
- black_studio_ajax_deferred_activate_visual_editor( id );
74
- id=null;
75
- }, 100 );
76
- }
77
- });
78
- }
79
-
80
-
81
-
82
- // Document ready stuff
83
- $( document ).ready(function() {
84
- // Event handler for widget opening button
85
- $( document ).on( 'click', 'div.widget:has(textarea[id^=widget-black-studio-tinymce]) .widget-title, div.widget:has(textarea[id^=widget-black-studio-tinymce]) a.widget-action', function( event ) {
86
- //event.preventDefault();
87
- var $widget = $( this ).closest( 'div.widget' );
88
- var $text_area = $( 'textarea[id^=widget-black-studio-tinymce]', $widget );
89
- if ( $( '[name="' + $( '#' + $text_area.attr('id') ).attr('name') + '"]' ).size() > 1) {
90
- var $widget_inside = $( 'div.widget-inside', $widget );
91
- if ( $( 'div.error', $widget_inside).length == 0 ) {
92
- $widget_inside.prepend('<div class="error"><strong>' + black_studio_tinymce_local.error_duplicate_id + '</strong></div>');
93
- }
94
- }
95
- // Event handler for widget saving button (for new instances)
96
- $( 'input[name=savewidget]', $widget ).on( 'click', function( event ) {
97
- var $widget = $( this ).closest( 'div.widget' )
98
- var $text_area = $( 'textarea[id^=widget-black-studio-tinymce]', $widget );
99
- if ( tinyMCE.get( $text_area.attr( 'id' ) ) != null ) {
100
- black_studio_deactivate_visual_editor( $text_area.attr( 'id' ) );
101
- }
102
- // Event handler for ajax complete
103
- $( this ).unbind( 'ajaxSuccess' ).ajaxSuccess( function( event, xhr, settings ) {
104
- var $text_area = $( 'textarea[id^=widget-black-studio-tinymce]', $( this ).closest( 'div.widget-inside') );
105
- black_studio_ajax_deferred_activate_visual_editor( $text_area.attr( 'id' ) );
106
- });
107
- });
108
- $( '#wpbody-content' ).css( 'overflow', 'visible' ); // needed for small screens
109
- $widget.css( 'position', 'relative' ).css( 'z-index', '100000' ); // needed for small screens and for fullscreen mode
110
- black_studio_open_deferred_activate_visual_editor( $text_area.attr( 'id' ) );
111
- $( '.insert-media', $widget ).data( 'editor', $text_area.attr( 'id' ) );
112
- });
113
- // Event handler for widget saving button (for existing instances)
114
- $( 'div.widget[id*=black-studio-tinymce] input[name=savewidget]').on( 'click', function( event ) {
115
- var $widget = $( this ).closest( 'div.widget' )
116
- var $text_area = $( 'textarea[id^=widget-black-studio-tinymce]', $widget );
117
- if ( tinyMCE.get( $text_area.attr( 'id' ) ) != null ) {
118
- black_studio_deactivate_visual_editor( $text_area.attr( 'id' ) );
119
- }
120
- // Event handler for ajax complete
121
- $( this ).unbind( 'ajaxSuccess' ).ajaxSuccess( function( event, xhr, settings ) {
122
- var $text_area = $( 'textarea[id^=widget-black-studio-tinymce]', $( this ).closest( 'div.widget-inside' ) );
123
- black_studio_ajax_deferred_activate_visual_editor( $text_area.attr( 'id' ) );
124
- });
125
- });
126
- // Event handler for visual switch button
127
- $( document ).on( 'click', 'a[id^=widget-black-studio-tinymce][id$=tmce]', function( event ) {
128
- //event.preventDefault();
129
- var $widget_inside = $( this ).closest( 'div.widget-inside,div.panel-dialog' );
130
- var $wrap_id = $( 'div[id^=wp-widget-black-studio-tinymce][id$=-wrap]', $widget_inside );
131
- var $textarea_id = $( 'textarea[id^=widget-black-studio-tinymce]', $widget_inside ).attr( 'id' )
132
- tinymce.DOM.removeClass( $wrap_id, 'html-active' );
133
- tinymce.DOM.addClass( $wrap_id, 'tmce-active' );
134
- $( 'input[id^=widget-black-studio-tinymce][id$=type]', $widget_inside ).val( 'visual' );
135
- black_studio_activate_visual_editor( $textarea_id );
136
- });
137
- // Event handler for html switch button
138
- $( document ).on( 'click', 'a[id^=widget-black-studio-tinymce][id$=html]', function( event ) {
139
- //event.preventDefault();
140
- var $widget_inside = $( this ).closest( 'div.widget-inside,div.panel-dialog' );
141
- var $wrap_id = $( 'div[id^=wp-widget-black-studio-tinymce][id$=-wrap]', $widget_inside );
142
- var $textarea_id = $( 'textarea[id^=widget-black-studio-tinymce]', $widget_inside ).attr( 'id' )
143
- $( 'input[id^=widget-black-studio-tinymce][id$=type]', $widget_inside ).val( 'visual' );
144
- tinymce.DOM.removeClass( $wrap_id, 'tmce-active' );
145
- tinymce.DOM.addClass( $wrap_id, 'html-active' );
146
- $( 'input[id^=widget-black-studio-tinymce][id$=type]', $widget_inside ).val( 'html' );
147
- black_studio_deactivate_visual_editor( $textarea_id );
148
- });
149
- // Set wpActiveEditor variables used when adding media from media library dialog
150
- $( document ).on( 'click', '.wp-media-buttons a', function() {
151
- var $widget_inside = $( this ).closest( 'div.widget-inside' );
152
- wpActiveEditor = $( 'textarea[id^=widget-black-studio-tinymce]', $widget_inside ).attr( 'id' );
153
- });
154
- // Activate editor when in accessibility mode
155
- if ( $( 'body.widgets_access' ).size() > 0) {
156
- var $text_area = $( 'textarea[id^=widget-black-studio-tinymce]' );
157
- black_studio_open_deferred_activate_visual_editor( $text_area.attr( 'id' ) );
158
- }
159
- });
160
- })( jQuery ); // end self-invoked wrapper function
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
black-studio-tinymce-widget.min.js DELETED
@@ -1 +0,0 @@
1
- var tinyMCEPreInit;var wpActiveEditor;(function(c){function d(g){c("#"+g).addClass("mceEditor");if(typeof tinyMCE=="object"&&typeof tinyMCE.execCommand=="function"){b(g);tinyMCEPreInit.mceInit[g]=tinyMCEPreInit.mceInit["black-studio-tinymce-widget"];tinyMCEPreInit.mceInit[g]["selector"]="#"+g;try{tinymce.init(tinymce.extend({},tinyMCEPreInit.mceInit["black-studio-tinymce-widget"],tinyMCEPreInit.mceInit[g]));tinyMCE.execCommand("mceAddControl",false,g)}catch(f){alert(f)}if(tinyMCE.get(g)!=null){if(typeof tinyMCE.get(g).on=="function"){tinyMCE.get(g).on("keyup change",function(){var h=tinyMCE.get(g).getContent();c("textarea#"+g).val(h).change()})}}}}function b(g){if(typeof tinyMCE=="object"&&typeof tinyMCE.execCommand=="function"){if(tinyMCE.get(g)!=null&&typeof tinyMCE.get(g).getContent=="function"){var f=tinyMCE.get(g).getContent();tinyMCE.get(g).remove();c("textarea#"+g).val(f)}}}function a(f){c("div.widget-inside:has(#"+f+") input[id^=widget-black-studio-tinymce][id$=type][value=visual]").each(function(){if(c("div.widget:has(#"+f+") :animated").size()==0&&tinyMCE.get(f)==null&&c("#"+f).is(":visible")){c("a[id^=widget-black-studio-tinymce][id$=tmce]",c(this).closest("div.widget-inside")).click()}else{if(tinyMCE.get(f)==null){setTimeout(function(){a(f);f=null},100)}else{c("a[id^=widget-black-studio-tinymce][id$=tmce]",c(this).closest("div.widget-inside")).click()}}})}function e(f){c("div.widget-inside:has(#"+f+") input[id^=widget-black-studio-tinymce][id$=type][value=visual]").each(function(){if(c.active==0&&tinyMCE.get(f)==null&&c("#"+f).is(":visible")){c("a[id^=widget-black-studio-tinymce][id$=tmce]",c(this).closest("div.widget-inside")).click()}else{if(c("div.widget:has(#"+f+") div.widget-inside").is(":visible")&&tinyMCE.get(f)==null){setTimeout(function(){e(f);f=null},100)}}})}c(document).ready(function(){c(document).on("click","div.widget:has(textarea[id^=widget-black-studio-tinymce]) .widget-title, div.widget:has(textarea[id^=widget-black-studio-tinymce]) a.widget-action",function(g){var j=c(this).closest("div.widget");var i=c("textarea[id^=widget-black-studio-tinymce]",j);if(c('[name="'+c("#"+i.attr("id")).attr("name")+'"]').size()>1){var h=c("div.widget-inside",j);if(c("div.error",h).length==0){h.prepend('<div class="error"><strong>'+black_studio_tinymce_local.error_duplicate_id+"</strong></div>")}}c("input[name=savewidget]",j).on("click",function(k){var m=c(this).closest("div.widget");var l=c("textarea[id^=widget-black-studio-tinymce]",m);if(tinyMCE.get(l.attr("id"))!=null){b(l.attr("id"))}c(this).unbind("ajaxSuccess").ajaxSuccess(function(o,p,n){var q=c("textarea[id^=widget-black-studio-tinymce]",c(this).closest("div.widget-inside"));e(q.attr("id"))})});c("#wpbody-content").css("overflow","visible");j.css("position","relative").css("z-index","100000");a(i.attr("id"));c(".insert-media",j).data("editor",i.attr("id"))});c("div.widget[id*=black-studio-tinymce] input[name=savewidget]").on("click",function(g){var i=c(this).closest("div.widget");var h=c("textarea[id^=widget-black-studio-tinymce]",i);if(tinyMCE.get(h.attr("id"))!=null){b(h.attr("id"))}c(this).unbind("ajaxSuccess").ajaxSuccess(function(k,l,j){var m=c("textarea[id^=widget-black-studio-tinymce]",c(this).closest("div.widget-inside"));e(m.attr("id"))})});c(document).on("click","a[id^=widget-black-studio-tinymce][id$=tmce]",function(h){var i=c(this).closest("div.widget-inside,div.panel-dialog");var j=c("div[id^=wp-widget-black-studio-tinymce][id$=-wrap]",i);var g=c("textarea[id^=widget-black-studio-tinymce]",i).attr("id");tinymce.DOM.removeClass(j,"html-active");tinymce.DOM.addClass(j,"tmce-active");c("input[id^=widget-black-studio-tinymce][id$=type]",i).val("visual");d(g)});c(document).on("click","a[id^=widget-black-studio-tinymce][id$=html]",function(h){var i=c(this).closest("div.widget-inside,div.panel-dialog");var j=c("div[id^=wp-widget-black-studio-tinymce][id$=-wrap]",i);var g=c("textarea[id^=widget-black-studio-tinymce]",i).attr("id");c("input[id^=widget-black-studio-tinymce][id$=type]",i).val("visual");tinymce.DOM.removeClass(j,"tmce-active");tinymce.DOM.addClass(j,"html-active");c("input[id^=widget-black-studio-tinymce][id$=type]",i).val("html");b(g)});c(document).on("click",".wp-media-buttons a",function(){var g=c(this).closest("div.widget-inside");wpActiveEditor=c("textarea[id^=widget-black-studio-tinymce]",g).attr("id")});if(c("body.widgets_access").size()>0){var f=c("textarea[id^=widget-black-studio-tinymce]");a(f.attr("id"))}})})(jQuery);
 
black-studio-tinymce-widget.php CHANGED
@@ -1,302 +1,238 @@
1
- <?php
2
- /*
3
- Plugin Name: Black Studio TinyMCE Widget
4
- Plugin URI: http://wordpress.org/extend/plugins/black-studio-tinymce-widget/
5
- Description: Adds a WYSIWYG widget based on the standard TinyMCE WordPress visual editor.
6
- Version: 1.4.8
7
- Author: Black Studio
8
- Author URI: http://www.blackstudio.it
9
- License: GPLv3
10
- Text Domain: black-studio-tinymce-widget
11
- Domain Path: /languages
12
- */
13
-
14
- /* Widget class */
15
- class WP_Widget_Black_Studio_TinyMCE extends WP_Widget {
16
-
17
- function __construct() {
18
- $widget_ops = array( 'classname' => 'widget_black_studio_tinymce', 'description' => __( 'Arbitrary text or HTML with visual editor', 'black-studio-tinymce-widget' ) );
19
- $control_ops = array( 'width' => 800, 'height' => 800 );
20
- parent::__construct( 'black-studio-tinymce', __( 'Visual Editor', 'black-studio-tinymce-widget' ), $widget_ops, $control_ops );
21
- }
22
-
23
- function widget( $args, $instance ) {
24
- if ( get_option( 'embed_autourls' ) ) {
25
- $wp_embed = $GLOBALS['wp_embed'];
26
- add_filter( 'widget_text', array( $wp_embed, 'run_shortcode' ), 8 );
27
- add_filter( 'widget_text', array( $wp_embed, 'autoembed' ), 8 );
28
- }
29
- extract( $args );
30
- $before_text = apply_filters( 'black_studio_tinymce_before_text', '<div class="textwidget">', $instance );
31
- $after_text = apply_filters( 'black_studio_tinymce_after_text', '</div>', $instance );
32
- $title = apply_filters( 'widget_title', empty($instance['title']) ? '' : $instance['title'], $instance, $this->id_base );
33
- $text = apply_filters( 'widget_text', $instance['text'], $instance );
34
- if ( function_exists( 'icl_t' ) && ! empty( $this->number ) ) {
35
- $title = icl_t( "Widgets", 'widget title - ' . md5 ( $title ), $title );
36
- $text = icl_t( "Widgets", 'widget body - ' . $this->id_base . '-' . $this->number, $text );
37
- }
38
- $text = do_shortcode( $text );
39
- echo $before_widget;
40
- if ( ! empty( $title ) ) {
41
- echo $before_title . $title . $after_title;
42
- }
43
- echo $before_text . $text . $after_text;
44
- echo $after_widget;
45
- }
46
-
47
- function update( $new_instance, $old_instance ) {
48
- $instance = $old_instance;
49
- $instance['title'] = strip_tags( $new_instance['title'] );
50
- if ( current_user_can( 'unfiltered_html' ) ) {
51
- $instance['text'] = $new_instance['text'];
52
- }
53
- else {
54
- $instance['text'] = stripslashes( wp_filter_post_kses( addslashes( $new_instance['text'] ) ) ); // wp_filter_post_kses() expects slashed
55
- }
56
- $instance['type'] = strip_tags( $new_instance['type'] );
57
- if ( function_exists( 'icl_register_string' ) && ! empty( $this->number ) ) {
58
- //icl_register_string( "Widgets", 'widget title - ' . $this->id_base . '-' . $this->number /* md5 ( apply_filters( 'widget_title', $instance['title'] ))*/, apply_filters( 'widget_title', $instance['title'] ) ); // This is handled automatically by WPML
59
- icl_register_string( "Widgets", 'widget body - ' . $this->id_base . '-' . $this->number, apply_filters( 'widget_text', $instance['text'] ) );
60
- }
61
- return $instance;
62
- }
63
-
64
- function form( $instance ) {
65
- $instance = wp_parse_args( (array) $instance, array( 'title' => '', 'text' => '', 'type' => 'visual' ) );
66
- $title = strip_tags( $instance['title'] );
67
- if ( function_exists( 'esc_textarea' ) ) {
68
- $text = esc_textarea( $instance['text'] );
69
- }
70
- else {
71
- $text = stripslashes( wp_filter_post_kses( addslashes( $instance['text'] ) ) );
72
- }
73
- $type = esc_attr( $instance['type'] );
74
- $switch_class = $type == 'visual' ? 'html-active' : 'tmce-active';
75
- if ( version_compare( get_bloginfo( 'version' ), '3.5', '<' ) ) {
76
- $toggle_buttons_class = "editor_toggle_buttons_legacy";
77
- $media_buttons_class = "editor_media_buttons_legacy";
78
- }
79
- else if ( version_compare( get_bloginfo( 'version' ), '3.8', '<' ) ) {
80
- $toggle_buttons_class = "wp-toggle-buttons";
81
- $media_buttons_class = "wp-media-buttons";
82
- }
83
- else {
84
- $toggle_buttons_class = "wp-editor-tabs";
85
- $media_buttons_class = "wp-media-buttons";
86
- }
87
-
88
- ?>
89
- <input id="<?php echo $this->get_field_id( 'type' ); ?>" name="<?php echo $this->get_field_name( 'type' ); ?>" type="hidden" value="<?php echo esc_attr( $type ); ?>" />
90
- <p><label for="<?php echo $this->get_field_id( 'title' ); ?>"><?php _e( 'Title:' ); ?></label>
91
- <input class="widefat" id="<?php echo $this->get_field_id( 'title' ); ?>" name="<?php echo $this->get_field_name( 'title' ); ?>" type="text" value="<?php echo esc_attr($title); ?>" /></p>
92
- <div id="wp-<?php echo $this->get_field_id( 'text' ); ?>-wrap" class="wp-core-ui wp-editor-wrap <?php echo $switch_class; ?>">
93
- <div class="wp-editor-tools hide-if-no-js">
94
- <div class="<?php echo $toggle_buttons_class; ?>">
95
- <a id="<?php echo $this->get_field_id( 'text' ); ?>-html" class="wp-switch-editor switch-html"><?php _e( 'HTML' ); ?></a>
96
- <a id="<?php echo $this->get_field_id( 'text' ); ?>-tmce" class="wp-switch-editor switch-tmce"><?php _e(' Visual' ); ?></a>
97
- </div>
98
- <div class="<?php echo $media_buttons_class; ?>">
99
- <?php do_action( 'media_buttons', $this->get_field_id( 'text' ) ); ?>
100
- </div>
101
- </div>
102
- <div class="wp-editor-container">
103
- <textarea class="widefat" rows="20" cols="40" id="<?php echo $this->get_field_id( 'text' ); ?>" name="<?php echo $this->get_field_name('text'); ?>"><?php echo $text; ?></textarea>
104
- </div>
105
- </div>
106
- <div class="wp-editor-bstw-links" style="font-size: 10px; text-align: right; padding: 5px 0;"><a href="http://www.blackstudio.it/en/wordpress-plugins/black-studio-tinymce-widget/" target="_blank"><?php echo __( 'Donate', 'black-studio-tinymce-widget' ); ?></a> | <a href="http://wordpress.org/support/plugin/black-studio-tinymce-widget" target="_blank"><?php echo __( 'Support', 'black-studio-tinymce-widget' ); ?></a> | <a href="http://wordpress.org/support/view/plugin-reviews/black-studio-tinymce-widget" target="_blank"><?php echo __( 'Rate', 'black-studio-tinymce-widget' ); ?></a> | <a href="https://twitter.com/blackstudioita" target="_blank"><?php echo __( 'Follow', 'black-studio-tinymce-widget' ); ?></a></div>
107
- <?php
108
- }
109
- }
110
-
111
- /* Get plugin version */
112
- function black_studio_tinymce_get_version() {
113
- if ( ! function_exists( 'get_plugins' ) )
114
- require_once( ABSPATH . 'wp-admin/includes/plugin.php' );
115
- $plugin_folder = get_plugins( '/' . plugin_basename( dirname( __FILE__ ) ) );
116
- $plugin_file = basename( ( __FILE__ ) );
117
- return $plugin_folder[$plugin_file]['Version'];
118
- }
119
-
120
- /* Load localization */
121
- load_plugin_textdomain( 'black-studio-tinymce-widget', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );
122
-
123
- /* Widget initialization */
124
- add_action( 'widgets_init', 'black_studio_tinymce_widgets_init' );
125
- function black_studio_tinymce_widgets_init() {
126
- if ( ! is_blog_installed() )
127
- return;
128
- register_widget( 'WP_Widget_Black_Studio_TinyMCE' );
129
- }
130
-
131
- /* Add actions and filters (only in widgets admin page) */
132
- add_action( 'admin_init', 'black_studio_tinymce_admin_init' );
133
- function black_studio_tinymce_admin_init() {
134
- global $pagenow;
135
- $load_editor = false;
136
- if ( $pagenow == "widgets.php" || $pagenow == "customize.php" ) {
137
- $load_editor = true;
138
- }
139
- // Compatibility for WP Page Widget plugin
140
- if ( is_plugin_active('wp-page-widget/wp-page-widgets.php' ) && (
141
- ( in_array( $pagenow, array( 'post-new.php', 'post.php') ) ) ||
142
- ( in_array( $pagenow, array( 'edit-tags.php' ) ) && isset( $_GET['action'] ) && $_GET['action'] == 'edit' ) ||
143
- ( in_array( $pagenow, array( 'admin.php' ) ) && isset( $_GET['page'] ) && in_array( $_GET['page'], array( 'pw-front-page', 'pw-search-page' ) ) )
144
- ) ) {
145
- $load_editor = true;
146
- }
147
- if ( $load_editor ) {
148
- add_action( 'admin_head', 'black_studio_tinymce_load_tiny_mce' );
149
- add_filter( 'tiny_mce_before_init', 'black_studio_tinymce_init_editor', 20 );
150
- add_action( 'admin_print_scripts', 'black_studio_tinymce_scripts' );
151
- add_action( 'admin_print_styles', 'black_studio_tinymce_styles' );
152
- add_action( 'admin_print_footer_scripts', 'black_studio_tinymce_footer_scripts' );
153
- add_filter( 'atd_load_scripts', '__return_true'); // Compatibility with Jetpack After the deadline
154
- }
155
- }
156
-
157
- /* Instantiate tinyMCE editor */
158
- function black_studio_tinymce_load_tiny_mce() {
159
- // Add support for thickbox media dialog
160
- add_thickbox();
161
- // New media modal dialog (WP 3.5+)
162
- if ( function_exists( 'wp_enqueue_media' ) ) {
163
- wp_enqueue_media();
164
- }
165
- }
166
-
167
- /* TinyMCE setup customization */
168
- function black_studio_tinymce_init_editor( $initArray ) {
169
- global $pagenow;
170
- // Remove WP fullscreen mode and set the native tinyMCE fullscreen mode
171
- if ( version_compare( get_bloginfo( 'version' ), '3.3', '<' ) ) {
172
- $plugins = explode(',', $initArray['plugins']);
173
- if ( isset( $plugins['wpfullscreen'] ) ) {
174
- unset( $plugins['wpfullscreen'] );
175
- }
176
- if ( ! isset( $plugins['fullscreen'] ) ) {
177
- $plugins[] = 'fullscreen';
178
- }
179
- $initArray['plugins'] = implode( ',', $plugins );
180
- }
181
- // Remove the "More" toolbar button (only in widget screen)
182
- if ( $pagenow == "widgets.php" && version_compare( get_bloginfo( 'version' ), '3.8', '<' )) {
183
- $initArray['theme_advanced_buttons1'] = str_replace( ',wp_more', '', $initArray['theme_advanced_buttons1'] );
184
- }
185
- // Do not remove linebreaks
186
- $initArray['remove_linebreaks'] = false;
187
- // Convert newline characters to BR tags
188
- $initArray['convert_newlines_to_brs'] = false;
189
- // Force P newlines
190
- $initArray['force_p_newlines'] = true;
191
- // Force no newlines for BR
192
- $initArray['force_br_newlines'] = false;
193
- // Do not remove redundant BR tags
194
- $initArray['remove_redundant_brs'] = false;
195
- // Force p block
196
- $initArray['forced_root_block'] = 'p';
197
- // Apply source formatting
198
- $initArray['apply_source_formatting'] = true;
199
- // Return modified settings
200
- return $initArray;
201
- }
202
-
203
- /* Widget js loading */
204
- function black_studio_tinymce_scripts() {
205
- wp_enqueue_script('media-upload');
206
- $version = black_studio_tinymce_get_version();
207
- $suffix = defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ? '' : '.min';
208
- if ( version_compare( get_bloginfo( 'version' ), '3.3', '>=' ) ) {
209
- $local_data = array( 'error_duplicate_id' => __('ERROR: Duplicate widget ID detected. To avoid content loss, please create a new one with the same content and then delete this widget.', 'black-studio-tinymce-widget') );
210
- wp_enqueue_script( 'wplink' );
211
- wp_enqueue_script( 'wpdialogs-popup' );
212
- wp_enqueue_script( 'black-studio-tinymce-widget', plugins_url('black-studio-tinymce-widget' . $suffix . '.js', __FILE__ ), array( 'jquery', 'editor' ), $version, true );
213
- wp_localize_script( 'black-studio-tinymce-widget', 'black_studio_tinymce_local', $local_data );
214
- do_action( 'wp_enqueue_editor', array( 'tinymce' => true ) ); // Advanced Image Styles compatibility
215
- }
216
- else {
217
- wp_enqueue_script( 'black-studio-tinymce-widget-legacy', plugins_url('black-studio-tinymce-widget-legacy' . $suffix . '.js', __FILE__ ), array( 'jquery', 'editor' ), $version, true );
218
- }
219
- }
220
-
221
- /* Widget css loading */
222
- function black_studio_tinymce_styles() {
223
- if ( version_compare( get_bloginfo( 'version' ), '3.3', '<' ) ) {
224
- wp_enqueue_style( 'thickbox' );
225
- }
226
- else {
227
- wp_enqueue_style( 'wp-jquery-ui-dialog' );
228
- }
229
- $style = 'black-studio-tinymce-widget';
230
- $version = black_studio_tinymce_get_version();
231
- wp_enqueue_style( 'editor-buttons' );
232
- if ( version_compare( get_bloginfo( 'version' ), '3.8', '<' ) ) {
233
- $style .= '-legacy';
234
- }
235
- wp_enqueue_style( $style, plugins_url( $style. '.css', __FILE__ ), array(), $version );
236
- }
237
-
238
-
239
- /* Footer script */
240
- function black_studio_tinymce_footer_scripts() {
241
- // Setup for WP 3.1 and previous versions
242
- if ( version_compare( get_bloginfo( 'version' ), '3.2', '<' ) ) {
243
- if ( function_exists( 'wp_tiny_mce' ) ) {
244
- wp_tiny_mce( false, array() );
245
- }
246
- if ( function_exists( 'wp_tiny_mce_preload_dialogs' ) ) {
247
- wp_tiny_mce_preload_dialogs();
248
- }
249
- }
250
- // Setup for WP 3.2
251
- else if ( version_compare( get_bloginfo( 'version' ), '3.3', '<' ) ) {
252
- if ( function_exists( 'wp_tiny_mce' ) ) {
253
- wp_tiny_mce( false, array() );
254
- }
255
- if ( function_exists( 'wp_preload_dialogs') ) {
256
- wp_preload_dialogs( array( 'plugins' => 'wpdialogs,wplink,wpfullscreen' ) );
257
- }
258
- }
259
- // Setup for WP 3.3+ - New Editor API
260
- else {
261
- wp_editor( '', 'black-studio-tinymce-widget' );
262
- }
263
- }
264
-
265
- /* Support for Smilies */
266
- add_filter( 'widget_text', 'black_studio_tinymce_apply_smilies_to_widget_text' );
267
- function black_studio_tinymce_apply_smilies_to_widget_text( $text ) {
268
- if ( get_option( 'use_smilies' ) ) {
269
- $text = convert_smilies( $text );
270
- }
271
- return $text;
272
- }
273
-
274
- /* Hack needed to enable full media options when adding content from media library */
275
- /* (this is done excluding post_id parameter in Thickbox iframe url) */
276
- add_filter( '_upload_iframe_src', 'black_studio_tinymce_upload_iframe_src' );
277
- function black_studio_tinymce_upload_iframe_src ( $upload_iframe_src ) {
278
- global $pagenow;
279
- if ( $pagenow == "widgets.php" || ( $pagenow == "admin-ajax.php" && isset ( $_POST['id_base'] ) && $_POST['id_base'] == "black-studio-tinymce" ) ) {
280
- $upload_iframe_src = str_replace( 'post_id=0', '', $upload_iframe_src );
281
- }
282
- return $upload_iframe_src;
283
- }
284
-
285
- /* Hack for widgets accessibility mode */
286
- add_filter( 'wp_default_editor', 'black_studio_tinymce_editor_accessibility_mode' );
287
- function black_studio_tinymce_editor_accessibility_mode($editor) {
288
- global $pagenow;
289
- if ( $pagenow == "widgets.php" && isset( $_GET['editwidget'] ) && strpos( $_GET['editwidget'], 'black-studio-tinymce' ) === 0 ) {
290
- $editor = 'html';
291
- }
292
- return $editor;
293
- }
294
-
295
- /* Hack for compatibility with Page Builder + WPML String Translation */
296
- add_filter( 'siteorigin_panels_widget_object', 'black_studio_tinymce_siteorigin_panels_widget_object', 10, 2 );
297
- function black_studio_tinymce_siteorigin_panels_widget_object( $the_widget, $widget ) {
298
- if ( isset($the_widget->id_base) && $the_widget->id_base == 'black-studio-tinymce' ) {
299
- $the_widget->number = '';
300
- }
301
- return $the_widget;
302
- }
1
+ <?php
2
+ /*
3
+ Plugin Name: Black Studio TinyMCE Widget
4
+ Plugin URI: https://wordpress.org/plugins/black-studio-tinymce-widget/
5
+ Description: Adds a new "Visual Editor" widget type based on the native WordPress TinyMCE editor.
6
+ Version: 2.0.0
7
+ Author: Black Studio
8
+ Author URI: http://www.blackstudio.it
9
+ Requires at least: 3.1
10
+ Tested up to: 4.0
11
+ License: GPLv3
12
+ Text Domain: black-studio-tinymce-widget
13
+ Domain Path: /languages
14
+ */
15
+
16
+ // Exit if accessed directly
17
+ if ( ! defined( 'ABSPATH' ) ) {
18
+ exit;
19
+ }
20
+
21
+ /**
22
+ * Main plugin class
23
+ *
24
+ * @package Black_Studio_TinyMCE_Widget
25
+ * @since 2.0.0
26
+ */
27
+
28
+ if ( ! class_exists( 'Black_Studio_TinyMCE_Plugin' ) ) {
29
+
30
+ final class Black_Studio_TinyMCE_Plugin {
31
+
32
+ /**
33
+ * Plugin version
34
+ *
35
+ * @var string
36
+ * @since 2.0.0
37
+ */
38
+ public static $version = '2.0.0';
39
+
40
+ /**
41
+ * The single instance of the plugin class
42
+ *
43
+ * @var object
44
+ * @since 2.0.0
45
+ */
46
+ protected static $_instance = null;
47
+
48
+ /**
49
+ * Instance of admin class
50
+ *
51
+ * @var object
52
+ * @since 2.0.0
53
+ */
54
+ protected static $admin = null;
55
+
56
+ /**
57
+ * Instance of compatibility class
58
+ *
59
+ * @var object
60
+ * @since 2.0.0
61
+ */
62
+ protected static $compatibility = null;
63
+
64
+ /**
65
+ * Instance of the text filters class
66
+ *
67
+ * @var object
68
+ * @since 2.0.0
69
+ */
70
+ protected static $text_filters = null;
71
+
72
+ /**
73
+ * Return the main plugin instance
74
+ *
75
+ * @return object
76
+ * @since 2.0.0
77
+ */
78
+ public static function instance() {
79
+ if ( is_null( self::$_instance ) ) {
80
+ self::$_instance = new self();
81
+ }
82
+ return self::$_instance;
83
+ }
84
+
85
+ /**
86
+ * Return the instance of the admin class
87
+ *
88
+ * @return object
89
+ * @since 2.0.0
90
+ */
91
+ public static function admin() {
92
+ return self::$admin;
93
+ }
94
+
95
+ /**
96
+ * Return the instance of the compatibility class
97
+ *
98
+ * @return object
99
+ * @since 2.0.0
100
+ */
101
+ public static function compatibility() {
102
+ return self::$compatibility;
103
+ }
104
+
105
+ /**
106
+ * Return the instance of the text filters class
107
+ *
108
+ * @return object
109
+ * @since 2.0.0
110
+ */
111
+ public static function text_filters() {
112
+ return self::$text_filters;
113
+ }
114
+
115
+ /**
116
+ * Get plugin version
117
+ *
118
+ * @return string
119
+ * @since 2.0.0
120
+ */
121
+ public static function get_version() {
122
+ return self::$version;
123
+ }
124
+
125
+ /**
126
+ * Get plugin basename
127
+ *
128
+ * @uses plugin_basename()
129
+ *
130
+ * @return string
131
+ * @since 2.0.0
132
+ */
133
+ public static function get_basename() {
134
+ return plugin_basename( __FILE__ );
135
+ }
136
+
137
+ /**
138
+ * Class constructor
139
+ *
140
+ * @uses add_action()
141
+ * @uses add_filter()
142
+ * @uses get_option()
143
+ * @uses get_bloginfo()
144
+ *
145
+ * @global object $wp_embed
146
+ * @return void
147
+ * @since 2.0.0
148
+ */
149
+ protected function __construct() {
150
+ // Include required files
151
+ include_once( plugin_dir_path( __FILE__ ) . '/includes/class-widget.php' );
152
+ // Include and instantiate admin class on admin pages
153
+ if ( is_admin() ) {
154
+ include_once( plugin_dir_path( __FILE__ ) . '/includes/class-admin.php' );
155
+ self::$admin = Black_Studio_TinyMCE_Admin::instance();
156
+ }
157
+ // Include and instantiate text filter class on frontend pages
158
+ else {
159
+ include_once( plugin_dir_path( __FILE__ ) . '/includes/class-text-filters.php' );
160
+ self::$text_filters = Black_Studio_TinyMCE_Text_Filters::instance();
161
+ }
162
+ // Register action and filter hooks
163
+ add_action( 'plugins_loaded', array( $this, 'load_compatibility' ), 20 );
164
+ add_action( 'widgets_init', array( $this, 'widgets_init' ) );
165
+ }
166
+
167
+ /**
168
+ * Prevent the class from being cloned
169
+ *
170
+ * @return void
171
+ * @since 2.0.0
172
+ */
173
+ protected function __clone() {
174
+ _doing_it_wrong( __FUNCTION__, __( 'Cheatin&#8217; uh?' ), '2.0' );
175
+ }
176
+
177
+ /**
178
+ * Load compatibility class
179
+ *
180
+ * @uses apply_filters()
181
+ * @uses get_bloginfo()
182
+ * @uses plugin_dir_path()
183
+ *
184
+ * @return void
185
+ * @since 2.0.0
186
+ */
187
+ public function load_compatibility() {
188
+ // Compatibility load flag (for both deprecated functions and code for compatibility with other plugins)
189
+ $load_compatibility = apply_filters( 'black_studio_tinymce_load_compatibility', true );
190
+ if ( $load_compatibility ) {
191
+ include_once( plugin_dir_path( __FILE__ ) . '/includes/class-compatibility.php' );
192
+ self::$compatibility = Black_Studio_TinyMCE_Compatibility::instance();
193
+ }
194
+ }
195
+
196
+ /**
197
+ * Widget initialization
198
+ *
199
+ * @uses is_blog_installed()
200
+ * @uses register_widget()
201
+ *
202
+ * @return null|void
203
+ * @since 2.0.0
204
+ */
205
+ public function widgets_init() {
206
+ if ( ! is_blog_installed() ) {
207
+ return;
208
+ }
209
+ register_widget( 'WP_Widget_Black_Studio_TinyMCE' );
210
+ }
211
+
212
+ /**
213
+ * Check if a widget is a Black Studio Tinyme Widget instance
214
+ *
215
+ * @param object $widget
216
+ * @return boolean
217
+ * @since 2.0.0
218
+ */
219
+ public function check_widget( $widget ) {
220
+ return gettype( $widget ) == 'object' && get_class( $widget ) == 'WP_Widget_Black_Studio_TinyMCE';
221
+ }
222
+
223
+ } // END class Black_Studio_TinyMCE_Plugin
224
+
225
+ } // class_exists check
226
+
227
+ /**
228
+ * Return the main instance to prevent the need to use globals
229
+ *
230
+ * @return object
231
+ * @since 2.0.0
232
+ */
233
+ function bstw() {
234
+ return Black_Studio_TinyMCE_Plugin::instance();
235
+ }
236
+
237
+ /* Create the main instance */
238
+ bstw();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
css/black-studio-tinymce-widget-pre33.css ADDED
@@ -0,0 +1,99 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* Black Studio TinyMCE Widget - CSS */
2
+
3
+ .bstw-links {
4
+ font-size: 11px;
5
+ margin-top: -3px;
6
+ text-align: right;
7
+ position: absolute;
8
+ right: 18px;
9
+ }
10
+
11
+ .bstw-links .icon-plugins {
12
+ float: right;
13
+ padding: 3px 6px;
14
+ margin: -8px -8px 0 -2px;
15
+ background: transparent url('../../../../wp-admin/images/menu.png') no-repeat scroll -180px -33px;
16
+ width: 16px;
17
+ height: 16px;
18
+ }
19
+
20
+ .bstw-links .bstw-links-list {
21
+ display: none;
22
+ }
23
+
24
+ .bstw-links a {
25
+ text-decoration: none;
26
+ }
27
+
28
+ #mce_fullscreen_container {
29
+ background-color: white;
30
+ }
31
+
32
+ #wp-black-studio-tinymce-widget-wrap {
33
+ display: none;
34
+ }
35
+
36
+ #TB_overlay, #TB_window {
37
+ z-index: 999999;
38
+ }
39
+
40
+ .wp-editor-container {
41
+ border-style: solid;
42
+ border-width: 1px;
43
+ border-collapse: separate;
44
+ -moz-border-radius: 3px 3px 0 0;
45
+ -webkit-border-top-right-radius: 3px;
46
+ -webkit-border-top-left-radius: 3px;
47
+ -khtml-border-top-right-radius: 3px;
48
+ -khtml-border-top-left-radius: 3px;
49
+ border-top-right-radius: 3px;
50
+ border-top-left-radius: 3px;
51
+ border-color: #ccc #ccc #dfdfdf;
52
+ clear: both;
53
+ }
54
+
55
+ .wp-switch-editor {
56
+ height: 18px;
57
+ margin: 5px 5px 0 0;
58
+ padding: 4px 5px 2px;
59
+ float: right;
60
+ cursor: pointer;
61
+ border-width: 1px;
62
+ border-style: solid;
63
+ -moz-border-radius: 3px 3px 0 0;
64
+ -webkit-border-top-right-radius: 3px;
65
+ -webkit-border-top-left-radius: 3px;
66
+ -khtml-border-top-right-radius: 3px;
67
+ -khtml-border-top-left-radius: 3px;
68
+ border-top-right-radius: 3px;
69
+ border-top-left-radius: 3px;
70
+ background-color: #f1f1f1;
71
+ border-color: #dfdfdf #dfdfdf #ccc;
72
+ color: #999;
73
+ position: relative;
74
+ top: 1px;
75
+ }
76
+
77
+ .tmce-active .switch-tmce, .html-active .switch-html {
78
+ border-color: #ccc #ccc #e9e9e9;
79
+ background-color: #e9e9e9;
80
+ color: #333;
81
+ }
82
+
83
+ .wp-media-buttons {
84
+ cursor: default;
85
+ padding: 8px 8px 0;
86
+ }
87
+
88
+ .wp-media-buttons a {
89
+ cursor: pointer;
90
+ padding: 0 0 5px 10px;
91
+ }
92
+
93
+ .wp-media-buttons img {
94
+ vertical-align: middle;
95
+ }
96
+
97
+ .wp_themeSkin .mceStatusbar {
98
+ border-color: #dfdfdf;
99
+ }
css/black-studio-tinymce-widget-pre33.min.css ADDED
@@ -0,0 +1,2 @@
 
 
1
+ /* Black Studio TinyMCE Widget - v2.0.0 */
2
+ .bstw-links{font-size:11px;margin-top:-3px;text-align:right;position:absolute;right:18px}.bstw-links .icon-plugins{float:right;padding:3px 6px;margin:-8px -8px 0 -2px;background:url(../../../../wp-admin/images/menu.png) -180px -33px no-repeat;width:16px;height:16px}.bstw-links .bstw-links-list{display:none}.bstw-links a{text-decoration:none}#mce_fullscreen_container{background-color:#fff}#wp-black-studio-tinymce-widget-wrap{display:none}#TB_overlay,#TB_window{z-index:999999}.wp-editor-container{border-style:solid;border-width:1px;border-collapse:separate;-moz-border-radius:3px 3px 0 0;-webkit-border-top-right-radius:3px;-webkit-border-top-left-radius:3px;-khtml-border-top-right-radius:3px;-khtml-border-top-left-radius:3px;border-top-right-radius:3px;border-top-left-radius:3px;border-color:#ccc #ccc #dfdfdf;clear:both}.wp-switch-editor{height:18px;margin:5px 5px 0 0;padding:4px 5px 2px;float:right;cursor:pointer;border-width:1px;border-style:solid;-moz-border-radius:3px 3px 0 0;-webkit-border-top-right-radius:3px;-webkit-border-top-left-radius:3px;-khtml-border-top-right-radius:3px;-khtml-border-top-left-radius:3px;border-top-right-radius:3px;border-top-left-radius:3px;background-color:#f1f1f1;border-color:#dfdfdf #dfdfdf #ccc;color:#999;position:relative;top:1px}.html-active .switch-html,.tmce-active .switch-tmce{border-color:#ccc #ccc #e9e9e9;background-color:#e9e9e9;color:#333}.wp-media-buttons{cursor:default;padding:8px 8px 0}.wp-media-buttons a{cursor:pointer;padding:0 0 5px 10px}.wp-media-buttons img{vertical-align:middle}.wp_themeSkin .mceStatusbar{border-color:#dfdfdf}
css/black-studio-tinymce-widget.css ADDED
@@ -0,0 +1,55 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* Black Studio TinyMCE Widget - CSS */
2
+
3
+ .bstw-links {
4
+ font-size: 11px;
5
+ margin-top: -3px;
6
+ text-align: right;
7
+ position: absolute;
8
+ right: 18px;
9
+ }
10
+
11
+ .bstw-links .icon16:before {
12
+ padding: 0;
13
+ }
14
+
15
+ .bstw-links .icon16 {
16
+ float: right;
17
+ padding: 3px 6px;
18
+ margin: -6px -8px 0 -2px;
19
+ }
20
+
21
+ .bstw-links .bstw-links-list {
22
+ display: none;
23
+ }
24
+
25
+ .bstw-links a {
26
+ text-decoration: none;
27
+ }
28
+
29
+ #wp-black-studio-tinymce-widget-wrap {
30
+ display: none;
31
+ }
32
+
33
+ div[id*="black-studio-tinymce"] .wp-editor-wrap {
34
+ margin-bottom: 1em;
35
+ }
36
+
37
+ #available-widgets [class*="black-studio-tinymce"] .widget-title:before {
38
+ content: "\f116";
39
+ }
40
+
41
+ .wp-customizer .mce-floatpanel.mce-popover {
42
+ z-index: 500000 !important;
43
+ }
44
+
45
+ #TB_overlay, #TB_window {
46
+ z-index: 999999 !important;
47
+ }
48
+
49
+ body.wait, body.wait * {
50
+ cursor: wait !important;
51
+ }
52
+
53
+ #zedity_content_overlay {
54
+ z-index: 100000 !important;
55
+ }
css/black-studio-tinymce-widget.min.css ADDED
@@ -0,0 +1,2 @@
 
 
1
+ /* Black Studio TinyMCE Widget - v2.0.0 */
2
+ .bstw-links{font-size:11px;margin-top:-3px;text-align:right;position:absolute;right:18px}.bstw-links .icon16:before{padding:0}.bstw-links .icon16{float:right;padding:3px 6px;margin:-6px -8px 0 -2px}.bstw-links .bstw-links-list{display:none}.bstw-links a{text-decoration:none}#wp-black-studio-tinymce-widget-wrap{display:none}div[id*=black-studio-tinymce] .wp-editor-wrap{margin-bottom:1em}#available-widgets [class*=black-studio-tinymce] .widget-title:before{content:"\f116"}.wp-customizer .mce-floatpanel.mce-popover{z-index:500000!important}#TB_overlay,#TB_window{z-index:999999!important}body.wait,body.wait *{cursor:wait!important}#zedity_content_overlay{z-index:100000!important}
includes/class-admin.php ADDED
@@ -0,0 +1,371 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Exit if accessed directly
4
+ if ( ! defined( 'ABSPATH' ) ) {
5
+ exit;
6
+ }
7
+
8
+ /**
9
+ * Class that provides admin functionalities
10
+ *
11
+ * @package Black_Studio_TinyMCE_Widget
12
+ * @since 2.0.0
13
+ */
14
+
15
+ if ( ! class_exists( 'Black_Studio_TinyMCE_Admin' ) ) {
16
+
17
+ final class Black_Studio_TinyMCE_Admin {
18
+
19
+ /**
20
+ * The single instance of the class
21
+ *
22
+ * @var object
23
+ * @since 2.0.0
24
+ */
25
+ protected static $_instance = null;
26
+
27
+ /**
28
+ * Array containing the plugin links
29
+ *
30
+ * @var array
31
+ * @since 2.0.0
32
+ */
33
+ protected $links;
34
+
35
+ /**
36
+ * Return the single class instance
37
+ *
38
+ * @return object
39
+ * @since 2.0.0
40
+ */
41
+ public static function instance() {
42
+ if ( is_null( self::$_instance ) ) {
43
+ self::$_instance = new self();
44
+ }
45
+ return self::$_instance;
46
+ }
47
+
48
+ /**
49
+ * Class constructor
50
+ *
51
+ * @uses add_action()
52
+ * @uses add_filter()
53
+ * @uses get_option()
54
+ * @uses get_bloginfo()
55
+ *
56
+ * @global object $wp_embed
57
+ * @return void
58
+ * @since 2.0.0
59
+ */
60
+ protected function __construct() {
61
+ // Register action and filter hooks
62
+ add_action( 'plugins_loaded', array( $this, 'load_textdomain' ) );
63
+ add_action( 'admin_init', array( $this, 'admin_init' ), 20 );
64
+ add_filter( 'wp_default_editor', array( $this, 'editor_accessibility_mode' ) );
65
+ }
66
+
67
+ /**
68
+ * Prevent the class from being cloned
69
+ *
70
+ * @return void
71
+ * @since 2.0.0
72
+ */
73
+ protected function __clone() {
74
+ _doing_it_wrong( __FUNCTION__, __( 'Cheatin&#8217; uh?' ), '2.0' );
75
+ }
76
+
77
+ /**
78
+ * Load language files
79
+ *
80
+ * @uses load_plugin_textdomain()
81
+ *
82
+ * @return void
83
+ * @since 2.0.0
84
+ */
85
+ public function load_textdomain() {
86
+ load_plugin_textdomain( 'black-studio-tinymce-widget', false, dirname( dirname( plugin_basename( __FILE__ ) ) ) . '/languages/' );
87
+ }
88
+
89
+ /**
90
+ * Checks if the plugin admin code should be loaded
91
+ *
92
+ * @uses apply_filters()
93
+ *
94
+ * @global string $pagenow
95
+ * @return void
96
+ * @since 2.0.0
97
+ */
98
+ public function enabled() {
99
+ global $pagenow;
100
+ $enabled_pages = apply_filters( 'black_studio_tinymce_enable_pages', array( 'widgets.php', 'customize.php', 'admin-ajax.php' ) );
101
+ return apply_filters( 'black_studio_tinymce_enable', in_array( $pagenow, $enabled_pages ) );
102
+ }
103
+
104
+ /**
105
+ * Add actions and filters (only in widgets admin page)
106
+ *
107
+ * @uses add_action()
108
+ * @uses add_filter()
109
+ * @uses do_action()
110
+ *
111
+ * @return void
112
+ * @since 2.0.0
113
+ */
114
+ public function admin_init() {
115
+ $this->init_links();
116
+ add_action( 'plugin_row_meta', array( $this, 'plugin_row_meta' ), 10, 2 );
117
+ if ( $this->enabled() ) {
118
+ add_action( 'admin_head', array( $this, 'enqueue_media' ) );
119
+ add_action( 'admin_print_scripts', array( $this, 'admin_print_scripts' ) );
120
+ add_action( 'admin_print_styles', array( $this, 'admin_print_styles' ) );
121
+ add_action( 'admin_print_footer_scripts', array( $this, 'admin_print_footer_scripts' ) );
122
+ add_action( 'black_studio_tinymce_editor', array( $this, 'editor' ), 10, 3 );
123
+ add_action( 'black_studio_tinymce_before_editor', array( $this, 'display_links' ) ); // consider donating if you remove links
124
+ add_filter( 'wp_editor_settings', array( $this, 'editor_settings' ), 10, 2 );
125
+ do_action( 'black_studio_tinymce_load' );
126
+ }
127
+ }
128
+
129
+ /**
130
+ * Instantiate tinyMCE editor
131
+ *
132
+ * @uses add_thickbox()
133
+ * @uses wp_enqueue_media()
134
+ *
135
+ * @return void
136
+ * @since 2.0.0
137
+ */
138
+ public function enqueue_media() {
139
+ // Add support for thickbox media dialog
140
+ add_thickbox();
141
+ // New media modal dialog (WP 3.5+)
142
+ if ( function_exists( 'wp_enqueue_media' ) ) {
143
+ wp_enqueue_media();
144
+ }
145
+ }
146
+
147
+ /**
148
+ * Enqueue styles
149
+ *
150
+ * @uses wp_enqueue_style()
151
+ * @uses Black_Studio_TinyMCE_Plugin::enqueue_style()
152
+ *
153
+ * @return void
154
+ * @since 2.0.0
155
+ */
156
+ public function admin_print_styles() {
157
+ wp_enqueue_style( 'wp-jquery-ui-dialog' );
158
+ wp_enqueue_style( 'editor-buttons' );
159
+ $this->enqueue_style();
160
+ }
161
+
162
+ /**
163
+ * Helper function to enqueue style
164
+ *
165
+ * @uses apply_filters()
166
+ * @uses wp_enqueue_style()
167
+ * @uses plugins_url()
168
+ * @uses SCRIPT_DEBUG
169
+ *
170
+ * @return void
171
+ * @since 2.0.0
172
+ */
173
+ public function enqueue_style() {
174
+ $style = apply_filters( 'black-studio-tinymce-widget-style', 'black-studio-tinymce-widget' );
175
+ $suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
176
+ wp_enqueue_style(
177
+ $style,
178
+ plugins_url( 'css/' . $style . $suffix. '.css', dirname( __FILE__ ) ),
179
+ array(),
180
+ bstw()->get_version()
181
+ );
182
+ }
183
+
184
+ /**
185
+ * Enqueue header scripts
186
+ *
187
+ * @uses wp_enqueue_script()
188
+ * @uses Black_Studio_TinyMCE_Plugin::enqueue_script()
189
+ * @uses Black_Studio_TinyMCE_Plugin::localize_script()
190
+ * @uses do_action()
191
+ *
192
+ * @return void
193
+ * @since 2.0.0
194
+ */
195
+ public function admin_print_scripts() {
196
+ wp_enqueue_script( 'media-upload' );
197
+ wp_enqueue_script( 'wplink' );
198
+ wp_enqueue_script( 'wpdialogs-popup' );
199
+ $this->enqueue_script();
200
+ $this->localize_script();
201
+ do_action( 'wp_enqueue_editor', array( 'tinymce' => true ) );
202
+ }
203
+
204
+ /**
205
+ * Helper function to enqueue script
206
+ *
207
+ * @uses apply_filters()
208
+ * @uses wp_enqueue_script()
209
+ * @uses plugins_url()
210
+ * @uses SCRIPT_DEBUG
211
+ *
212
+ * @return void
213
+ * @since 2.0.0
214
+ */
215
+ public function enqueue_script() {
216
+ $script = apply_filters( 'black-studio-tinymce-widget-script', 'black-studio-tinymce-widget' );
217
+ $suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
218
+ wp_enqueue_script(
219
+ $script,
220
+ plugins_url( 'js/' . $script . $suffix . '.js', dirname( __FILE__ ) ),
221
+ array( 'jquery', 'editor', 'quicktags' ),
222
+ bstw()->get_version(),
223
+ true
224
+ );
225
+ }
226
+
227
+ /**
228
+ * Helper function to enqueue localized script
229
+ *
230
+ * @uses apply_filters()
231
+ * @uses wp_localize_script()
232
+ *
233
+ * @return void
234
+ * @since 2.0.0
235
+ */
236
+ public function localize_script() {
237
+ $container_selectors = apply_filters( 'black_studio_tinymce_container_selectors', array( 'div.widget', 'div.widget-inside' ) );
238
+ $activate_events = apply_filters( 'black_studio_tinymce_activate_events', array() );
239
+ $deactivate_events = apply_filters( 'black_studio_tinymce_deactivate_events', array() );
240
+ $data = array(
241
+ 'container_selectors' => implode( ', ', $container_selectors ),
242
+ 'activate_events' => $activate_events,
243
+ 'deactivate_events' => $deactivate_events,
244
+ /* translators: error message shown when a duplicated widget ID is detected */
245
+ 'error_duplicate_id' => __( 'ERROR: Duplicate widget ID detected. To avoid content loss, please create a new widget with the same content and then delete this one.', 'black-studio-tinymce-widget' )
246
+ );
247
+ wp_localize_script( apply_filters( 'black-studio-tinymce-widget-script', 'black-studio-tinymce-widget' ), 'bstw_data', $data );
248
+ }
249
+
250
+ /**
251
+ * Enqueue footer scripts
252
+ *
253
+ * @uses wp_editor()
254
+ *
255
+ * @return void
256
+ * @since 2.0.0
257
+ */
258
+ public function admin_print_footer_scripts() {
259
+ $this->editor( '', 'black-studio-tinymce-widget', 'black-studio-tinymce-widget' );
260
+ }
261
+
262
+ /**
263
+ * Output the visual editor
264
+ *
265
+ * @uses wp_editor()
266
+ *
267
+ * @param string $text
268
+ * @param string $editor_id
269
+ * @param string $name
270
+ * @return void
271
+ * @since 2.0.0
272
+ */
273
+ public function editor( $text, $editor_id, $name = '' ) {
274
+ wp_editor( $text, $editor_id, $this->editor_settings( array( 'textarea_name' => $name ), $editor_id ) );
275
+ }
276
+
277
+ /**
278
+ * Set editor settings
279
+ *
280
+ * @param mixed[] $settings
281
+ * @param string $editor_id
282
+ * @return mixed[]
283
+ * @since 2.0.0
284
+ */
285
+ public function editor_settings( $settings, $editor_id ) {
286
+ if ( strstr( $editor_id, 'black-studio-tinymce' ) ) {
287
+ $settings['default_editor'] = 'tmce';
288
+ $settings['tinymce'] = array( 'wp_skip_init' => true );
289
+ $settings['editor_height'] = 350;
290
+ }
291
+ return $settings;
292
+ }
293
+
294
+ /**
295
+ * Edit widgets in accessibility mode
296
+ *
297
+ * @global string $pagenow
298
+ * @param string $editor
299
+ * @return string
300
+ * @since 2.0.0
301
+ */
302
+ public function editor_accessibility_mode( $editor ) {
303
+ global $pagenow;
304
+ if ( $pagenow == 'widgets.php' && isset( $_GET['editwidget'] ) && strpos( $_GET['editwidget'], 'black-studio-tinymce' ) === 0 ) {
305
+ $editor = 'html';
306
+ }
307
+ return $editor;
308
+ }
309
+
310
+ /**
311
+ * Initialize plugin links
312
+ *
313
+ * @return void
314
+ * @since 2.0.0
315
+ */
316
+ public function init_links() {
317
+ $this->links = array(
318
+ /* translators: text used for plugin home link */
319
+ 'https://wordpress.org/plugins/black-studio-tinymce-widget/' => __( 'Home', 'black-studio-tinymce-widget' ),
320
+ /* translators: text used for support faq link */
321
+ 'https://wordpress.org/plugins/black-studio-tinymce-widget/faq/' => __( 'FAQ', 'black-studio-tinymce-widget' ),
322
+ /* translators: text used for support forum link */
323
+ 'https://wordpress.org/support/plugin/black-studio-tinymce-widget' => __( 'Support', 'black-studio-tinymce-widget' ),
324
+ /* translators: text used for reviews link */
325
+ 'https://wordpress.org/support/view/plugin-reviews/black-studio-tinymce-widget' => __( 'Rate', 'black-studio-tinymce-widget' ),
326
+ /* translators: text used for follow on twitter link */
327
+ 'https://twitter.com/blackstudioita' => __( 'Follow', 'black-studio-tinymce-widget' ),
328
+ /* translators: text used for donation link */
329
+ 'http://www.blackstudio.it/en/wordpress-plugins/black-studio-tinymce-widget/' => __( 'Donate', 'black-studio-tinymce-widget' ),
330
+ );
331
+ }
332
+
333
+ /**
334
+ * Display plugin links
335
+ *
336
+ * @return void
337
+ * @since 2.0.0
338
+ */
339
+ public function display_links() {
340
+ echo "\t<div class='bstw-links'>\n";
341
+ echo "\t\t<span class='bstw-links-list'>\n";
342
+ $counter = count( $this->links ) - 1;
343
+ foreach ( $this->links as $url => $label ) {
344
+ $separator = ( $counter-- > 0 ? ' | ' : '' );
345
+ echo "\t\t\t<a href='" . esc_url( $url ) . "' target='_blank'>" . esc_html( $label ) . "</a>$separator\n"; // xss ok
346
+ }
347
+ echo "\t\t</span>\n";
348
+ /* translators: text used for the icon that shows the plugin links */
349
+ echo "\t\t<a class='bstw-links-icon icon16 icon-plugins' href='#' title='" . esc_attr( __( 'About Black Studio TinyMCE Widget plugin', 'black-studio-tinymce-widget' ) ) . "'></a>\n";
350
+ echo "\t</div>\n";
351
+ }
352
+
353
+ /**
354
+ * Show row meta on the plugin screen
355
+ *
356
+ * @param string[] $links
357
+ * @param string $file
358
+ * @return string[]
359
+ */
360
+ public function plugin_row_meta( $links, $file ) {
361
+ if ( $file == bstw()->get_basename() ) {
362
+ foreach ( $this->links as $url => $label ) {
363
+ $links[ $label ] = '<a href="' . esc_url( $url ) . '" target="_blank">' . esc_html( $label ) . '</a>';
364
+ }
365
+ }
366
+ return $links;
367
+ }
368
+
369
+ } // END class Black_Studio_TinyMCE_Admin
370
+
371
+ } // class_exists check
includes/class-compatibility-plugins.php ADDED
@@ -0,0 +1,360 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Exit if accessed directly
4
+ if ( ! defined( 'ABSPATH' ) ) {
5
+ exit;
6
+ }
7
+
8
+ /**
9
+ * Class that provides compatibility code with other plugins
10
+ *
11
+ * @package Black_Studio_TinyMCE_Widget
12
+ * @since 2.0.0
13
+ */
14
+
15
+ if ( ! class_exists( 'Black_Studio_TinyMCE_Compatibility_Plugins' ) ) {
16
+
17
+ final class Black_Studio_TinyMCE_Compatibility_Plugins {
18
+
19
+ /**
20
+ * The single instance of the class
21
+ *
22
+ * @var object
23
+ * @since 2.0.0
24
+ */
25
+ protected static $_instance = null;
26
+
27
+ /**
28
+ * Return the single class instance
29
+ *
30
+ * @param string[] $plugins
31
+ * @return object
32
+ * @since 2.0.0
33
+ */
34
+ public static function instance( $plugins = array() ) {
35
+ if ( is_null( self::$_instance ) ) {
36
+ self::$_instance = new self( $plugins );
37
+ }
38
+ return self::$_instance;
39
+ }
40
+
41
+ /**
42
+ * Class constructor
43
+ *
44
+ * @param string[] $plugins
45
+ * @return void
46
+ * @since 2.0.0
47
+ */
48
+ protected function __construct( $plugins ) {
49
+ foreach ( $plugins as $plugin ) {
50
+ if ( is_callable( array( $this, $plugin ), false ) ) {
51
+ $this->$plugin();
52
+ }
53
+ }
54
+ }
55
+
56
+ /**
57
+ * Prevent the class from being cloned
58
+ *
59
+ * @return void
60
+ * @since 2.0.0
61
+ */
62
+ protected function __clone() {
63
+ _doing_it_wrong( __FUNCTION__, __( 'Cheatin&#8217; uh?' ), '2.0' );
64
+ }
65
+
66
+ /**
67
+ * Compatibility with WPML
68
+ *
69
+ * @uses add_filter()
70
+ *
71
+ * @return void
72
+ * @since 2.0.0
73
+ */
74
+ public function wpml() {
75
+ add_filter( 'black_studio_tinymce_widget_update', array( $this, 'wpml_widget_update' ), 10, 2 );
76
+ add_filter( 'widget_text', array( $this, 'wpml_widget_text' ), 5, 3 );
77
+ }
78
+
79
+ /**
80
+ * Add widget text to WPML String translation
81
+ *
82
+ * @uses icl_register_string() Part of WPML
83
+ *
84
+ * @param mixed[] $instance
85
+ * @param object $widget
86
+ * @return mixed[]
87
+ * @since 2.0.0
88
+ */
89
+ public function wpml_widget_update( $instance, $widget ) {
90
+ if ( function_exists( 'icl_register_string' ) && ! empty( $widget->number ) ) {
91
+ icl_register_string( 'Widgets', 'widget body - ' . $widget->id_base . '-' . $widget->number, $instance['text'] );
92
+ }
93
+ return $instance;
94
+ }
95
+
96
+ /**
97
+ * Translate widget text
98
+ *
99
+ * @uses icl_t() Part of WPML
100
+ *
101
+ * @param string $text
102
+ * @param mixed[] $instance
103
+ * @param object|null $widget
104
+ * @return string
105
+ * @since 2.0.0
106
+ */
107
+ public function wpml_widget_text( $text, $instance, $widget = null ) {
108
+ if ( bstw()->check_widget( $widget ) && ! empty( $instance ) ) {
109
+ if ( function_exists( 'icl_t' ) ) {
110
+ $text = icl_t( 'Widgets', 'widget body - ' . $widget->id_base . '-' . $widget->number, $text );
111
+ }
112
+ }
113
+ return $text;
114
+ }
115
+
116
+ /**
117
+ * Compatibility for WP Page Widget plugin
118
+ *
119
+ * @uses add_action()
120
+ *
121
+ * @return void
122
+ * @since 2.0.0
123
+ */
124
+ public function wp_page_widget() {
125
+ add_action( 'admin_init', array( $this, 'wp_page_widget_admin_init' ) );
126
+ }
127
+
128
+ /**
129
+ * Initialize compatibility for WP Page Widget plugin (only for WordPress 3.3+)
130
+ *
131
+ * @uses add_filter()
132
+ * @uses add_action()
133
+ * @uses is_plugin_active()
134
+ * @uses get_bloginfo()
135
+ *
136
+ * @return void
137
+ * @since 2.0.0
138
+ */
139
+ public function wp_page_widget_admin_init() {
140
+ if ( is_admin() && is_plugin_active( 'wp-page-widget/wp-page-widgets.php' ) && version_compare( get_bloginfo( 'version' ), '3.3', '>=' ) ) {
141
+ add_filter( 'black_studio_tinymce_enable_pages', array( $this, 'wp_page_widget_enable_pages' ) );
142
+ add_action( 'admin_print_scripts', array( $this, 'wp_page_widget_enqueue_script' ) );
143
+ }
144
+ }
145
+
146
+ /**
147
+ * Enable filter for WP Page Widget plugin
148
+ *
149
+ * @param string[] $pages
150
+ * @return string[]
151
+ * @since 2.0.0
152
+ */
153
+ public function wp_page_widget_enable_pages( $pages ) {
154
+ $pages[] = 'post-new.php';
155
+ $pages[] = 'post.php';
156
+ if ( isset( $_GET['action'] ) && $_GET['action'] == 'edit' ) {
157
+ $pages[] = 'edit-tags.php';
158
+ }
159
+ if ( isset( $_GET['page'] ) && in_array( $_GET['page'], array( 'pw-front-page', 'pw-search-page' ) ) ) {
160
+ $pages[] = 'admin.php';
161
+ }
162
+ return $pages;
163
+ }
164
+
165
+ /**
166
+ * Enqueue script for WP Page Widget plugin
167
+ *
168
+ * @uses apply_filters()
169
+ * @uses wp_enqueue_script()
170
+ * @uses plugins_url()
171
+ * @uses SCRIPT_DEBUG
172
+ *
173
+ * @return void
174
+ * @since 2.0.0
175
+ */
176
+ public function wp_page_widget_enqueue_script() {
177
+ $main_script = apply_filters( 'black-studio-tinymce-widget-script', 'black-studio-tinymce-widget' );
178
+ $compat_script = 'wp-page-widget';
179
+ $suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
180
+ wp_enqueue_script(
181
+ $compat_script,
182
+ plugins_url( 'js/' . $compat_script . $suffix . '.js', dirname( __FILE__ ) ),
183
+ array( 'jquery', 'editor', 'quicktags', $main_script ),
184
+ bstw()->get_version(),
185
+ true
186
+ );
187
+ }
188
+
189
+ /**
190
+ * Compatibility with Page Builder (SiteOrigin Panels)
191
+ *
192
+ * @uses add_action()
193
+ *
194
+ * @return void
195
+ * @since 2.0.0
196
+ */
197
+ public function siteorigin_panels() {
198
+ add_action( 'admin_init', array( $this, 'siteorigin_panels_disable_compat' ), 7 );
199
+ add_action( 'admin_init', array( $this, 'siteorigin_panels_admin_init' ) );
200
+ }
201
+
202
+ /**
203
+ * Initialize compatibility for Page Builder (SiteOrigin Panels)
204
+ *
205
+ * @uses add_filter()
206
+ * @uses add_action()
207
+ * @uses remove_filter()
208
+ * @uses add_action()
209
+ * @uses is_plugin_active()
210
+ *
211
+ * @return void
212
+ * @since 2.0.0
213
+ */
214
+ public function siteorigin_panels_admin_init() {
215
+ if ( is_admin() && is_plugin_active( 'siteorigin-panels/siteorigin-panels.php' ) ) {
216
+ add_filter( 'siteorigin_panels_widget_object', array( $this, 'siteorigin_panels_widget_object' ), 10 );
217
+ add_filter( 'black_studio_tinymce_container_selectors', array( $this, 'siteorigin_panels_container_selectors' ) );
218
+ add_filter( 'black_studio_tinymce_activate_events', array( $this, 'siteorigin_panels_activate_events' ) );
219
+ add_filter( 'black_studio_tinymce_deactivate_events', array( $this, 'siteorigin_panels_deactivate_events' ) );
220
+ add_filter( 'black_studio_tinymce_enable_pages', array( $this, 'siteorigin_panels_enable_pages' ) );
221
+ add_filter( 'wp_editor_settings', array( $this, 'siteorigin_panels_editor_settings' ), 20, 2 );
222
+ remove_filter( 'widget_text', array( bstw()->text_filters(), 'wpautop' ), 40 );
223
+ add_action( 'black_studio_tinymce_after_editor', array( $this, 'siteorigin_panels_after_editor' ) );
224
+ }
225
+ }
226
+
227
+ /**
228
+ * Remove widget number to prevent translation when using Page Builder (SiteOrigin Panels) + WPML String Translation
229
+ *
230
+ * @param object $the_widget
231
+ * @return object
232
+ * @since 2.0.0
233
+ */
234
+ public function siteorigin_panels_widget_object( $the_widget ) {
235
+ if ( isset( $the_widget->id_base ) && $the_widget->id_base == 'black-studio-tinymce' ) {
236
+ $the_widget->number = '';
237
+ }
238
+ return $the_widget;
239
+ }
240
+
241
+ /**
242
+ * Add selector for widget detection for Page Builder (SiteOrigin Panels)
243
+ *
244
+ * @param string[] $selectors
245
+ * @return string[]
246
+ * @since 2.0.0
247
+ */
248
+ public function siteorigin_panels_container_selectors( $selectors ) {
249
+ $selectors[] = 'div.panel-dialog';
250
+ return $selectors;
251
+ }
252
+
253
+ /**
254
+ * Add activate events for Page Builder (SiteOrigin Panels)
255
+ *
256
+ * @param string[] $events
257
+ * @return string[]
258
+ * @since 2.0.0
259
+ */
260
+ public function siteorigin_panels_activate_events( $events ) {
261
+ $events[] = 'panelsopen';
262
+ return $events;
263
+ }
264
+
265
+ /**
266
+ * Add deactivate events for Page Builder (SiteOrigin Panels)
267
+ *
268
+ * @param string[] $events
269
+ * @return string[]
270
+ * @since 2.0.0
271
+ */
272
+ public function siteorigin_panels_deactivate_events( $events ) {
273
+ $events[] = 'panelsdone';
274
+ return $events;
275
+ }
276
+
277
+ /**
278
+ * Add pages filter to enable editor for Page Builder (SiteOrigin Panels)
279
+ *
280
+ * @param string[] $pages
281
+ * @return string[]
282
+ * @since 2.0.0
283
+ */
284
+ public function siteorigin_panels_enable_pages( $pages ) {
285
+ $pages[] = 'post-new.php';
286
+ $pages[] = 'post.php';
287
+ if ( isset( $_GET['page'] ) && $_GET['page'] == 'so_panels_home_page' ) {
288
+ $pages[] = 'themes.php';
289
+ }
290
+ return $pages;
291
+ }
292
+
293
+ /**
294
+ * Editor settings for use within Page Builder (SiteOrigin Panels)
295
+ *
296
+ * @return void
297
+ * @since 2.0.0
298
+ */
299
+ public function siteorigin_panels_editor_settings( $settings, $editor_id ) {
300
+ // Allow initialization of main page/post editor instances
301
+ if ( strstr( $editor_id, 'black-studio-tinymce' ) === false ) {
302
+ $settings['tinymce'] = array( 'wp_skip_init' => false );
303
+ }
304
+ // Prevent wpautop on editor instances inside Page Builder
305
+ if ( $editor_id == 'widget-black-studio-tinymce-{$id}-text' ) {
306
+ $settings['default_editor'] = 'html';
307
+ }
308
+ return $settings;
309
+ }
310
+
311
+ /**
312
+ * Remove editor content filters for use within Page Builder (SiteOrigin Panels)
313
+ * Workaround for WordPress Core bug #28403 https://core.trac.wordpress.org/ticket/28403
314
+ *
315
+ * @return void
316
+ * @since 2.0.0
317
+ */
318
+ public function siteorigin_panels_after_editor() {
319
+ remove_filter( 'the_editor_content', 'wp_htmledit_pre' );
320
+ remove_filter( 'the_editor_content', 'wp_richedit_pre' );
321
+ }
322
+
323
+ /**
324
+ * Disable old compatibility code provided by Page Builder (SiteOrigin Panels)
325
+ *
326
+ * @return void
327
+ * @since 2.0.0
328
+ */
329
+ public function siteorigin_panels_disable_compat( ) {
330
+ remove_action( 'admin_init', 'siteorigin_panels_black_studio_tinymce_admin_init' );
331
+ remove_action( 'admin_enqueue_scripts', 'siteorigin_panels_black_studio_tinymce_admin_enqueue', 15 );
332
+ }
333
+
334
+ /**
335
+ * Compatibility with Jetpack After the deadline
336
+ *
337
+ * @uses add_action()
338
+ *
339
+ * @return void
340
+ * @since 2.0.0
341
+ */
342
+ public function jetpack_after_the_deadline() {
343
+ add_action( 'black_studio_tinymce_load', array( $this, 'jetpack_after_the_deadline_load' ) );
344
+ }
345
+
346
+ /**
347
+ * Load Jetpack After the deadline scripts
348
+ *
349
+ * @uses add_filter()
350
+ *
351
+ * @return void
352
+ * @since 2.0.0
353
+ */
354
+ public function jetpack_after_the_deadline_load() {
355
+ add_filter( 'atd_load_scripts', '__return_true' );
356
+ }
357
+
358
+ } // END class Black_Studio_TinyMCE_Compatibility_Plugins
359
+
360
+ } // class_exists check
includes/class-compatibility-wordpress.php ADDED
@@ -0,0 +1,349 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Exit if accessed directly
4
+ if ( ! defined( 'ABSPATH' ) ) {
5
+ exit;
6
+ }
7
+
8
+ /**
9
+ * Class that provides compatibility code with older WordPress versions
10
+ *
11
+ * @package Black_Studio_TinyMCE_Widget
12
+ * @since 2.0.0
13
+ */
14
+
15
+ if ( ! class_exists( 'Black_Studio_TinyMCE_Compatibility_Wordpress' ) ) {
16
+
17
+ final class Black_Studio_TinyMCE_Compatibility_Wordpress {
18
+
19
+ /**
20
+ * The single instance of the class
21
+ *
22
+ * @var object
23
+ * @since 2.0.0
24
+ */
25
+ protected static $_instance = null;
26
+
27
+ /**
28
+ * Return the single class instance
29
+ *
30
+ * @return object
31
+ * @since 2.0.0
32
+ */
33
+ public static function instance() {
34
+ if ( is_null( self::$_instance ) ) {
35
+ self::$_instance = new self();
36
+ }
37
+ return self::$_instance;
38
+ }
39
+
40
+ /**
41
+ * Class constructor
42
+ *
43
+ * @uses get_bloginfo()
44
+ * @uses add_action()
45
+ *
46
+ * @param object $plugin
47
+ * @since 2.0.0
48
+ */
49
+ protected function __construct() {
50
+ $current_version = get_bloginfo( 'version' );
51
+ $previous_versions = array( '3.2', '3.3', '3.5', '3.9' );
52
+ foreach ( $previous_versions as $previous_version ) {
53
+ if ( version_compare( $current_version, $previous_version, '<' ) ) {
54
+ add_action( 'admin_init', array( $this, 'wp_pre_' . str_replace( '.', '', $previous_version ) ), intval( 10 * $previous_version ) );
55
+ }
56
+ }
57
+ }
58
+
59
+ /**
60
+ * Prevent the class from being cloned
61
+ *
62
+ * @return void
63
+ * @since 2.0.0
64
+ */
65
+ protected function __clone() {
66
+ _doing_it_wrong( __FUNCTION__, __( 'Cheatin&#8217; uh?' ), '2.0' );
67
+ }
68
+
69
+ /**
70
+ * Compatibility for WordPress prior to 3.2
71
+ *
72
+ * @uses remove_action()
73
+ * @uses add_action()
74
+ *
75
+ * @return void
76
+ * @since 2.0.0
77
+ */
78
+ public function wp_pre_32() {
79
+ if ( bstw()->admin()->enabled() ) {
80
+ remove_action( 'admin_print_footer_scripts', array( bstw()->admin(), 'admin_print_footer_scripts' ) );
81
+ add_action( 'admin_print_footer_scripts', array( $this, 'wp_pre_32_admin_print_footer_scripts' ) );
82
+ }
83
+ }
84
+
85
+ /**
86
+ * Enqueue footer scripts for WordPress prior to 3.2
87
+ *
88
+ * @uses wp_tiny_mce()
89
+ * @uses wp_tiny_mce_preload_dialogs()
90
+ *
91
+ * @return void
92
+ * @since 2.0.0
93
+ */
94
+ public function wp_pre_32_admin_print_footer_scripts() {
95
+ if ( function_exists( 'wp_tiny_mce' ) ) {
96
+ wp_tiny_mce( false, array() );
97
+ }
98
+ if ( function_exists( 'wp_tiny_mce_preload_dialogs' ) ) {
99
+ wp_tiny_mce_preload_dialogs();
100
+ }
101
+ }
102
+
103
+ /**
104
+ * Compatibility for WordPress prior to 3.3
105
+ *
106
+ * @uses add_filter()
107
+ * @uses add_action()
108
+ * @uses remove_action()
109
+ * @uses get_bloginfo()
110
+ *
111
+ * @return void
112
+ * @since 2.0.0
113
+ */
114
+ public function wp_pre_33() {
115
+ $wp_version = get_bloginfo( 'version' );
116
+ if ( bstw()->admin()->enabled() ) {
117
+ add_filter( 'tiny_mce_before_init', array( $this, 'wp_pre_33_tiny_mce_before_init' ), 67 );
118
+ add_filter( 'black-studio-tinymce-widget-script', array( $this, 'wp_pre_33_handle' ), 67 );
119
+ add_filter( 'black-studio-tinymce-widget-style', array( $this, 'wp_pre_33_handle' ), 67 );
120
+ remove_action( 'admin_print_styles', array( bstw()->admin(), 'admin_print_styles' ) );
121
+ add_action( 'admin_print_styles', array( $this, 'wp_pre_33_admin_print_styles' ) );
122
+ remove_action( 'admin_print_scripts', array( bstw()->admin(), 'admin_print_scripts' ) );
123
+ add_action( 'admin_print_scripts', array( $this, 'wp_pre_33_admin_print_scripts' ) );
124
+ remove_action( 'admin_print_footer_scripts', array( bstw()->admin(), 'admin_print_footer_scripts' ) );
125
+ if ( ! version_compare( $wp_version, '3.2', '<' ) ) {
126
+ remove_action( 'admin_print_footer_scripts', array( $this, 'wp_pre_32_admin_print_footer_scripts' ) );
127
+ }
128
+ add_action( 'admin_print_footer_scripts', array( $this, 'wp_pre_33_admin_print_footer_scripts' ) );
129
+ }
130
+ }
131
+
132
+ /**
133
+ * Remove WP fullscreen mode and set the native tinyMCE fullscreen mode for WordPress prior to 3.3
134
+ *
135
+ * @param mixed[] $settings
136
+ * @return mixed[]
137
+ * @since 2.0.0
138
+ */
139
+ public function wp_pre_33_tiny_mce_before_init( $settings ) {
140
+ $plugins = explode( ',', $settings['plugins'] );
141
+ if ( isset( $plugins['wpfullscreen'] ) ) {
142
+ unset( $plugins['wpfullscreen'] );
143
+ }
144
+ if ( ! isset( $plugins['fullscreen'] ) ) {
145
+ $plugins[] = 'fullscreen';
146
+ }
147
+ $settings['plugins'] = implode( ',', $plugins );
148
+ return $settings;
149
+ }
150
+
151
+ /**
152
+ * Enqueue styles for WordPress prior to 3.3
153
+ *
154
+ * @uses wp_enqueue_style()
155
+ * @uses Black_Studio_TinyMCE_Admin::enqueue_style()
156
+ *
157
+ * @return void
158
+ * @since 2.0.0
159
+ */
160
+ public function wp_pre_33_admin_print_styles() {
161
+ wp_enqueue_style( 'thickbox' );
162
+ wp_enqueue_style( 'editor-buttons' );
163
+ bstw()->admin()->enqueue_style();
164
+ }
165
+
166
+ /**
167
+ * Enqueue header scripts for WordPress prior to 3.3
168
+ *
169
+ * @uses wp_enqueue_script()
170
+ * @uses Black_Studio_TinyMCE_Admin::enqueue_script()
171
+ * @uses Black_Studio_TinyMCE_Admin::localize_script()
172
+ *
173
+ * @return void
174
+ * @since 2.0.0
175
+ */
176
+ public function wp_pre_33_admin_print_scripts() {
177
+ wp_enqueue_script( 'media-upload' );
178
+ bstw()->admin()->enqueue_script();
179
+ bstw()->admin()->localize_script();
180
+ }
181
+
182
+ /**
183
+ * Filter to enqueue style / script for WordPress prior to 3.3
184
+ *
185
+ * @return string
186
+ * @since 2.0.0
187
+ */
188
+ public function wp_pre_33_handle() {
189
+ return 'black-studio-tinymce-widget-pre33';
190
+ }
191
+
192
+ /**
193
+ * Enqueue footer scripts for WordPress prior to 3.3
194
+ *
195
+ * @uses wp_tiny_mce()
196
+ * @uses wp_preload_dialog()
197
+ *
198
+ * @return void
199
+ * @since 2.0.0
200
+ */
201
+ public function wp_pre_33_admin_print_footer_scripts() {
202
+ if ( function_exists( 'wp_tiny_mce' ) ) {
203
+ wp_tiny_mce( false, array() );
204
+ }
205
+ if ( function_exists( 'wp_preload_dialogs' ) ) {
206
+ wp_preload_dialogs( array( 'plugins' => 'wpdialogs,wplink,wpfullscreen' ) );
207
+ }
208
+ }
209
+
210
+ /**
211
+ * Compatibility for WordPress prior to 3.5
212
+ *
213
+ * @uses add_filter()
214
+ * @uses Black_Studio_TinyMCE_Admin::enabled()
215
+ *
216
+ * @return void
217
+ * @since 2.0.0
218
+ */
219
+ public function wp_pre_35() {
220
+ if ( bstw()->admin()->enabled() ) {
221
+ add_filter( '_upload_iframe_src', array( $this, 'wp_pre_35_upload_iframe_src' ), 65 );
222
+ }
223
+ }
224
+
225
+ /**
226
+ * Enable full media options in upload dialog for WordPress prior to 3.5
227
+ * (this is done excluding post_id parameter in Thickbox iframe url)
228
+ *
229
+ * @global string $pagenow
230
+ * @param string $upload_iframe_src
231
+ * @return string
232
+ * @since 2.0.0
233
+ */
234
+ public function wp_pre_35_upload_iframe_src( $upload_iframe_src ) {
235
+ global $pagenow;
236
+ if ( $pagenow == 'widgets.php' || ( $pagenow == 'admin-ajax.php' && isset( $_POST['id_base'] ) && $_POST['id_base'] == 'black-studio-tinymce' ) ) {
237
+ $upload_iframe_src = str_replace( 'post_id=0', '', $upload_iframe_src );
238
+ }
239
+ return $upload_iframe_src;
240
+ }
241
+
242
+ /**
243
+ * Compatibility for WordPress prior to 3.9
244
+ *
245
+ * @uses add_action()
246
+ * @uses remove_action()
247
+ * @uses add_filter()
248
+ * @uses get_bloginfo()
249
+ * @uses Black_Studio_TinyMCE_Admin::enabled()
250
+ *
251
+ * @return void
252
+ * @since 2.0.0
253
+ */
254
+ public function wp_pre_39() {
255
+ $wp_version = get_bloginfo( 'version' );
256
+ if ( bstw()->admin()->enabled() ) {
257
+ add_filter( 'black-studio-tinymce-widget-script', array( $this, 'wp_pre_39_handle' ), 61 );
258
+ add_filter( 'tiny_mce_before_init', array( $this, 'wp_pre_39_tiny_mce_before_init' ), 61 );
259
+ add_action( 'admin_print_footer_scripts', array( $this, 'wp_pre_39_admin_print_footer_scripts' ) );
260
+ remove_action( 'admin_print_footer_scripts', array( bstw()->admin(), 'admin_print_footer_scripts' ) );
261
+ if ( ! version_compare( $wp_version, '3.2', '<' ) ) {
262
+ remove_action( 'admin_print_footer_scripts', array( $this, 'wp_pre_32_admin_print_footer_scripts' ) );
263
+ }
264
+ if ( ! version_compare( $wp_version, '3.3', '<' ) ) {
265
+ remove_action( 'admin_print_footer_scripts', array( $this, 'wp_pre_33_admin_print_footer_scripts' ) );
266
+ }
267
+ add_action( 'black_studio_tinymce_editor', array( $this, 'wp_pre_39_editor' ), 10, 4 );
268
+ remove_action( 'black_studio_tinymce_editor', array( bstw()->admin(), 'editor' ), 10, 3 );
269
+ }
270
+ }
271
+
272
+ /**
273
+ * Filter to enqueue style / script for WordPress prior to 3.9
274
+ *
275
+ * @return string
276
+ * @since 2.0.0
277
+ */
278
+ public function wp_pre_39_handle() {
279
+ return 'black-studio-tinymce-widget-pre39';
280
+ }
281
+
282
+ /**
283
+ * TinyMCE initialization for WordPress prior to 3.9
284
+ *
285
+ * @param mixed[] $settings
286
+ * @return mixed[]
287
+ * @since 2.0.0
288
+ */
289
+ public function wp_pre_39_tiny_mce_before_init( $settings ) {
290
+ $custom_settings = array(
291
+ 'remove_linebreaks' => false,
292
+ 'convert_newlines_to_brs' => false,
293
+ 'force_p_newlines' => true,
294
+ 'force_br_newlines' => false,
295
+ 'remove_redundant_brs' => false,
296
+ 'forced_root_block' => 'p',
297
+ 'apply_source_formatting' => true,
298
+ );
299
+ // Return modified settings
300
+ return array_merge( $settings, $custom_settings );
301
+ }
302
+
303
+ /**
304
+ * Enqueue footer scripts for WordPress prior to 3.9
305
+ *
306
+ * @uses wp_editor()
307
+ *
308
+ * @return void
309
+ * @since 2.0.0
310
+ */
311
+ public function wp_pre_39_admin_print_footer_scripts() {
312
+ if ( function_exists( 'wp_editor' ) ) {
313
+ wp_editor( '', 'black-studio-tinymce-widget' );
314
+ }
315
+ }
316
+
317
+ /**
318
+ * Output the visual editor code for WordPress prior to 3.9
319
+ *
320
+ * @uses esc_attr()
321
+ * @uses esc_textarea()
322
+ * @uses do_action()
323
+ *
324
+ * @return void
325
+ * @since 2.0.0
326
+ */
327
+ public function wp_pre_39_editor( $text, $id, $name = '', $type = 'visual' ) {
328
+ $switch_class = $type == 'visual' ? 'html-active' : 'tmce-active';
329
+ ?>
330
+ <div id="<?php echo esc_attr( $id ); ?>-wp-content-wrap" class="wp-core-ui wp-editor-wrap <?php echo esc_attr( $switch_class ); ?> has-dfw">
331
+ <div id="<?php echo esc_attr( $id ); ?>-wp-content-editor-tools" class="wp-editor-tools hide-if-no-js">
332
+ <div class="wp-editor-tabs">
333
+ <a id="<?php echo esc_attr( $id ); ?>-content-html" class="wp-switch-editor switch-html"><?php _e( 'HTML' ); ?></a>
334
+ <a id="<?php echo esc_attr( $id ); ?>-content-tmce" class="wp-switch-editor switch-tmce"><?php _e( 'Visual' ); ?></a>
335
+ </div>
336
+ <div id="<?php esc_attr( $id ); ?>-wp-content-media-buttons" class="wp-media-buttons">
337
+ <?php do_action( 'media_buttons', $id ); ?>
338
+ </div>
339
+ </div>
340
+ <div class="wp-editor-container">
341
+ <textarea class="widefat" rows="20" cols="40" id="<?php echo esc_attr( $id ); ?>" name="<?php echo esc_attr( $name ); ?>"><?php echo esc_textarea( $text ); ?></textarea>
342
+ </div>
343
+ </div>
344
+ <?php
345
+ }
346
+
347
+ } // END class Black_Studio_TinyMCE_Compatibility_Wordpress
348
+
349
+ } // class_exists check
includes/class-compatibility.php ADDED
@@ -0,0 +1,150 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Exit if accessed directly
4
+ if ( ! defined( 'ABSPATH' ) ) {
5
+ exit;
6
+ }
7
+
8
+ /**
9
+ * Class that manages compatibility code
10
+ *
11
+ * @package Black_Studio_TinyMCE_Widget
12
+ * @since 2.0.0
13
+ */
14
+
15
+ if ( ! class_exists( 'Black_Studio_TinyMCE_Compatibility' ) ) {
16
+
17
+ final class Black_Studio_TinyMCE_Compatibility {
18
+
19
+ /**
20
+ * The single instance of the plugin class
21
+ *
22
+ * @var object
23
+ * @since 2.0.0
24
+ */
25
+ protected static $_instance = null;
26
+
27
+ /**
28
+ * Instance of compatibility class for 3rd party plugins
29
+ *
30
+ * @var object
31
+ * @since 2.0.0
32
+ */
33
+ protected static $plugins = null;
34
+
35
+ /**
36
+ * Instance of compatibility class for WordPress old versions
37
+ *
38
+ * @var object
39
+ * @since 2.0.0
40
+ */
41
+ protected static $wordpress = null;
42
+
43
+ /**
44
+ * Return the single class instance
45
+ *
46
+ * @return object
47
+ * @since 2.0.0
48
+ */
49
+ public static function instance() {
50
+ if ( is_null( self::$_instance ) ) {
51
+ self::$_instance = new self();
52
+ }
53
+ return self::$_instance;
54
+ }
55
+
56
+ /**
57
+ * Return the instance of the compatibility class for 3rd party plugins
58
+ *
59
+ * @return object
60
+ * @since 2.0.0
61
+ */
62
+ public static function plugins() {
63
+ return self::$plugins;
64
+ }
65
+
66
+ /**
67
+ * Return the instance of the compatibility class for WordPress old versions
68
+ *
69
+ * @return object
70
+ * @since 2.0.0
71
+ */
72
+ public static function wordpress() {
73
+ return self::$wordpress;
74
+ }
75
+
76
+ /**
77
+ * Class constructor
78
+ *
79
+ * @global object $wp_embed
80
+ * @return void
81
+ * @since 2.0.0
82
+ */
83
+ protected function __construct() {
84
+ $this->load_deprecated();
85
+ $this->load_plugins();
86
+ $this->load_wordpress();
87
+ }
88
+
89
+ /**
90
+ * Prevent the class from being cloned
91
+ *
92
+ * @return void
93
+ * @since 2.0.0
94
+ */
95
+ protected function __clone() {
96
+ _doing_it_wrong( __FUNCTION__, __( 'Cheatin&#8217; uh?' ), '2.0' );
97
+ }
98
+
99
+ /**
100
+ * Load compatibility code for previous BSTW versions
101
+ *
102
+ * @uses apply_filters()
103
+ * @uses plugin_dir_path()
104
+ *
105
+ * @return void
106
+ * @since 2.0.0
107
+ */
108
+ public function load_deprecated() {
109
+ $load_deprecated = apply_filters( 'black_studio_tinymce_load_deprecated', true );
110
+ if ( $load_deprecated ) {
111
+ include_once( plugin_dir_path( dirname( __FILE__ ) ) . '/includes/deprecated.php' );
112
+ }
113
+ }
114
+
115
+ /**
116
+ * Load compatibility code for other plugins
117
+ *
118
+ * @uses apply_filters()
119
+ * @uses plugin_dir_path()
120
+ *
121
+ * @return void
122
+ * @since 2.0.0
123
+ */
124
+ public function load_plugins() {
125
+ $load_compatibility_plugins = apply_filters( 'black_studio_tinymce_load_compatibility_plugins', array( 'siteorigin_panels', 'wpml', 'jetpack_after_the_deadline', 'wp_page_widget' ) );
126
+ if ( ! empty( $load_compatibility_plugins ) ) {
127
+ include_once( plugin_dir_path( dirname( __FILE__ ) ) . '/includes/class-compatibility-plugins.php' );
128
+ self::$plugins = Black_Studio_TinyMCE_Compatibility_Plugins::instance( $load_compatibility_plugins );
129
+ }
130
+ }
131
+
132
+ /**
133
+ * Load compatibility code for previous WordPress versions
134
+ *
135
+ * @uses get_bloginfo()
136
+ * @uses plugin_dir_path()
137
+ *
138
+ * @return void
139
+ * @since 2.0.0
140
+ */
141
+ public function load_wordpress() {
142
+ if ( version_compare( get_bloginfo( 'version' ), '3.9', '<' ) ) {
143
+ include_once( plugin_dir_path( dirname( __FILE__ ) ) . '/includes/class-compatibility-wordpress.php' );
144
+ self::$wordpress = Black_Studio_TinyMCE_Compatibility_Wordpress::instance();
145
+ }
146
+ }
147
+
148
+ } // END class Black_Studio_TinyMCE_Compatibility
149
+
150
+ } // class_exists check
includes/class-text-filters.php ADDED
@@ -0,0 +1,161 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Exit if accessed directly
4
+ if ( ! defined( 'ABSPATH' ) ) {
5
+ exit;
6
+ }
7
+
8
+ /**
9
+ * Class that applies widget text filters
10
+ *
11
+ * @package Black_Studio_TinyMCE_Widget
12
+ * @since 2.0.0
13
+ */
14
+
15
+ if ( ! class_exists( 'Black_Studio_TinyMCE_Text_Filters' ) ) {
16
+
17
+ final class Black_Studio_TinyMCE_Text_Filters {
18
+
19
+ /**
20
+ * The single instance of the class
21
+ *
22
+ * @var object
23
+ * @since 2.0.0
24
+ */
25
+ protected static $_instance = null;
26
+
27
+ /**
28
+ * Return the single class instance
29
+ *
30
+ * @return object
31
+ * @since 2.0.0
32
+ */
33
+ public static function instance() {
34
+ if ( is_null( self::$_instance ) ) {
35
+ self::$_instance = new self();
36
+ }
37
+ return self::$_instance;
38
+ }
39
+
40
+ /**
41
+ * Class constructor
42
+ *
43
+ * @uses add_action()
44
+ * @uses add_filter()
45
+ * @uses get_option()
46
+ * @uses get_bloginfo()
47
+ *
48
+ * @global object $wp_embed
49
+ * @return void
50
+ * @since 2.0.0
51
+ */
52
+ protected function __construct() {
53
+ // Support for wp_kses_post in widget text
54
+ add_filter( 'widget_text', array( $this, 'wp_kses_post' ), 10, 3 );
55
+ // Support for autoembed urls in widget text
56
+ if ( get_option( 'embed_autourls' ) ) {
57
+ add_filter( 'widget_text', array( $this, 'autoembed' ), 20, 3 );
58
+ }
59
+ // Support for smilies in widget text
60
+ if ( get_option( 'use_smilies' ) ) {
61
+ add_filter( 'widget_text', array( $this, 'convert_smilies' ), 30, 3 );
62
+ }
63
+ // Support for wpautop in widget text
64
+ add_filter( 'widget_text', array( $this, 'wpautop' ), 40, 3 );
65
+ // Support for shortcodes in widget text
66
+ add_filter( 'widget_text', array( $this, 'do_shortcode' ), 50, 3 );
67
+ }
68
+
69
+ /**
70
+ * Prevent the class from being cloned
71
+ *
72
+ * @return void
73
+ * @since 2.0.0
74
+ */
75
+ protected function __clone() {
76
+ _doing_it_wrong( __FUNCTION__, __( 'Cheatin&#8217; uh?' ), '2.0' );
77
+ }
78
+
79
+ /**
80
+ * Apply wp_kses to widget text
81
+ *
82
+ * @uses wp_kses_post()
83
+ *
84
+ * @param string $text
85
+ * @return string
86
+ * @since 2.0.0
87
+ */
88
+ public function wp_kses_post( $text, $instance, $widget = null ) {
89
+ if ( bstw()->check_widget( $widget ) && ! empty( $instance ) ) {
90
+ $text = wp_kses_post( $text );
91
+ }
92
+ return $text;
93
+ }
94
+
95
+ /**
96
+ * Apply auto_embed to widget text
97
+ *
98
+ * @param string $text
99
+ * @return string
100
+ * @since 2.0.0
101
+ */
102
+ public function autoembed( $text, $instance, $widget = null ) {
103
+ if ( bstw()->check_widget( $widget ) && ! empty( $instance ) ) {
104
+ global $wp_embed;
105
+ $text = $wp_embed->run_shortcode( $text );
106
+ $text = $wp_embed->autoembed( $text );
107
+ }
108
+ return $text;
109
+ }
110
+
111
+ /**
112
+ * Apply smilies conversion to widget text
113
+ *
114
+ * @uses convert_smilies()
115
+ *
116
+ * @param string $text
117
+ * @return string
118
+ * @since 2.0.0
119
+ */
120
+ public function convert_smilies( $text, $instance, $widget = null ) {
121
+ if ( bstw()->check_widget( $widget ) && ! empty( $instance ) ) {
122
+ $text = convert_smilies( $text );
123
+ }
124
+ return $text;
125
+ }
126
+
127
+ /**
128
+ * Apply automatic paragraphs in widget text
129
+ *
130
+ * @uses wpautop()
131
+ *
132
+ * @param string $text
133
+ * @return string
134
+ * @since 2.0.0
135
+ */
136
+ public function wpautop( $text, $instance, $widget = null ) {
137
+ if ( bstw()->check_widget( $widget ) && ! empty( $instance ) ) {
138
+ $text = wpautop( $text );
139
+ }
140
+ return $text;
141
+ }
142
+
143
+ /**
144
+ * Process shortcodes in widget text
145
+ *
146
+ * @uses do_shortcode()
147
+ *
148
+ * @param string $text
149
+ * @return string
150
+ * @since 2.0.0
151
+ */
152
+ public function do_shortcode( $text, $instance, $widget = null ) {
153
+ if ( bstw()->check_widget( $widget ) && ! empty( $instance ) ) {
154
+ $text = do_shortcode( $text );
155
+ }
156
+ return $text;
157
+ }
158
+
159
+ } // END class Black_Studio_TinyMCE_Text_Filters
160
+
161
+ } // class_exists check
includes/class-widget.php ADDED
@@ -0,0 +1,123 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Exit if accessed directly
4
+ if ( ! defined( 'ABSPATH' ) ) {
5
+ exit;
6
+ }
7
+
8
+ /**
9
+ * Widget class
10
+ *
11
+ * @package Black_Studio_TinyMCE_Widget
12
+ * @since 0.5
13
+ */
14
+
15
+ if ( ! class_exists( 'WP_Widget_Black_Studio_TinyMCE' ) ) {
16
+
17
+ class WP_Widget_Black_Studio_TinyMCE extends WP_Widget {
18
+
19
+ /**
20
+ * Widget Class constructor
21
+ *
22
+ * @uses WP_Widget::__construct()
23
+ * @return void
24
+ * @since 0.5
25
+ */
26
+ public function __construct() {
27
+ /* translators: title of the widget */
28
+ $widget_title = __( 'Visual Editor', 'black-studio-tinymce-widget' );
29
+ /* translators: description of the widget, shown in available widgets */
30
+ $widget_description = __( 'Arbitrary text or HTML with visual editor', 'black-studio-tinymce-widget' );
31
+ $widget_ops = array( 'classname' => 'widget_black_studio_tinymce', 'description' => $widget_description );
32
+ $control_ops = array( 'width' => 800, 'height' => 600 );
33
+ parent::__construct( 'black-studio-tinymce', $widget_title, $widget_ops, $control_ops );
34
+ }
35
+
36
+ /**
37
+ * Output widget HTML code
38
+ *
39
+ * @uses apply_filters()
40
+ * @uses WP_Widget::$id_base
41
+ *
42
+ * @param string[] $args
43
+ * @param mixed[] $instance
44
+ * @return void
45
+ * @since 0.5
46
+ */
47
+ public function widget( $args, $instance ) {
48
+ $before_widget = $args['before_widget'];
49
+ $after_widget = $args['after_widget'];
50
+ $before_title = $args['before_title'];
51
+ $after_title = $args['after_title'];
52
+ $before_text = apply_filters( 'black_studio_tinymce_before_text', '<div class="textwidget">', $instance );
53
+ $after_text = apply_filters( 'black_studio_tinymce_after_text', '</div>', $instance );
54
+ $title = apply_filters( 'widget_title', empty( $instance['title'] ) ? '' : $instance['title'], $instance, $this->id_base );
55
+ $text = apply_filters( 'widget_text', empty( $instance['text'] ) ? '' : $instance['text'], $instance, $this );
56
+ $output = $before_widget;
57
+ if ( ! empty( $title ) ) {
58
+ $output .= $before_title . $title . $after_title;
59
+ }
60
+ $output .= $before_text . $text . $after_text;
61
+ $output .= $after_widget;
62
+ echo $output; // xss ok
63
+ }
64
+
65
+ /**
66
+ * Update widget data
67
+ *
68
+ * @uses current_user_can()
69
+ * @uses wp_filter_post_kses()
70
+ * @uses apply_filters()
71
+ *
72
+ * @param mixed[] $new_instance
73
+ * @param mixed[] $old_instance
74
+ * @return mixed[]
75
+ * @since 0.5
76
+ */
77
+ public function update( $new_instance, $old_instance ) {
78
+ $instance = $old_instance;
79
+ $instance['title'] = strip_tags( $new_instance['title'] );
80
+ if ( current_user_can( 'unfiltered_html' ) ) {
81
+ $instance['text'] = $new_instance['text'];
82
+ }
83
+ else {
84
+ $instance['text'] = stripslashes( wp_filter_post_kses( addslashes( $new_instance['text'] ) ) ); // wp_filter_post_kses() expects slashed
85
+ }
86
+ $instance['type'] = strip_tags( $new_instance['type'] );
87
+ $instance = apply_filters( 'black_studio_tinymce_widget_update', $instance, $this );
88
+ return $instance;
89
+ }
90
+
91
+ /**
92
+ * Output widget form
93
+ *
94
+ * @uses wp_parse_args()
95
+ * @uses apply_filters()
96
+ * @uses esc_attr()
97
+ * @uses esc_textarea()
98
+ * @uses WP_Widget::get_field_id()
99
+ * @uses WP_Widget::get_field_name()
100
+ * @uses _e()
101
+ * @uses do_action()
102
+ * @uses apply_filters()
103
+ *
104
+ * @param mixed[] $instance
105
+ * @return void
106
+ * @since 0.5
107
+ */
108
+ public function form( $instance ) {
109
+ $instance = wp_parse_args( (array) $instance, array( 'title' => '', 'text' => '', 'type' => 'visual' ) );
110
+ $title = strip_tags( $instance['title'] );
111
+ do_action( 'black_studio_tinymce_before_editor' );
112
+ ?>
113
+ <input id="<?php echo $this->get_field_id( 'type' ); ?>" name="<?php echo $this->get_field_name( 'type' ); ?>" type="hidden" value="<?php echo esc_attr( $instance['type'] ); ?>" />
114
+ <p><label for="<?php echo $this->get_field_id( 'title' ); ?>"><?php _e( 'Title:' ); ?></label>
115
+ <input class="widefat" id="<?php echo $this->get_field_id( 'title' ); ?>" name="<?php echo $this->get_field_name( 'title' ); ?>" type="text" value="<?php echo esc_attr( $title ); ?>" /></p>
116
+ <?php
117
+ do_action( 'black_studio_tinymce_editor', $instance['text'], $this->get_field_id( 'text' ), $this->get_field_name( 'text' ), $instance['type'] );
118
+ do_action( 'black_studio_tinymce_after_editor' );
119
+ }
120
+
121
+ } // END class WP_Widget_Black_Studio_TinyMCE
122
+
123
+ } // class_exists check
includes/deprecated.php ADDED
@@ -0,0 +1,152 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ // Exit if accessed directly
4
+ if ( ! defined( 'ABSPATH' ) ) {
5
+ exit;
6
+ }
7
+
8
+ /**
9
+ * Deprecated functions
10
+ *
11
+ * @package Black_Studio_TinyMCE_Widget
12
+ */
13
+
14
+ /**
15
+ * Global var with plugin version for backward compatibility
16
+ *
17
+ * @since 0.6.3
18
+ * @deprecated 2.0.0
19
+ */
20
+ global $black_studio_tinymce_widget_version; // global is necessary because this file is included in a non-global context
21
+ $black_studio_tinymce_widget_version = Black_Studio_TinyMCE_Plugin::$version;
22
+
23
+ /**
24
+ * Global var used for development
25
+ *
26
+ * @since 0.9.4
27
+ * @deprecated 1.4
28
+ */
29
+ global $black_studio_tinymce_widget_dev_mode ; // global is necessary because this file is included in a non-global context
30
+ $black_studio_tinymce_widget_dev_mode = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG;
31
+
32
+ /**
33
+ * @since 1.4.0
34
+ * @deprecated 2.0.0
35
+ */
36
+ function black_studio_tinymce_get_version() {
37
+ _deprecated_function( __FUNCTION__, '2.0.0', 'bstw()->get_version()' );
38
+ bstw()->get_version();
39
+ }
40
+
41
+ /**
42
+ * @since 0.7.0
43
+ * @deprecated 2.0.0
44
+ */
45
+ function black_studio_tinymce_widgets_init() {
46
+ _deprecated_function( __FUNCTION__, '2.0.0', 'bstw()->widgets_init()' );
47
+ bstw()->widgets_init();
48
+ }
49
+
50
+ /**
51
+ * @since 0.8.0
52
+ * @deprecated 2.0.0
53
+ */
54
+ function black_studio_tinymce_admin_init() {
55
+ _deprecated_function( __FUNCTION__, '2.0.0', 'bstw()->admin()->admin_init()' );
56
+ bstw()->admin()->admin_init();
57
+ }
58
+
59
+ /**
60
+ * @since 0.5.0
61
+ * @deprecated 2.0.0
62
+ */
63
+ function black_studio_tinymce_load_tiny_mce() {
64
+ _deprecated_function( __FUNCTION__, '2.0.0', 'bstw()->admin()->enqueue_media()' );
65
+ bstw()->admin()->enqueue_media();
66
+ }
67
+
68
+ /**
69
+ * @since 0.5.0
70
+ * @deprecated 2.0.0
71
+ */
72
+ function black_studio_tinymce_init_editor( $arg ) {
73
+ _deprecated_function( __FUNCTION__, '2.0.0' );
74
+ return $arg;
75
+ }
76
+
77
+ /**
78
+ * @since 0.5.0
79
+ * @deprecated 2.0.0
80
+ */
81
+ function black_studio_tinymce_styles() {
82
+ _deprecated_function( __FUNCTION__, '2.0.0', 'bstw()->admin()->admin_print_styles()' );
83
+ bstw()->admin()->admin_print_styles();
84
+ }
85
+
86
+ /**
87
+ * @since 0.5.0
88
+ * @deprecated 2.0.0
89
+ */
90
+ function black_studio_tinymce_scripts() {
91
+ _deprecated_function( __FUNCTION__, '2.0.0', 'bstw()->admin()->admin_print_scripts()' );
92
+ bstw()->admin()->admin_print_scripts();
93
+ }
94
+
95
+ /**
96
+ * @since 0.7.0
97
+ * @deprecated 2.0.0
98
+ */
99
+ function black_studio_tinymce_footer_scripts() {
100
+ _deprecated_function( __FUNCTION__, '2.0.0', 'bstw()->admin()->admin_print_footer_scripts()' );
101
+ bstw()->admin()->admin_print_footer_scripts();
102
+ }
103
+
104
+ /**
105
+ * @since 0.6.0
106
+ * @deprecated 0.7.0
107
+ */
108
+ function black_studio_tinymce_preload_dialogs() {
109
+ _deprecated_function( __FUNCTION__, '0.7', 'bstw()->admin()->admin_print_footer_scripts()' );
110
+ bstw()->admin()->admin_print_footer_scripts();
111
+ }
112
+
113
+ /**
114
+ * @uses get_option()
115
+ *
116
+ * @since 1.3.0
117
+ * @deprecated 2.0.0
118
+ */
119
+ function black_studio_tinymce_apply_smilies_to_widget_text( $text ) {
120
+ _deprecated_function( __FUNCTION__, '2.0.0', 'bstw()->text_filters()->convert_smilies( ... )' );
121
+ if ( get_option( 'use_smilies' ) ) {
122
+ $text = bstw()->text_filters()->convert_smilies( $text );
123
+ }
124
+ return $text;
125
+ }
126
+
127
+ /**
128
+ * @since 1.0.0
129
+ * @deprecated 2.0.0
130
+ */
131
+ function black_studio_tinymce_upload_iframe_src( $arg ){
132
+ _deprecated_function( __FUNCTION__, '2.0.0', 'bstw()->compatibility()->wordpress()->wp_pre_35_upload_iframe_src( ... )' );
133
+ bstw()->compatibility()->wordpress()->wp_pre_35_upload_iframe_src( $arg );
134
+ }
135
+
136
+ /**
137
+ * @since 1.2.0
138
+ * @deprecated 2.0.0
139
+ */
140
+ function black_studio_tinymce_editor_accessibility_mode( $editor ) {
141
+ _deprecated_function( __FUNCTION__, '2.0.0', 'bstw()->admin()->editor_accessibility_mode( ... )' );
142
+ bstw()->admin()->editor_accessibility_mode( $editor );
143
+ }
144
+
145
+ /**
146
+ * @since 1.4.5
147
+ * @deprecated 2.0.0
148
+ */
149
+ function black_studio_tinymce_siteorigin_panels_widget_object( $the_widget ) {
150
+ _deprecated_function( __FUNCTION__, '2.0.0', 'bstw()-compatibility()->plugins()->siteorigin_panels_widget_object( ... )' );
151
+ bstw()->compatibility()->plugins()->siteorigin_panels_widget_object( $the_widget );
152
+ }
js/black-studio-tinymce-widget-pre33.js ADDED
@@ -0,0 +1,244 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* Black Studio TinyMCE Widget - JS */
2
+
3
+ /* global tinymce */
4
+ /* global bstw_data */
5
+ /* global wpActiveEditor: true */
6
+ /* global edCanvas: true */
7
+
8
+ (function( $ ) {
9
+
10
+ // Returns bstw instance given the textarea ID or any jQuery object inside the widget object
11
+ function bstw( arg ) {
12
+
13
+ var id = null;
14
+
15
+ // ID initialization
16
+ if ( typeof arg === 'string' ) {
17
+ id = arg;
18
+ }
19
+ // jQuery object initialization
20
+ else if ( typeof arg === 'object' && arg instanceof jQuery ) {
21
+ id = $( 'textarea[id^=widget-black-studio-tinymce]', arg.closest( bstw_data.container_selectors ) ).attr( 'id' );
22
+ }
23
+
24
+ // Create and return instance
25
+ return {
26
+
27
+ // Activate visual editor
28
+ activate: function () {
29
+ $( '#' + id ).addClass( 'mceEditor' );
30
+ if ( typeof tinymce === 'object' && typeof tinymce.execCommand === 'function' ) {
31
+ this.deactivate();
32
+ try {
33
+ tinymce.execCommand( 'mceAddControl', false, id );
34
+ } catch( e ) {
35
+ window.alert( e );
36
+ }
37
+ }
38
+ return this;
39
+ },
40
+
41
+ // Deactivate visual editor
42
+ deactivate: function() {
43
+ if ( typeof tinymce === 'object' && typeof tinymce.execCommand === 'function' ) {
44
+ if ( this.is_tinymce_active() ) {
45
+ var content = tinymce.get( id ).getContent();
46
+ // tinymce.execCommand('mceRemoveControl', false, id);
47
+ tinymce.get( id ).remove();
48
+ $( '#' + id ).val( content );
49
+ }
50
+ }
51
+ return this;
52
+ },
53
+
54
+ // Activate editor deferred (after widget opening)
55
+ activate_after_open: function() {
56
+ // Activate only if type is set to visual
57
+ if ( this.get_mode() === 'visual' ) {
58
+ // If textarea is visible and animation/ajax has completed (or in accessibility mode) then trigger a click to Visual button and enable the editor
59
+ if ( $('div.widget:has(#' + id + ') :animated' ).size() === 0 && ! this.is_tinymce_active() && this.is_textearea_visible() ) {
60
+ this.set_mode( 'visual' );
61
+ }
62
+ // Otherwise wait and retry later (animation ongoing)
63
+ else if ( ! this.is_tinymce_active() ) {
64
+ setTimeout(function() {
65
+ bstw( id ).activate_after_open();
66
+ }, 100 );
67
+ }
68
+ // If editor instance is already existing (i.e. dragged from another sidebar) just activate it
69
+ else {
70
+ this.set_mode( 'visual' );
71
+ }
72
+ }
73
+ return this;
74
+ },
75
+
76
+ // Activate editor deferred (after ajax requests)
77
+ activate_after_ajax: function () {
78
+ // Activate only if type is set to visual
79
+ if ( this.get_mode() === 'visual' ) {
80
+ // If textarea is visible and animation/ajax has completed then trigger a click to Visual button and enable the editor
81
+ if ( $.active === 0 && ! this.is_tinymce_active() && this.is_textearea_visible() ) {
82
+ this.set_mode( 'visual' );
83
+ }
84
+ // Otherwise wait and retry later (animation ongoing)
85
+ else if ( this.is_widget_inside_visible() && ! this.is_tinymce_active() ) {
86
+ setTimeout(function() {
87
+ bstw( id ).activate_after_ajax();
88
+ }, 100 );
89
+ }
90
+ }
91
+ return this;
92
+ },
93
+
94
+ // Get the div.widget jQuery object containing the instance
95
+ get_widget: function() {
96
+ return $( '#' + id ).closest( 'div.widget' );
97
+ },
98
+
99
+ // Get the div.widget-inside jQuery object containing the instance
100
+ get_widget_inside: function() {
101
+ return $( '#' + id ).closest( 'div.widget-inside' );
102
+ },
103
+
104
+ // Get the div.wp-editor-wrap jQuery object containing the instance
105
+ get_editor_wrap: function() {
106
+ return $( '#' + id ).closest( 'div.wp-editor-wrap' );
107
+ },
108
+
109
+ // Get the textarea jQuery object related to the instance
110
+ get_textarea: function() {
111
+ return $( '#' + id );
112
+ },
113
+
114
+ // Get the textarea ID related to the instance
115
+ get_id: function() {
116
+ return id;
117
+ },
118
+
119
+ // Get the tinymce instance related to the instance
120
+ get_tinymce: function() {
121
+ return tinymce.get( id );
122
+ },
123
+
124
+ // Get the current editor mode ( visual / html )
125
+ get_mode: function() {
126
+ return $( 'input[id^=widget-black-studio-tinymce][id$=type]', this.get_widget_inside() ).val();
127
+
128
+ },
129
+
130
+ // Set editor mode ( visual / html )
131
+ set_mode: function( value ) {
132
+ if ( value === 'visual' ) {
133
+ this.get_editor_wrap().removeClass( 'html-active' ).addClass( 'tmce-active' );
134
+ this.activate();
135
+ }
136
+ if ( value === 'html' ) {
137
+ this.get_editor_wrap().removeClass( 'tmce-active' ).addClass( 'html-active' );
138
+ this.deactivate();
139
+ }
140
+ $( 'input[id^=widget-black-studio-tinymce][id$=type]', this.get_widget_inside() ).val( value );
141
+ return this;
142
+ },
143
+
144
+ // Check if the connected tinymce instance is active
145
+ is_tinymce_active: function() {
146
+ return typeof tinymce === 'object' && typeof tinymce.get( id ) === 'object' && tinymce.get( id ) !== null;
147
+ },
148
+
149
+ // Check if the textarea is visible
150
+ is_textearea_visible: function() {
151
+ return $( '#' + id ).is( ':visible' );
152
+ },
153
+
154
+ // Check if the widget inside is visible
155
+ is_widget_inside_visible: function() {
156
+ return $( ' div.widget-inside:has(#' + id + ')' ).is( ':visible' );
157
+ },
158
+
159
+ // Check for widgets with duplicate ids
160
+ check_duplicates: function() {
161
+ if ( $( '[name="' + this.get_textarea().attr('name') + '"]' ).size() > 1) {
162
+ if ( $( 'div.error', this.get_widget_inside() ).length === 0 ) {
163
+ this.get_widget_inside().prepend('<div class="error"><strong>' + bstw_data.error_duplicate_id + '</strong></div>');
164
+ }
165
+ }
166
+ return this;
167
+ },
168
+
169
+ // Fix CSS
170
+ fix_css: function() {
171
+ this.get_widget().css( 'position', 'relative' ).css( 'z-index', '100000' ); // needed for small screens and for fullscreen mode
172
+ $( '#wpbody-content' ).css( 'overflow', 'visible' ); // needed for small screens
173
+ return this;
174
+ },
175
+
176
+ // Set target on media buttons
177
+ set_media_target: function() {
178
+ $( '.insert-media', this.get_widget() ).data( 'editor', id );
179
+ return this;
180
+ }
181
+ };
182
+ }
183
+
184
+ // Document ready stuff
185
+ $( document ).ready(function() {
186
+
187
+ // Event handler for widget open button
188
+ $( 'div.widget[id*=black-studio-tinymce] .widget-title, div.widget[id*=black-studio-tinymce] a.widget-action' ).live( 'click', function() {
189
+ bstw( $( this ) ).check_duplicates().fix_css().set_media_target().activate_after_open();
190
+ // Event handler for widget save button (for new instances)
191
+ // Note: this event handler is intentionally attached to the save button instead of document
192
+ // to let the the textarea content be updated before the ajax request is run
193
+ $( 'input[name=savewidget]', bstw( $( this ) ).get_widget() ).click(function() {
194
+ if ( bstw( $( this ) ).is_tinymce_active() ) {
195
+ bstw( $( this ) ).deactivate();
196
+ }
197
+ // Event handler for ajax complete
198
+ $( this ).unbind( 'ajaxSuccess' ).ajaxSuccess(function() {
199
+ bstw( $( this ) ).activate_after_ajax();
200
+ });
201
+ });
202
+ });
203
+
204
+ // Event handler for widget save button (for existing instances)
205
+ $( 'div.widget[id*=black-studio-tinymce] input[name=savewidget]' ).live( 'click', function() {
206
+ if ( bstw( $( this ) ).is_tinymce_active() ) {
207
+ bstw( $( this ) ).deactivate();
208
+ }
209
+ // Event handler for ajax complete
210
+ $( this ).unbind( 'ajaxSuccess' ).ajaxSuccess(function() {
211
+ bstw( $( this ) ).activate_after_ajax();
212
+ });
213
+ });
214
+
215
+ // Event handler for visual switch button
216
+ $( 'a[id^=widget-black-studio-tinymce][id$=tmce]' ).live( 'click', function() {
217
+ bstw( $( this ) ).set_mode( 'visual' );
218
+ });
219
+
220
+ // Event handler for html switch button
221
+ $( 'a[id^=widget-black-studio-tinymce][id$=html]' ).live( 'click', function() {
222
+ bstw( $( this ) ).set_mode( 'html' );
223
+ });
224
+
225
+ // Set wpActiveEditor variables used when adding media from media library dialog
226
+ $( '.wp-media-buttons a' ).live( 'click', function() {
227
+ edCanvas = bstw( $( this ) ).get_textarea().get();
228
+ wpActiveEditor = bstw( $( this ) ).get_id();
229
+ });
230
+
231
+ // Activate editor when in accessibility mode
232
+ if ( $( 'body.widgets_access' ).size() > 0 ) {
233
+ bstw( $( 'textarea[id^=widget-black-studio-tinymce]' ).attr( 'id' ) ).activate_after_open();
234
+ }
235
+
236
+ // Plugin links toggle behavior
237
+ $( '.bstw-links-icon' ).live( 'click', function( event ) {
238
+ event.preventDefault();
239
+ $( this ).closest( '.bstw-links' ).children( '.bstw-links-list' ).toggle();
240
+ });
241
+
242
+ });
243
+
244
+ })( jQuery ); // end self-invoked wrapper function
js/black-studio-tinymce-widget-pre33.min.js ADDED
@@ -0,0 +1,2 @@
 
 
1
+ /* Black Studio TinyMCE Widget - v2.0.0 */
2
+ !function(a){function b(c){var d=null;return"string"==typeof c?d=c:"object"==typeof c&&c instanceof jQuery&&(d=a("textarea[id^=widget-black-studio-tinymce]",c.closest(bstw_data.container_selectors)).attr("id")),{activate:function(){if(a("#"+d).addClass("mceEditor"),"object"==typeof tinymce&&"function"==typeof tinymce.execCommand){this.deactivate();try{tinymce.execCommand("mceAddControl",!1,d)}catch(b){window.alert(b)}}return this},deactivate:function(){if("object"==typeof tinymce&&"function"==typeof tinymce.execCommand&&this.is_tinymce_active()){var b=tinymce.get(d).getContent();tinymce.get(d).remove(),a("#"+d).val(b)}return this},activate_after_open:function(){return"visual"===this.get_mode()&&(0===a("div.widget:has(#"+d+") :animated").size()&&!this.is_tinymce_active()&&this.is_textearea_visible()?this.set_mode("visual"):this.is_tinymce_active()?this.set_mode("visual"):setTimeout(function(){b(d).activate_after_open()},100)),this},activate_after_ajax:function(){return"visual"===this.get_mode()&&(0===a.active&&!this.is_tinymce_active()&&this.is_textearea_visible()?this.set_mode("visual"):this.is_widget_inside_visible()&&!this.is_tinymce_active()&&setTimeout(function(){b(d).activate_after_ajax()},100)),this},get_widget:function(){return a("#"+d).closest("div.widget")},get_widget_inside:function(){return a("#"+d).closest("div.widget-inside")},get_editor_wrap:function(){return a("#"+d).closest("div.wp-editor-wrap")},get_textarea:function(){return a("#"+d)},get_id:function(){return d},get_tinymce:function(){return tinymce.get(d)},get_mode:function(){return a("input[id^=widget-black-studio-tinymce][id$=type]",this.get_widget_inside()).val()},set_mode:function(b){return"visual"===b&&(this.get_editor_wrap().removeClass("html-active").addClass("tmce-active"),this.activate()),"html"===b&&(this.get_editor_wrap().removeClass("tmce-active").addClass("html-active"),this.deactivate()),a("input[id^=widget-black-studio-tinymce][id$=type]",this.get_widget_inside()).val(b),this},is_tinymce_active:function(){return"object"==typeof tinymce&&"object"==typeof tinymce.get(d)&&null!==tinymce.get(d)},is_textearea_visible:function(){return a("#"+d).is(":visible")},is_widget_inside_visible:function(){return a(" div.widget-inside:has(#"+d+")").is(":visible")},check_duplicates:function(){return a('[name="'+this.get_textarea().attr("name")+'"]').size()>1&&0===a("div.error",this.get_widget_inside()).length&&this.get_widget_inside().prepend('<div class="error"><strong>'+bstw_data.error_duplicate_id+"</strong></div>"),this},fix_css:function(){return this.get_widget().css("position","relative").css("z-index","100000"),a("#wpbody-content").css("overflow","visible"),this},set_media_target:function(){return a(".insert-media",this.get_widget()).data("editor",d),this}}}a(document).ready(function(){a("div.widget[id*=black-studio-tinymce] .widget-title, div.widget[id*=black-studio-tinymce] a.widget-action").live("click",function(){b(a(this)).check_duplicates().fix_css().set_media_target().activate_after_open(),a("input[name=savewidget]",b(a(this)).get_widget()).click(function(){b(a(this)).is_tinymce_active()&&b(a(this)).deactivate(),a(this).unbind("ajaxSuccess").ajaxSuccess(function(){b(a(this)).activate_after_ajax()})})}),a("div.widget[id*=black-studio-tinymce] input[name=savewidget]").live("click",function(){b(a(this)).is_tinymce_active()&&b(a(this)).deactivate(),a(this).unbind("ajaxSuccess").ajaxSuccess(function(){b(a(this)).activate_after_ajax()})}),a("a[id^=widget-black-studio-tinymce][id$=tmce]").live("click",function(){b(a(this)).set_mode("visual")}),a("a[id^=widget-black-studio-tinymce][id$=html]").live("click",function(){b(a(this)).set_mode("html")}),a(".wp-media-buttons a").live("click",function(){edCanvas=b(a(this)).get_textarea().get(),wpActiveEditor=b(a(this)).get_id()}),a("body.widgets_access").size()>0&&b(a("textarea[id^=widget-black-studio-tinymce]").attr("id")).activate_after_open(),a(".bstw-links-icon").live("click",function(b){b.preventDefault(),a(this).closest(".bstw-links").children(".bstw-links-list").toggle()})})}(jQuery);
js/black-studio-tinymce-widget-pre39.js ADDED
@@ -0,0 +1,278 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* Black Studio TinyMCE Widget - JS */
2
+
3
+ /* global bstw_data, tinymce, tinyMCEPreInit, isRtl */
4
+
5
+ (function( $ ) {
6
+
7
+ // Returns bstw instance given the textarea ID or any jQuery object inside the widget object
8
+ function bstw( arg ) {
9
+
10
+ var id = null;
11
+
12
+ // ID initialization
13
+ if ( typeof arg === 'string' ) {
14
+ id = arg;
15
+ }
16
+ // jQuery object initialization
17
+ else if ( typeof arg === 'object' && arg instanceof jQuery ) {
18
+ id = $( 'textarea[id^=widget-black-studio-tinymce]', arg.closest( bstw_data.container_selectors ) ).attr( 'id' );
19
+ }
20
+
21
+ // Create and return instance
22
+ return {
23
+
24
+ // Activate visual editor
25
+ activate: function () {
26
+ $( '#' + id ).addClass( 'mceEditor' );
27
+ if ( typeof tinymce === 'object' && typeof tinymce.execCommand === 'function' ) {
28
+ this.deactivate();
29
+ tinyMCEPreInit.mceInit[id] = tinyMCEPreInit.mceInit['black-studio-tinymce-widget'];
30
+ tinyMCEPreInit.mceInit[id].selector = '#' + id;
31
+ try {
32
+ // Instantiate new TinyMCE editor
33
+ tinymce.init( tinymce.extend( {}, tinyMCEPreInit.mceInit['black-studio-tinymce-widget'], tinyMCEPreInit.mceInit[id] ) );
34
+ tinymce.execCommand( 'mceAddControl', false, id );
35
+ } catch( e ) {
36
+ window.alert( e );
37
+ }
38
+ // Real time preview (Theme customizer)
39
+ if ( this.is_tinymce_active() ) {
40
+ if ( typeof tinymce.get( id ).on === 'function' ) {
41
+ tinymce.get( id ).on( 'keyup change', function() {
42
+ var content = tinymce.get( id ).getContent();
43
+ $( '#' + id ).val( content ).change();
44
+ });
45
+ }
46
+ }
47
+ }
48
+ return this;
49
+ },
50
+
51
+ // Deactivate visual editor
52
+ deactivate: function() {
53
+ if ( typeof tinymce === 'object' && typeof tinymce.execCommand === 'function' ) {
54
+ if ( this.is_tinymce_active() ) {
55
+ var content = tinymce.get( id ).getContent();
56
+ // tinymce.execCommand('mceRemoveControl', false, id);
57
+ tinymce.get( id ).remove();
58
+ $( '#' + id ).val( content );
59
+ }
60
+ }
61
+ return this;
62
+ },
63
+
64
+ // Activate editor deferred (after widget opening)
65
+ activate_after_open: function() {
66
+ // Activate only if type is set to visual
67
+ if ( this.get_mode() === 'visual' ) {
68
+ // If textarea is visible and animation/ajax has completed (or in accessibility mode) then trigger a click to Visual button and enable the editor
69
+ if ( $('div.widget:has(#' + id + ') :animated' ).size() === 0 && ! this.is_tinymce_active() && this.is_textearea_visible() ) {
70
+ this.set_mode( 'visual' );
71
+ }
72
+ // Otherwise wait and retry later (animation ongoing)
73
+ else if ( ! this.is_tinymce_active() ) {
74
+ setTimeout(function() {
75
+ bstw( id ).activate_after_open();
76
+ }, 100 );
77
+ }
78
+ // If editor instance is already existing (i.e. dragged from another sidebar) just activate it
79
+ else {
80
+ this.set_mode( 'visual' );
81
+ }
82
+ }
83
+ return this;
84
+ },
85
+
86
+ // Activate editor deferred (after ajax requests)
87
+ activate_after_ajax: function () {
88
+ // Activate only if type is set to visual
89
+ if ( this.get_mode() === 'visual' ) {
90
+ // If textarea is visible and animation/ajax has completed then trigger a click to Visual button and enable the editor
91
+ if ( $.active === 0 && ! this.is_tinymce_active() && this.is_textearea_visible() ) {
92
+ this.set_mode( 'visual' );
93
+ }
94
+ // Otherwise wait and retry later (animation ongoing)
95
+ else if ( this.is_widget_inside_visible() && ! this.is_tinymce_active() ) {
96
+ setTimeout(function() {
97
+ bstw( id ).activate_after_ajax();
98
+ }, 100 );
99
+ }
100
+ }
101
+ return this;
102
+ },
103
+
104
+ // Get the div.widget jQuery object containing the instance
105
+ get_widget: function() {
106
+ return $( '#' + id ).closest( 'div.widget' );
107
+ },
108
+
109
+ // Get the div.widget-inside jQuery object containing the instance
110
+ get_widget_inside: function() {
111
+ return $( '#' + id ).closest( 'div.widget-inside' );
112
+ },
113
+
114
+ // Get the div.wp-editor-wrap jQuery object containing the instance
115
+ get_editor_wrap: function() {
116
+ return $( '#' + id ).closest( 'div.wp-editor-wrap' );
117
+ },
118
+
119
+ // Get the textarea jQuery object related to the instance
120
+ get_textarea: function() {
121
+ return $( '#' + id );
122
+ },
123
+
124
+ // Get the textarea ID related to the instance
125
+ get_id: function() {
126
+ return id;
127
+ },
128
+
129
+ // Get the tinymce instance related to the instance
130
+ get_tinymce: function() {
131
+ return tinymce.get( id );
132
+ },
133
+
134
+ // Get the current editor mode ( visual / html )
135
+ get_mode: function() {
136
+ return $( 'input[id^=widget-black-studio-tinymce][id$=type]', this.get_widget_inside() ).val();
137
+
138
+ },
139
+
140
+ // Set editor mode ( visual / html )
141
+ set_mode: function( value ) {
142
+ if ( value === 'visual' ) {
143
+ this.get_editor_wrap().removeClass( 'html-active' ).addClass( 'tmce-active' );
144
+ this.activate();
145
+ }
146
+ if ( value === 'html' ) {
147
+ this.get_editor_wrap().removeClass( 'tmce-active' ).addClass( 'html-active' );
148
+ this.deactivate();
149
+ }
150
+ $( 'input[id^=widget-black-studio-tinymce][id$=type]', this.get_widget_inside() ).val( value );
151
+ return this;
152
+ },
153
+
154
+ // Check if the connected tinymce instance is active
155
+ is_tinymce_active: function() {
156
+ return typeof tinymce === 'object' && typeof tinymce.get( id ) === 'object' && tinymce.get( id ) !== null;
157
+ },
158
+
159
+ // Check if the textarea is visible
160
+ is_textearea_visible: function() {
161
+ return $( '#' + id ).is( ':visible' );
162
+ },
163
+
164
+ // Check if the widget inside is visible
165
+ is_widget_inside_visible: function() {
166
+ return $( ' div.widget-inside:has(#' + id + ')' ).is( ':visible' );
167
+ },
168
+
169
+ // Check for widgets with duplicate ids
170
+ check_duplicates: function() {
171
+ if ( $( '[name="' + this.get_textarea().attr('name') + '"]' ).size() > 1) {
172
+ if ( $( 'div.error', this.get_widget_inside() ).length === 0 ) {
173
+ this.get_widget_inside().prepend('<div class="error"><strong>' + bstw_data.error_duplicate_id + '</strong></div>');
174
+ }
175
+ }
176
+ return this;
177
+ },
178
+
179
+ // Fix CSS
180
+ fix_css: function() {
181
+ this.get_widget().css( 'position', 'relative' ).css( 'z-index', '100000' ); // needed for small screens and for fullscreen mode
182
+ $( '#wpbody-content' ).css( 'overflow', 'visible' ); // needed for small screens
183
+ return this;
184
+ },
185
+
186
+ // Set target on media buttons
187
+ set_media_target: function() {
188
+ $( '.insert-media', this.get_widget() ).data( 'editor', id );
189
+ return this;
190
+ }
191
+ };
192
+ }
193
+
194
+ // Document ready stuff
195
+ $( document ).ready(function() {
196
+
197
+ // Event handler for widget open button
198
+ $( document ).on( 'click', 'div.widget[id*=black-studio-tinymce] .widget-title, div.widget[id*=black-studio-tinymce] a.widget-action', function() {
199
+ bstw( $( this ) ).check_duplicates().fix_css().set_media_target().activate_after_open();
200
+ // Event handler for widget save button (for new instances)
201
+ // Note: this event handler is intentionally attached to the save button instead of document
202
+ // to let the the textarea content be updated before the ajax request is run
203
+ $( 'input[name=savewidget]', bstw( $( this ) ).get_widget() ).on( 'click', function() {
204
+ if ( bstw( $( this ) ).is_tinymce_active() ) {
205
+ bstw( $( this ) ).deactivate();
206
+ }
207
+ // Event handler for ajax complete
208
+ $( this ).unbind( 'ajaxSuccess' ).ajaxSuccess(function() {
209
+ bstw( $( this ) ).activate_after_ajax();
210
+ });
211
+ });
212
+ // Responsive: adjust widget width if it can't fit into the screen
213
+ if ( ! $( this ).parents( '#available-widgets' ).length ) {
214
+ var target_width = parseInt( $( 'input[name=widget-width]', bstw( $( this ) ).get_widget() ).val(), 10 ),
215
+ window_width = $( window ).width(),
216
+ widget_width = bstw( $( this ) ).get_widget().parent().width(),
217
+ menu_width = parseInt( $( '#wpcontent' ).css( 'margin-left' ), 10 ),
218
+ isRTL = !! ( 'undefined' !== typeof isRtl && isRtl ),
219
+ margin;
220
+ if ( target_width + menu_width + 30 > window_width ) {
221
+ if ( bstw( $( this ) ).get_widget().closest( 'div.widget-liquid-right' ).length ) {
222
+ margin = isRTL ? 'margin-right' : 'margin-left';
223
+ } else {
224
+ margin = isRTL ? 'margin-left' : 'margin-right';
225
+ }
226
+ $( bstw( $( this ) ).get_widget() ).css( margin, ( widget_width - ( window_width - 30 - menu_width) ) + 'px' );
227
+ }
228
+ }
229
+ });
230
+
231
+ // Event handler for widget save button (for existing instances)
232
+ $( 'div.widget[id*=black-studio-tinymce] input[name=savewidget]' ).on( 'click', function() {
233
+ if ( bstw( $( this ) ).is_tinymce_active() ) {
234
+ bstw( $( this ) ).deactivate();
235
+ }
236
+ // Event handler for ajax complete
237
+ $( this ).unbind( 'ajaxSuccess' ).ajaxSuccess(function() {
238
+ bstw( $( this ) ).activate_after_ajax();
239
+ });
240
+ });
241
+
242
+ // Event handler for visual switch button
243
+ $( document ).on( 'click', 'a[id^=widget-black-studio-tinymce][id$=tmce]', function() {
244
+ bstw( $( this ) ).set_mode( 'visual' );
245
+ });
246
+
247
+ // Event handler for html switch button
248
+ $( document ).on( 'click', 'a[id^=widget-black-studio-tinymce][id$=html]', function() {
249
+ bstw( $( this ) ).set_mode( 'html' );
250
+ });
251
+
252
+ // Event handler for widget added (i.e. with Theme Customizer */
253
+ $( document ).on( 'widget-added', function( event, $widget ) {
254
+ if ( $widget.is( '[id*=black-studio-tinymce]' ) ) {
255
+ event.preventDefault();
256
+ bstw( $widget ).activate_after_open();
257
+ }
258
+ });
259
+
260
+ // Set window.wpActiveEditor variable used when adding media from media library dialog
261
+ $( document ).on( 'click', '.wp-media-buttons a', function() {
262
+ window.wpActiveEditor = bstw( $( this ) ).get_id();
263
+ });
264
+
265
+ // Activate editor when in accessibility mode
266
+ if ( $( 'body.widgets_access' ).size() > 0 ) {
267
+ bstw( $( 'textarea[id^=widget-black-studio-tinymce]' ).attr( 'id' ) ).activate_after_open();
268
+ }
269
+
270
+ // Plugin links toggle behavior
271
+ $( document ).on( 'click', '.bstw-links-icon', function( event ) {
272
+ event.preventDefault();
273
+ $( this ).closest( '.bstw-links' ).children( '.bstw-links-list' ).toggle();
274
+ });
275
+
276
+ });
277
+
278
+ })( jQuery ); // end self-invoked wrapper function
js/black-studio-tinymce-widget-pre39.min.js ADDED
@@ -0,0 +1,2 @@
 
 
1
+ /* Black Studio TinyMCE Widget - v2.0.0 */
2
+ !function(a){function b(c){var d=null;return"string"==typeof c?d=c:"object"==typeof c&&c instanceof jQuery&&(d=a("textarea[id^=widget-black-studio-tinymce]",c.closest(bstw_data.container_selectors)).attr("id")),{activate:function(){if(a("#"+d).addClass("mceEditor"),"object"==typeof tinymce&&"function"==typeof tinymce.execCommand){this.deactivate(),tinyMCEPreInit.mceInit[d]=tinyMCEPreInit.mceInit["black-studio-tinymce-widget"],tinyMCEPreInit.mceInit[d].selector="#"+d;try{tinymce.init(tinymce.extend({},tinyMCEPreInit.mceInit["black-studio-tinymce-widget"],tinyMCEPreInit.mceInit[d])),tinymce.execCommand("mceAddControl",!1,d)}catch(b){window.alert(b)}this.is_tinymce_active()&&"function"==typeof tinymce.get(d).on&&tinymce.get(d).on("keyup change",function(){var b=tinymce.get(d).getContent();a("#"+d).val(b).change()})}return this},deactivate:function(){if("object"==typeof tinymce&&"function"==typeof tinymce.execCommand&&this.is_tinymce_active()){var b=tinymce.get(d).getContent();tinymce.get(d).remove(),a("#"+d).val(b)}return this},activate_after_open:function(){return"visual"===this.get_mode()&&(0===a("div.widget:has(#"+d+") :animated").size()&&!this.is_tinymce_active()&&this.is_textearea_visible()?this.set_mode("visual"):this.is_tinymce_active()?this.set_mode("visual"):setTimeout(function(){b(d).activate_after_open()},100)),this},activate_after_ajax:function(){return"visual"===this.get_mode()&&(0===a.active&&!this.is_tinymce_active()&&this.is_textearea_visible()?this.set_mode("visual"):this.is_widget_inside_visible()&&!this.is_tinymce_active()&&setTimeout(function(){b(d).activate_after_ajax()},100)),this},get_widget:function(){return a("#"+d).closest("div.widget")},get_widget_inside:function(){return a("#"+d).closest("div.widget-inside")},get_editor_wrap:function(){return a("#"+d).closest("div.wp-editor-wrap")},get_textarea:function(){return a("#"+d)},get_id:function(){return d},get_tinymce:function(){return tinymce.get(d)},get_mode:function(){return a("input[id^=widget-black-studio-tinymce][id$=type]",this.get_widget_inside()).val()},set_mode:function(b){return"visual"===b&&(this.get_editor_wrap().removeClass("html-active").addClass("tmce-active"),this.activate()),"html"===b&&(this.get_editor_wrap().removeClass("tmce-active").addClass("html-active"),this.deactivate()),a("input[id^=widget-black-studio-tinymce][id$=type]",this.get_widget_inside()).val(b),this},is_tinymce_active:function(){return"object"==typeof tinymce&&"object"==typeof tinymce.get(d)&&null!==tinymce.get(d)},is_textearea_visible:function(){return a("#"+d).is(":visible")},is_widget_inside_visible:function(){return a(" div.widget-inside:has(#"+d+")").is(":visible")},check_duplicates:function(){return a('[name="'+this.get_textarea().attr("name")+'"]').size()>1&&0===a("div.error",this.get_widget_inside()).length&&this.get_widget_inside().prepend('<div class="error"><strong>'+bstw_data.error_duplicate_id+"</strong></div>"),this},fix_css:function(){return this.get_widget().css("position","relative").css("z-index","100000"),a("#wpbody-content").css("overflow","visible"),this},set_media_target:function(){return a(".insert-media",this.get_widget()).data("editor",d),this}}}a(document).ready(function(){a(document).on("click","div.widget[id*=black-studio-tinymce] .widget-title, div.widget[id*=black-studio-tinymce] a.widget-action",function(){if(b(a(this)).check_duplicates().fix_css().set_media_target().activate_after_open(),a("input[name=savewidget]",b(a(this)).get_widget()).on("click",function(){b(a(this)).is_tinymce_active()&&b(a(this)).deactivate(),a(this).unbind("ajaxSuccess").ajaxSuccess(function(){b(a(this)).activate_after_ajax()})}),!a(this).parents("#available-widgets").length){var c,d=parseInt(a("input[name=widget-width]",b(a(this)).get_widget()).val(),10),e=a(window).width(),f=b(a(this)).get_widget().parent().width(),g=parseInt(a("#wpcontent").css("margin-left"),10),h=!("undefined"==typeof isRtl||!isRtl);d+g+30>e&&(c=b(a(this)).get_widget().closest("div.widget-liquid-right").length?h?"margin-right":"margin-left":h?"margin-left":"margin-right",a(b(a(this)).get_widget()).css(c,f-(e-30-g)+"px"))}}),a("div.widget[id*=black-studio-tinymce] input[name=savewidget]").on("click",function(){b(a(this)).is_tinymce_active()&&b(a(this)).deactivate(),a(this).unbind("ajaxSuccess").ajaxSuccess(function(){b(a(this)).activate_after_ajax()})}),a(document).on("click","a[id^=widget-black-studio-tinymce][id$=tmce]",function(){b(a(this)).set_mode("visual")}),a(document).on("click","a[id^=widget-black-studio-tinymce][id$=html]",function(){b(a(this)).set_mode("html")}),a(document).on("widget-added",function(a,c){c.is("[id*=black-studio-tinymce]")&&(a.preventDefault(),b(c).activate_after_open())}),a(document).on("click",".wp-media-buttons a",function(){window.wpActiveEditor=b(a(this)).get_id()}),a("body.widgets_access").size()>0&&b(a("textarea[id^=widget-black-studio-tinymce]").attr("id")).activate_after_open(),a(document).on("click",".bstw-links-icon",function(b){b.preventDefault(),a(this).closest(".bstw-links").children(".bstw-links-list").toggle()})})}(jQuery);
js/black-studio-tinymce-widget.js ADDED
@@ -0,0 +1,311 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* Black Studio TinyMCE Widget - JS */
2
+
3
+ /* global bstw_data, tinymce, tinyMCEPreInit, QTags, quicktags, isRtl */
4
+
5
+ var bstw;
6
+
7
+ (function( $ ) {
8
+
9
+ // Return bstw instance given the textarea ID or any jQuery object inside the widget object
10
+ bstw = function( arg ) {
11
+
12
+ var id = null;
13
+
14
+ // ID initialization
15
+ if ( typeof arg === 'string' ) {
16
+ id = arg;
17
+ }
18
+ // jQuery object initialization
19
+ else if ( typeof arg === 'object' && arg instanceof jQuery ) {
20
+ id = $( 'textarea[id^=widget-black-studio-tinymce]', arg.closest( bstw_data.container_selectors ) ).attr( 'id' );
21
+ }
22
+
23
+ // Create and return instance
24
+ return {
25
+
26
+ // Activate editor
27
+ activate: function () {
28
+ if ( ! $( '#' + id ).hasClass( 'active' ) && ! $( '#' + id ).hasClass( 'activating' )) {
29
+ $( '#' + id ).addClass( 'activating' );
30
+ if ( ! this.is_quicktags_configured() ) {
31
+ tinyMCEPreInit.qtInit[id] = tinyMCEPreInit.qtInit['black-studio-tinymce-widget'];
32
+ tinyMCEPreInit.qtInit[id].id = id;
33
+ }
34
+ if ( ! this.is_quicktags_active() ) {
35
+ var prevInstances, newInstance;
36
+ prevInstances = QTags.instances;
37
+ QTags.instances = [];
38
+ quicktags( tinyMCEPreInit.qtInit[id] );
39
+ QTags._buttonsInit();
40
+ newInstance = QTags.instances[id];
41
+ QTags.instances = prevInstances;
42
+ QTags.instances[id] = newInstance;
43
+ }
44
+ if ( ! this.is_tinymce_configured() ) {
45
+ tinyMCEPreInit.mceInit[id] = tinyMCEPreInit.mceInit['black-studio-tinymce-widget'];
46
+ tinyMCEPreInit.mceInit[id].selector = '#' + id;
47
+ }
48
+ if ( ! this.is_tinymce_active() ) {
49
+ tinyMCEPreInit.mceInit[id].wpautop = true;
50
+ tinyMCEPreInit.mceInit[id].setup = function( ed ) {
51
+ // Real time preview (Theme customizer)
52
+ ed.on( 'keyup change', function() {
53
+ var content = window.switchEditors.pre_wpautop( ed.getContent() );
54
+ $( '#' + id ).val( content ).change();
55
+ });
56
+ $( '#' + id ).addClass( 'active' ).removeClass( 'activating' );
57
+ };
58
+ this.go();
59
+ //tinymce.init( tinyMCEPreInit.mceInit[id] );
60
+ } else {
61
+ $( '#' + id ).addClass( 'active' ).removeClass( 'activating' );
62
+ }
63
+ }
64
+ return this;
65
+ },
66
+
67
+ // Deactivate editor
68
+ deactivate: function() {
69
+ if ( ! $( '#' + id ).hasClass( 'activating' ) ) {
70
+ if ( this.is_tinymce_active() ) {
71
+ this.update_content();
72
+ tinymce.get( id ).remove();
73
+ }
74
+ if ( this.is_tinymce_configured() ) {
75
+ delete tinyMCEPreInit.mceInit[id];
76
+ }
77
+ if ( this.is_quicktags_active() ) {
78
+ $( '.quicktags-toolbar', this.get_widget_inside() ).remove();
79
+ delete QTags.instances[id];
80
+ }
81
+ if ( this.is_quicktags_configured() ) {
82
+ delete tinyMCEPreInit.qtInit[id];
83
+ }
84
+ $( '#' + id ).removeClass( 'active' );
85
+ }
86
+ return this;
87
+ },
88
+
89
+ // Update textarea content when in visual mode
90
+ update_content: function() {
91
+ if ( this.get_mode() === 'visual' ) {
92
+ this.get_textarea().val( window.switchEditors.pre_wpautop( tinymce.get( id ).getContent() ) );
93
+ } else {
94
+ tinymce.get( id ).setContent( window.switchEditors.wpautop( this.get_textarea().val() ) );
95
+ }
96
+ return this;
97
+ },
98
+
99
+ // Setup an editor mode
100
+ go: function( mode ) {
101
+ if ( 'undefined' === typeof mode) {
102
+ mode = this.get_mode();
103
+ }
104
+ window.switchEditors.go( id, 'visual' === mode ? 'tmce' : 'html' );
105
+ return this;
106
+ },
107
+
108
+ // Get the current editor mode ( visual / html ) from the input value
109
+ get_mode: function() {
110
+ return $( 'input[id^=widget-black-studio-tinymce][id$=type]', this.get_container() ).val();
111
+ },
112
+
113
+ // Set editor mode ( visual / html ) into the input value
114
+ set_mode: function( mode ) {
115
+ $( 'input[id^=widget-black-studio-tinymce][id$=type]', this.get_container() ).val( mode );
116
+ return this;
117
+ },
118
+
119
+ // Get the jQuery container object containing the instance
120
+ get_container: function() {
121
+ return $( '#' + id ).closest( bstw_data.container_selectors );
122
+ },
123
+
124
+ // Get the div.widget jQuery object containing the instance
125
+ get_widget: function() {
126
+ return $( '#' + id ).closest( 'div.widget' );
127
+ },
128
+
129
+ // Get the div.widget-inside jQuery object containing the instance
130
+ get_widget_inside: function() {
131
+ return $( '#' + id ).closest( 'div.widget-inside' );
132
+ },
133
+
134
+ // Get the textarea jQuery object related to the instance
135
+ get_textarea: function() {
136
+ return $( '#' + id );
137
+ },
138
+
139
+ is_tinymce_active: function() {
140
+ return 'object' === typeof tinymce && 'object' === typeof tinymce.get( id ) && null !== tinymce.get( id );
141
+ },
142
+
143
+ // Check if the tinymce instance is configured
144
+ is_tinymce_configured: function() {
145
+ return 'undefined' !== typeof tinyMCEPreInit.mceInit[id];
146
+ },
147
+
148
+ // Check if the quicktags instance is active
149
+ is_quicktags_active: function() {
150
+ return 'object' === typeof QTags.instances[id];
151
+ },
152
+
153
+ // Check if the quicktags instance is configured
154
+ is_quicktags_configured: function() {
155
+ return 'object' === typeof tinyMCEPreInit.qtInit[id];
156
+ },
157
+
158
+ // Checks and settings to run before opening the widget
159
+ prepare: function() {
160
+ // Check for widgets with duplicate ids
161
+ if ( $( '[name="' + this.get_textarea().attr('name') + '"]' ).size() > 1) {
162
+ if ( $( 'div.error', this.get_widget_inside() ).length === 0 ) {
163
+ this.get_widget_inside().prepend('<div class="error"><strong>' + bstw_data.error_duplicate_id + '</strong></div>');
164
+ }
165
+ }
166
+ // Fix CSS
167
+ this.get_widget().css( 'position', 'relative' ).css( 'z-index', '100000' ); // needed for small screens and for fullscreen mode
168
+ $( '#wpbody-content' ).css( 'overflow', 'visible' ); // needed for small screens
169
+ return this;
170
+ },
171
+
172
+ // Responsive: adjust widget width if it can't fit into the screen
173
+ responsive: function() {
174
+ if ( this.get_widget_inside().is( ':visible' ) ) {
175
+ var target_width = parseInt( $( 'input[name=widget-width]', this.get_widget() ).val(), 10 ),
176
+ window_width = $( window ).width(),
177
+ widget_width = this.get_widget().parent().width(),
178
+ menu_width = parseInt( $( '#wpcontent' ).css( 'margin-left' ), 10 ),
179
+ isRTL = !! ( 'undefined' !== typeof isRtl && isRtl ),
180
+ margin;
181
+ if ( target_width + menu_width + 30 > window_width ) {
182
+ if ( this.get_widget().closest( 'div.widget-liquid-right' ).length ) {
183
+ margin = isRTL ? 'margin-right' : 'margin-left';
184
+ } else {
185
+ margin = isRTL ? 'margin-left' : 'margin-right';
186
+ }
187
+ this.get_widget().css( margin, ( widget_width - ( window_width - 30 - menu_width) ) + 'px' );
188
+ }
189
+ }
190
+ return this;
191
+ }
192
+
193
+ };
194
+ };
195
+
196
+ // Document ready stuff
197
+ $( document ).ready(function() {
198
+
199
+ // Event handler for widget open button
200
+ $( document ).on( 'click', 'div.widget[id*=black-studio-tinymce] .widget-title, div.widget[id*=black-studio-tinymce] .widget-action', function() {
201
+ if ( ! $( this ).parents( '#available-widgets' ).length ) {
202
+ bstw( $( this ) ).prepare().responsive().activate();
203
+ // Note: the save event handler is intentionally attached to the save button instead of document
204
+ // to let the the textarea content be updated before the ajax request starts
205
+ $( 'input[name=savewidget]', bstw( $( this ) ).get_widget() ).on( 'click', function() {
206
+ bstw( $( this ) ).update_content();
207
+ });
208
+ }
209
+ });
210
+
211
+ // Event handler for widget added
212
+ $( document ).on( 'widget-added', function( event, $widget ) {
213
+ if ( $widget.is( '[id*=black-studio-tinymce]' ) ) {
214
+ event.preventDefault();
215
+ bstw( $widget ).activate();
216
+ }
217
+ });
218
+
219
+ // Event handler for widget updated
220
+ $( document ).on( 'widget-updated', function( event, $widget ) {
221
+ if ( $widget.is( '[id*=black-studio-tinymce]' ) ) {
222
+ event.preventDefault();
223
+ bstw( $widget ).deactivate().activate();
224
+ }
225
+ });
226
+
227
+ // Event handler for visual switch button
228
+ $( document ).on( 'click', 'a[id^=widget-black-studio-tinymce][id$=tmce]', function() {
229
+ bstw( $( this ) ).set_mode( 'visual' );
230
+ });
231
+
232
+ // Event handler for html switch button
233
+ $( document ).on( 'click', 'a[id^=widget-black-studio-tinymce][id$=html]', function() {
234
+ bstw( $( this ) ).set_mode( 'html' );
235
+ });
236
+
237
+ // Set active editor when clicking on media buttons
238
+ $( document ).on ( 'click.wp-editor', '.wp-editor-wrap', function() {
239
+ if ( this.id ) {
240
+ window.wpActiveEditor = this.id.slice( 3, -5 );
241
+ }
242
+ });
243
+
244
+ // Deactivate editor on drag & drop operations
245
+ $( document ).on( 'sortstart', function( event, ui ) {
246
+ var open_widgets_selectors = [
247
+ 'body.wp-customizer .expanded > div[id*=black-studio-tinymce].widget', // Theme Customizer
248
+ '.widget-liquid-right div[id*=black-studio-tinymce].widget' // Widgets page
249
+ ];
250
+ $( open_widgets_selectors.join( ', ') ).filter( ':has(.widget-inside:visible)' ).each(function() {
251
+ $( '.widget-title', this ).trigger( 'click' );
252
+ bstw( $( this ) ).deactivate();
253
+ });
254
+ if ( ui.item.is( '[id*=black-studio-tinymce]' ) ){
255
+ bstw( ui.item.find('textarea[id^=widget-black-studio-tinymce]' ) ).deactivate();
256
+ }
257
+ });
258
+ $( document ).on( 'sortstop', function( event, ui ) {
259
+ if ( ui.item.is( '[id*=black-studio-tinymce]' ) ){
260
+ bstw( ui.item.find('textarea[id^=widget-black-studio-tinymce]' ) ).activate();
261
+ }
262
+ });
263
+ $( document ).on( 'sortupdate', function( event, ui ) {
264
+ if ( event !== null && $( ui.item ).is( '.ui-draggable' ) ) {
265
+ return;
266
+ }
267
+ $( 'body' ).addClass( 'wait' );
268
+ setTimeout(function() {
269
+ $( 'textarea[id^=widget-black-studio-tinymce].active' ).each(function() {
270
+ bstw( $( this ) ).deactivate();
271
+ });
272
+ $( 'body' ).removeClass( 'wait' );
273
+ }, 500 );
274
+ });
275
+
276
+ // External events
277
+ if ( 'object' === typeof bstw_data.activate_events && bstw_data.activate_events.length > 0 ) {
278
+ $( document ).on( bstw_data.activate_events.join( ' ' ), function( event ) {
279
+ bstw( $( event.target ) ).activate();
280
+ });
281
+ }
282
+ if ( 'object' === typeof bstw_data.deactivate_events && bstw_data.deactivate_events.length > 0 ) {
283
+ $( document ).on( bstw_data.deactivate_events.join( ' ' ), function( event ) {
284
+ bstw( $( event.target ) ).deactivate();
285
+ });
286
+ }
287
+
288
+ // Event handler for window resize (needed for responsive behavior)
289
+ $( window ).resize(function() {
290
+ $( 'textarea[id^=widget-black-studio-tinymce]' ).each(function() {
291
+ bstw( $( this ) ).responsive();
292
+ });
293
+ });
294
+
295
+ // Activate editor when in accessibility mode
296
+ if ( $( 'body.widgets_access' ).size() > 0 ) {
297
+ bstw( $( 'textarea[id^=widget-black-studio-tinymce]' ).attr( 'id' ) ).activate();
298
+ }
299
+
300
+ // Deactivate editor on hidden base instance
301
+ bstw( 'widget-black-studio-tinymce-__i__-text' ).deactivate();
302
+
303
+ // Plugin links toggle behavior
304
+ $( document ).on( 'click', '.bstw-links-icon', function( event ) {
305
+ event.preventDefault();
306
+ $( this ).closest( '.bstw-links' ).children( '.bstw-links-list' ).toggle();
307
+ });
308
+
309
+ });
310
+
311
+ })( jQuery ); // end self-invoked wrapper function
js/black-studio-tinymce-widget.min.js ADDED
@@ -0,0 +1,2 @@
 
 
1
+ /* Black Studio TinyMCE Widget - v2.0.0 */
2
+ var bstw;!function(a){bstw=function(b){var c=null;return"string"==typeof b?c=b:"object"==typeof b&&b instanceof jQuery&&(c=a("textarea[id^=widget-black-studio-tinymce]",b.closest(bstw_data.container_selectors)).attr("id")),{activate:function(){if(!a("#"+c).hasClass("active")&&!a("#"+c).hasClass("activating")){if(a("#"+c).addClass("activating"),this.is_quicktags_configured()||(tinyMCEPreInit.qtInit[c]=tinyMCEPreInit.qtInit["black-studio-tinymce-widget"],tinyMCEPreInit.qtInit[c].id=c),!this.is_quicktags_active()){var b,d;b=QTags.instances,QTags.instances=[],quicktags(tinyMCEPreInit.qtInit[c]),QTags._buttonsInit(),d=QTags.instances[c],QTags.instances=b,QTags.instances[c]=d}this.is_tinymce_configured()||(tinyMCEPreInit.mceInit[c]=tinyMCEPreInit.mceInit["black-studio-tinymce-widget"],tinyMCEPreInit.mceInit[c].selector="#"+c),this.is_tinymce_active()?a("#"+c).addClass("active").removeClass("activating"):(tinyMCEPreInit.mceInit[c].wpautop=!0,tinyMCEPreInit.mceInit[c].setup=function(b){b.on("keyup change",function(){var d=window.switchEditors.pre_wpautop(b.getContent());a("#"+c).val(d).change()}),a("#"+c).addClass("active").removeClass("activating")},this.go())}return this},deactivate:function(){return a("#"+c).hasClass("activating")||(this.is_tinymce_active()&&(this.update_content(),tinymce.get(c).remove()),this.is_tinymce_configured()&&delete tinyMCEPreInit.mceInit[c],this.is_quicktags_active()&&(a(".quicktags-toolbar",this.get_widget_inside()).remove(),delete QTags.instances[c]),this.is_quicktags_configured()&&delete tinyMCEPreInit.qtInit[c],a("#"+c).removeClass("active")),this},update_content:function(){return"visual"===this.get_mode()?this.get_textarea().val(window.switchEditors.pre_wpautop(tinymce.get(c).getContent())):tinymce.get(c).setContent(window.switchEditors.wpautop(this.get_textarea().val())),this},go:function(a){return"undefined"==typeof a&&(a=this.get_mode()),window.switchEditors.go(c,"visual"===a?"tmce":"html"),this},get_mode:function(){return a("input[id^=widget-black-studio-tinymce][id$=type]",this.get_container()).val()},set_mode:function(b){return a("input[id^=widget-black-studio-tinymce][id$=type]",this.get_container()).val(b),this},get_container:function(){return a("#"+c).closest(bstw_data.container_selectors)},get_widget:function(){return a("#"+c).closest("div.widget")},get_widget_inside:function(){return a("#"+c).closest("div.widget-inside")},get_textarea:function(){return a("#"+c)},is_tinymce_active:function(){return"object"==typeof tinymce&&"object"==typeof tinymce.get(c)&&null!==tinymce.get(c)},is_tinymce_configured:function(){return"undefined"!=typeof tinyMCEPreInit.mceInit[c]},is_quicktags_active:function(){return"object"==typeof QTags.instances[c]},is_quicktags_configured:function(){return"object"==typeof tinyMCEPreInit.qtInit[c]},prepare:function(){return a('[name="'+this.get_textarea().attr("name")+'"]').size()>1&&0===a("div.error",this.get_widget_inside()).length&&this.get_widget_inside().prepend('<div class="error"><strong>'+bstw_data.error_duplicate_id+"</strong></div>"),this.get_widget().css("position","relative").css("z-index","100000"),a("#wpbody-content").css("overflow","visible"),this},responsive:function(){if(this.get_widget_inside().is(":visible")){var b,c=parseInt(a("input[name=widget-width]",this.get_widget()).val(),10),d=a(window).width(),e=this.get_widget().parent().width(),f=parseInt(a("#wpcontent").css("margin-left"),10),g=!("undefined"==typeof isRtl||!isRtl);c+f+30>d&&(b=this.get_widget().closest("div.widget-liquid-right").length?g?"margin-right":"margin-left":g?"margin-left":"margin-right",this.get_widget().css(b,e-(d-30-f)+"px"))}return this}}},a(document).ready(function(){a(document).on("click","div.widget[id*=black-studio-tinymce] .widget-title, div.widget[id*=black-studio-tinymce] .widget-action",function(){a(this).parents("#available-widgets").length||(bstw(a(this)).prepare().responsive().activate(),a("input[name=savewidget]",bstw(a(this)).get_widget()).on("click",function(){bstw(a(this)).update_content()}))}),a(document).on("widget-added",function(a,b){b.is("[id*=black-studio-tinymce]")&&(a.preventDefault(),bstw(b).activate())}),a(document).on("widget-updated",function(a,b){b.is("[id*=black-studio-tinymce]")&&(a.preventDefault(),bstw(b).deactivate().activate())}),a(document).on("click","a[id^=widget-black-studio-tinymce][id$=tmce]",function(){bstw(a(this)).set_mode("visual")}),a(document).on("click","a[id^=widget-black-studio-tinymce][id$=html]",function(){bstw(a(this)).set_mode("html")}),a(document).on("click.wp-editor",".wp-editor-wrap",function(){this.id&&(window.wpActiveEditor=this.id.slice(3,-5))}),a(document).on("sortstart",function(b,c){var d=["body.wp-customizer .expanded > div[id*=black-studio-tinymce].widget",".widget-liquid-right div[id*=black-studio-tinymce].widget"];a(d.join(", ")).filter(":has(.widget-inside:visible)").each(function(){a(".widget-title",this).trigger("click"),bstw(a(this)).deactivate()}),c.item.is("[id*=black-studio-tinymce]")&&bstw(c.item.find("textarea[id^=widget-black-studio-tinymce]")).deactivate()}),a(document).on("sortstop",function(a,b){b.item.is("[id*=black-studio-tinymce]")&&bstw(b.item.find("textarea[id^=widget-black-studio-tinymce]")).activate()}),a(document).on("sortupdate",function(b,c){null!==b&&a(c.item).is(".ui-draggable")||(a("body").addClass("wait"),setTimeout(function(){a("textarea[id^=widget-black-studio-tinymce].active").each(function(){bstw(a(this)).deactivate()}),a("body").removeClass("wait")},500))}),"object"==typeof bstw_data.activate_events&&bstw_data.activate_events.length>0&&a(document).on(bstw_data.activate_events.join(" "),function(b){bstw(a(b.target)).activate()}),"object"==typeof bstw_data.deactivate_events&&bstw_data.deactivate_events.length>0&&a(document).on(bstw_data.deactivate_events.join(" "),function(b){bstw(a(b.target)).deactivate()}),a(window).resize(function(){a("textarea[id^=widget-black-studio-tinymce]").each(function(){bstw(a(this)).responsive()})}),a("body.widgets_access").size()>0&&bstw(a("textarea[id^=widget-black-studio-tinymce]").attr("id")).activate(),bstw("widget-black-studio-tinymce-__i__-text").deactivate(),a(document).on("click",".bstw-links-icon",function(b){b.preventDefault(),a(this).closest(".bstw-links").children(".bstw-links-list").toggle()})})}(jQuery);
js/wp-page-widget.js ADDED
@@ -0,0 +1,27 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* Black Studio TinyMCE Widget - Compatibility with WP Page Widget plugin */
2
+
3
+ /* global bstw */
4
+
5
+ (function( $ ) {
6
+
7
+ $( document ).ready(function() {
8
+
9
+ // Event handler for widget save button
10
+ $( document ).on( 'click', '#pw-sidebars-customize div[id*=black-studio-tinymce].widget input.widget-control-save', function() {
11
+ $( this ).unbind( 'ajaxSuccess' ).ajaxSuccess(function( ) {
12
+ $( this ).trigger( 'widget-updated', [ bstw( $( this ) ).get_widget() ] ).unbind( 'ajaxSuccess' );
13
+ });
14
+ });
15
+
16
+ // Event handler for widget open button
17
+ $( document ).on( 'click', '#pw-sidebars-customize div[id*=black-studio-tinymce].widget .widget-title', function() {
18
+ var $textarea = bstw( $( this ) ).get_textarea();
19
+ if ( $textarea.hasClass( 'active' ) ) {
20
+ bstw( $( this ) ).deactivate();
21
+ $( this ).trigger( 'widget-added', [ bstw( $( this ) ).get_widget() ] );
22
+ }
23
+ });
24
+
25
+ });
26
+
27
+ })( jQuery ); // end self-invoked wrapper function
js/wp-page-widget.min.js ADDED
@@ -0,0 +1,2 @@
 
 
1
+ /* Black Studio TinyMCE Widget - v2.0.0 */
2
+ !function(a){a(document).ready(function(){a(document).on("click","#pw-sidebars-customize div[id*=black-studio-tinymce].widget input.widget-control-save",function(){a(this).unbind("ajaxSuccess").ajaxSuccess(function(){a(this).trigger("widget-updated",[bstw(a(this)).get_widget()]).unbind("ajaxSuccess")})}),a(document).on("click","#pw-sidebars-customize div[id*=black-studio-tinymce].widget .widget-title",function(){var b=bstw(a(this)).get_textarea();b.hasClass("active")&&(bstw(a(this)).deactivate(),a(this).trigger("widget-added",[bstw(a(this)).get_widget()]))})})}(jQuery);
languages/black-studio-tinymce-widget-ca.mo ADDED
Binary file
languages/black-studio-tinymce-widget-ca.po ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
+ msgid ""
6
+ msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Catalan (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/ca/)\n"
13
+ "MIME-Version: 1.0\n"
14
+ "Content-Type: text/plain; charset=UTF-8\n"
15
+ "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: ca\n"
17
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
+
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr ""
34
+
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Pàgina d'inici"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "PMF"
44
+
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr ""
49
+
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Puntuació"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr "Segueix"
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "Fes un donatiu"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Editor visual"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr ""
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-da_DK.mo CHANGED
Binary file
languages/black-studio-tinymce-widget-da_DK.po CHANGED
@@ -1,38 +1,84 @@
 
 
 
 
1
  msgid ""
2
  msgstr ""
3
  "Project-Id-Version: Black Studio TinyMCE Widget\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2014-03-06 12:08+0100\n"
6
- "PO-Revision-Date: 2014-07-08 22:01+0100\n"
7
- "Last-Translator: Mikkel Rommelhoff <mr@rommel.dk>\n"
8
- "Language-Team: Rommel <mr@rommel.dk>\n"
9
- "Language: da_DK\n"
10
  "MIME-Version: 1.0\n"
11
  "Content-Type: text/plain; charset=UTF-8\n"
12
  "Content-Transfer-Encoding: 8bit\n"
13
- "X-Poedit-KeywordsList: _;gettext;gettext_noop;__\n"
14
- "X-Poedit-Basepath: ..\n"
15
- "X-Poedit-SourceCharset: UTF-8\n"
16
- "X-Generator: Poedit 1.6.6\n"
17
  "Plural-Forms: nplurals=2; plural=(n != 1);\n"
 
 
 
 
 
 
18
  "X-Poedit-SearchPath-0: .\n"
 
 
19
 
20
- #: black-studio-tinymce-widget.php:21
21
- msgid "Arbitrary text or HTML with visual editor"
22
- msgstr "Widget med teksteditor eller HTML"
 
 
 
23
 
24
- #: black-studio-tinymce-widget.php:23
25
- msgid "Visual Editor"
26
- msgstr "Teksteditor"
 
27
 
28
- #: black-studio-tinymce-widget.php:99
29
- msgid "Donate"
30
- msgstr "Doner"
 
31
 
32
- #: black-studio-tinymce-widget.php:99
 
33
  msgid "Support"
34
  msgstr "Support"
35
 
36
- #: black-studio-tinymce-widget.php:99
 
 
 
 
 
 
37
  msgid "Follow"
38
  msgstr "Følg"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
  msgid ""
6
  msgstr ""
7
  "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Danish (Denmark) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/da_DK/)\n"
 
13
  "MIME-Version: 1.0\n"
14
  "Content-Type: text/plain; charset=UTF-8\n"
15
  "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: da_DK\n"
 
 
 
17
  "Plural-Forms: nplurals=2; plural=(n != 1);\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
  "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
 
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr ""
34
 
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Forside"
39
 
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "FAQ"
44
 
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
  msgid "Support"
48
  msgstr "Support"
49
 
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Rate"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
  msgid "Follow"
58
  msgstr "Følg"
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "Doner"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Teksteditor"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr "Widget med teksteditor eller HTML"
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-de_DE.mo CHANGED
Binary file
languages/black-studio-tinymce-widget-de_DE.po CHANGED
@@ -1,39 +1,84 @@
1
- # Translation of Black Studio TinyMCE Widget in German
2
- # This file is distributed under the same license as the Black Studio TinyMCE Widget package.
 
 
3
  msgid ""
4
  msgstr ""
5
- "PO-Revision-Date: 2012-10-03 09:57:33+0000\n"
 
 
 
 
 
6
  "MIME-Version: 1.0\n"
7
  "Content-Type: text/plain; charset=UTF-8\n"
8
  "Content-Transfer-Encoding: 8bit\n"
9
- "Plural-Forms: nplurals=2; plural=n != 1;\n"
10
- "X-Generator: GlotPress/0.1\n"
11
- "Project-Id-Version: Black Studio TinyMCE Widget\n"
 
 
 
 
 
 
 
 
12
 
13
- #: black-studio-tinymce-widget.php:70
14
- msgid "HTML"
15
- msgstr "HTML"
 
 
 
16
 
17
- #: black-studio-tinymce-widget.php:71
18
- msgid "Visual"
19
- msgstr "Visual"
 
20
 
21
- #: black-studio-tinymce-widget.php:79
22
- msgid "Donate"
23
- msgstr "Spende"
 
24
 
25
- #: black-studio-tinymce-widget.php:79
 
26
  msgid "Support"
27
  msgstr "Support"
28
 
29
- #: black-studio-tinymce-widget.php:79
 
 
 
 
 
 
30
  msgid "Follow"
31
  msgstr "Folgen"
32
 
33
- #: black-studio-tinymce-widget.php:19
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
34
  msgid "Arbitrary text or HTML with visual editor"
35
  msgstr "Normaler Text oder HTML mit Editor"
36
 
37
- #: black-studio-tinymce-widget.php:21
38
- msgid "Black Studio TinyMCE"
39
- msgstr "Black Studio TinyMCE"
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
  msgid ""
6
  msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: German (Germany) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/de_DE/)\n"
13
  "MIME-Version: 1.0\n"
14
  "Content-Type: text/plain; charset=UTF-8\n"
15
  "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: de_DE\n"
17
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
 
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr "FEHLER: Doppelte Widget-ID gefunden. Um den Verlust von Daten zu verhindern, erstelle ein neues Widget mit dem gleichen Inhalt und lösche das Aktuelle."
34
 
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Home"
39
 
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "FAQ"
44
 
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
  msgid "Support"
48
  msgstr "Support"
49
 
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Bewerten"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
  msgid "Follow"
58
  msgstr "Folgen"
59
 
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "Spende"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Visual Editor"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
  msgid "Arbitrary text or HTML with visual editor"
78
  msgstr "Normaler Text oder HTML mit Editor"
79
 
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-el.mo ADDED
Binary file
languages/black-studio-tinymce-widget-el.po ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # evigiannakou <evigian@in.gr>, 2014
5
+ msgid ""
6
+ msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Greek (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/el/)\n"
13
+ "MIME-Version: 1.0\n"
14
+ "Content-Type: text/plain; charset=UTF-8\n"
15
+ "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: el\n"
17
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
+
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr "ΣΦΑΛΜΑ: Ανιχνεύθηκε ID διπλής μονάδας. Για να αποφύγετε την απώλεια περιεχομένου, παρακαλώ δημιουργήστε μια νέα μονάδα με το ίδιο περιεχόμενο και έπειτα διαγράψτε αυτή."
34
+
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Αρχική"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "Κοινές απορίες"
44
+
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr "Υποστήριξη"
49
+
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Αξιολόγηση"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr "Ακολουθήστε"
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "Δωρεά"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Επεξεργαστής"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr "Τυχαίο κείμενο ή HTML με επεξεργαστή"
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-en_GB.mo ADDED
Binary file
languages/black-studio-tinymce-widget-en_GB.po ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
+ msgid ""
6
+ msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-06 00:00+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: English (United Kingdom) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/en_GB/)\n"
13
+ "MIME-Version: 1.0\n"
14
+ "Content-Type: text/plain; charset=UTF-8\n"
15
+ "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: en_GB\n"
17
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
+
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr "ERROR: Duplicate widget ID detected. To avoid content loss, please create a new widget with the same content and then delete this one."
34
+
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Home"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "FAQ"
44
+
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr "Support"
49
+
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Rate"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr "Follow"
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "Donate"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr "About Black Studio TinyMCE Widget plugin"
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Visual Editor"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr "Arbitrary text or HTML with visual editor"
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr "Adds a new \"Visual Editor\" widget type based on the native WordPress TinyMCE editor."
languages/black-studio-tinymce-widget-es_ES.mo CHANGED
Binary file
languages/black-studio-tinymce-widget-es_ES.po CHANGED
@@ -1,57 +1,85 @@
 
 
 
 
 
1
  msgid ""
2
  msgstr ""
3
  "Project-Id-Version: Black Studio TinyMCE Widget\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2012-07-31 10:19+0100\n"
6
- "PO-Revision-Date: 2012-07-31 10:22+0100\n"
7
- "Last-Translator: Marco <marco@blackstudio.it>\n"
8
- "Language-Team: Black Studio <info@blackstudio.it>\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
- "Plural-Forms: nplurals=2; plural=n != 1;\n"
13
- "X-Poedit-Language: Italian\n"
14
- "X-Poedit-Country: ITALY\n"
 
 
 
 
 
 
15
  "X-Poedit-SourceCharset: utf-8\n"
16
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2\n"
17
- "X-Poedit-Basepath: ..\n"
18
  "X-Textdomain-Support: yes\n"
19
- "X-Poedit-SearchPath-0: .\n"
20
 
21
- # @ black-studio-tinymce-widget
22
- #: black-studio-tinymce-widget.php:19
23
- msgid "Arbitrary text or HTML with visual editor"
24
- msgstr "Texto arbitrario o HTML con un editor visual"
 
 
25
 
26
- # @ black-studio-tinymce-widget
27
- #: black-studio-tinymce-widget.php:21
28
- msgid "Black Studio TinyMCE"
29
- msgstr "Black Studio TinyMCE"
30
 
31
- # @ default
32
- #: black-studio-tinymce-widget.php:67
33
- msgid "Title:"
34
- msgstr "Título:"
35
 
36
- # @ default
37
- #: black-studio-tinymce-widget.php:70
38
- msgid "HTML"
39
- msgstr "HTML"
 
 
 
 
 
40
 
41
- # @ default
42
- #: black-studio-tinymce-widget.php:71
43
- msgid "Visual"
44
- msgstr "Visual"
45
 
46
- #: black-studio-tinymce-widget.php:79
 
47
  msgid "Donate"
48
  msgstr "Donación"
49
 
50
- #: black-studio-tinymce-widget.php:79
51
- msgid "Support"
52
- msgstr "Soporte"
 
53
 
54
- #: black-studio-tinymce-widget.php:79
55
- msgid "Follow"
56
- msgstr "Seguir"
 
57
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # genethic <lauramoreno1436@gmail.com>, 2014
5
+ # marcochiesi <marco@blackstudio.it>, 2014
6
  msgid ""
7
  msgstr ""
8
  "Project-Id-Version: Black Studio TinyMCE Widget\n"
9
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
10
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
11
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
12
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
13
+ "Language-Team: Spanish (Spain) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/es_ES/)\n"
14
  "MIME-Version: 1.0\n"
15
  "Content-Type: text/plain; charset=UTF-8\n"
16
  "Content-Transfer-Encoding: 8bit\n"
17
+ "Language: es_ES\n"
18
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
19
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
20
+ "X-Poedit-Basepath: .\n"
21
+ "X-Poedit-Bookmarks: \n"
22
+ "X-Poedit-Country: United States\n"
23
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
24
+ "X-Poedit-Language: English\n"
25
+ "X-Poedit-SearchPath-0: .\n"
26
  "X-Poedit-SourceCharset: utf-8\n"
 
 
27
  "X-Textdomain-Support: yes\n"
 
28
 
29
+ #. translators: error message shown when a duplicated widget ID is detected
30
+ #: includes/class-admin.php:245
31
+ msgid ""
32
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
33
+ "new widget with the same content and then delete this one."
34
+ msgstr "Error: Detectado ID de widget duplicado. Para evitar la pérdida de contenido, por favor cree un nuevo widget con el mismo contenido y borre este."
35
 
36
+ #. translators: text used for plugin home link
37
+ #: includes/class-admin.php:319
38
+ msgid "Home"
39
+ msgstr "INICIO"
40
 
41
+ #. translators: text used for support faq link
42
+ #: includes/class-admin.php:321
43
+ msgid "FAQ"
44
+ msgstr "FAQ"
45
 
46
+ #. translators: text used for support forum link
47
+ #: includes/class-admin.php:323
48
+ msgid "Support"
49
+ msgstr "Soporte"
50
+
51
+ #. translators: text used for reviews link
52
+ #: includes/class-admin.php:325
53
+ msgid "Rate"
54
+ msgstr "Puntuar"
55
 
56
+ #. translators: text used for follow on twitter link
57
+ #: includes/class-admin.php:327
58
+ msgid "Follow"
59
+ msgstr "Seguir"
60
 
61
+ #. translators: text used for donation link
62
+ #: includes/class-admin.php:329
63
  msgid "Donate"
64
  msgstr "Donación"
65
 
66
+ #. translators: text used for the icon that shows the plugin links
67
+ #: includes/class-admin.php:349
68
+ msgid "About Black Studio TinyMCE Widget plugin"
69
+ msgstr ""
70
 
71
+ #. translators: title of the widget
72
+ #: includes/class-widget.php:28
73
+ msgid "Visual Editor"
74
+ msgstr "Editor visual"
75
 
76
+ #. translators: description of the widget, shown in available widgets
77
+ #: includes/class-widget.php:30
78
+ msgid "Arbitrary text or HTML with visual editor"
79
+ msgstr "Texto arbitrario o HTML con un editor visual"
80
+
81
+ #. Description of the plugin/theme
82
+ msgid ""
83
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
84
+ "TinyMCE editor."
85
+ msgstr ""
languages/black-studio-tinymce-widget-fi.mo ADDED
Binary file
languages/black-studio-tinymce-widget-fi.po ADDED
@@ -0,0 +1,85 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
+ # Sami Keijonen <sami.keijonen@foxnet.fi>, 2014
6
+ msgid ""
7
+ msgstr ""
8
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
9
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
10
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
11
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
12
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
13
+ "Language-Team: Finnish (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/fi/)\n"
14
+ "MIME-Version: 1.0\n"
15
+ "Content-Type: text/plain; charset=UTF-8\n"
16
+ "Content-Transfer-Encoding: 8bit\n"
17
+ "Language: fi\n"
18
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
19
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
20
+ "X-Poedit-Basepath: .\n"
21
+ "X-Poedit-Bookmarks: \n"
22
+ "X-Poedit-Country: United States\n"
23
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
24
+ "X-Poedit-Language: English\n"
25
+ "X-Poedit-SearchPath-0: .\n"
26
+ "X-Poedit-SourceCharset: utf-8\n"
27
+ "X-Textdomain-Support: yes\n"
28
+
29
+ #. translators: error message shown when a duplicated widget ID is detected
30
+ #: includes/class-admin.php:245
31
+ msgid ""
32
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
33
+ "new widget with the same content and then delete this one."
34
+ msgstr "Virhe: Samalla ID:llä löytyi toinen vimpain. Tee samalla sisällöllä toinen vimpain ja poista tämä."
35
+
36
+ #. translators: text used for plugin home link
37
+ #: includes/class-admin.php:319
38
+ msgid "Home"
39
+ msgstr "Etusivu"
40
+
41
+ #. translators: text used for support faq link
42
+ #: includes/class-admin.php:321
43
+ msgid "FAQ"
44
+ msgstr "UKK"
45
+
46
+ #. translators: text used for support forum link
47
+ #: includes/class-admin.php:323
48
+ msgid "Support"
49
+ msgstr "Tuki"
50
+
51
+ #. translators: text used for reviews link
52
+ #: includes/class-admin.php:325
53
+ msgid "Rate"
54
+ msgstr "Arvostele"
55
+
56
+ #. translators: text used for follow on twitter link
57
+ #: includes/class-admin.php:327
58
+ msgid "Follow"
59
+ msgstr "Seuraa"
60
+
61
+ #. translators: text used for donation link
62
+ #: includes/class-admin.php:329
63
+ msgid "Donate"
64
+ msgstr "Lahjoita"
65
+
66
+ #. translators: text used for the icon that shows the plugin links
67
+ #: includes/class-admin.php:349
68
+ msgid "About Black Studio TinyMCE Widget plugin"
69
+ msgstr ""
70
+
71
+ #. translators: title of the widget
72
+ #: includes/class-widget.php:28
73
+ msgid "Visual Editor"
74
+ msgstr "Editori"
75
+
76
+ #. translators: description of the widget, shown in available widgets
77
+ #: includes/class-widget.php:30
78
+ msgid "Arbitrary text or HTML with visual editor"
79
+ msgstr "Lisää sisältöä visuaalisella editorilla"
80
+
81
+ #. Description of the plugin/theme
82
+ msgid ""
83
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
84
+ "TinyMCE editor."
85
+ msgstr ""
languages/black-studio-tinymce-widget-fi_FI.mo DELETED
Binary file
languages/black-studio-tinymce-widget-fi_FI.po DELETED
@@ -1,37 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Black Studio TinyMCE Widget\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2012-07-31 10:19+0100\n"
6
- "PO-Revision-Date: 2013-07-23 22:34+0200\n"
7
- "Last-Translator: Marco <marco@blackstudio.it>\n"
8
- "Language-Team: Timo Leiniö <timo@wpopas.fi>\n"
9
- "MIME-Version: 1.0\n"
10
- "Content-Type: text/plain; charset=UTF-8\n"
11
- "Content-Transfer-Encoding: 8bit\n"
12
- "X-Poedit-KeywordsList: _;gettext;gettext_noop;__\n"
13
- "X-Poedit-Basepath: ..\n"
14
- "X-Poedit-SourceCharset: UTF-8\n"
15
- "Language: fi\n"
16
- "X-Generator: Poedit 1.5.7\n"
17
- "X-Poedit-SearchPath-0: .\n"
18
-
19
- #: black-studio-tinymce-widget.php:19
20
- msgid "Arbitrary text or HTML with visual editor"
21
- msgstr "Lisää sisältöä visuaalisella editorilla"
22
-
23
- #: black-studio-tinymce-widget.php:21
24
- msgid "Black Studio TinyMCE"
25
- msgstr "Black Studio TinyMCE"
26
-
27
- #: black-studio-tinymce-widget.php:79
28
- msgid "Donate"
29
- msgstr "Lahjoita"
30
-
31
- #: black-studio-tinymce-widget.php:79
32
- msgid "Support"
33
- msgstr "Tue"
34
-
35
- #: black-studio-tinymce-widget.php:79
36
- msgid "Follow"
37
- msgstr "Seuraa"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/black-studio-tinymce-widget-fr_FR.mo ADDED
Binary file
languages/black-studio-tinymce-widget-fr_FR.po ADDED
@@ -0,0 +1,85 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # FxB <fxb@wp-translations.org>, 2014
5
+ # marcochiesi <marco@blackstudio.it>, 2014
6
+ msgid ""
7
+ msgstr ""
8
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
9
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
10
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
11
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
12
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
13
+ "Language-Team: French (France) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/fr_FR/)\n"
14
+ "MIME-Version: 1.0\n"
15
+ "Content-Type: text/plain; charset=UTF-8\n"
16
+ "Content-Transfer-Encoding: 8bit\n"
17
+ "Language: fr_FR\n"
18
+ "Plural-Forms: nplurals=2; plural=(n > 1);\n"
19
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
20
+ "X-Poedit-Basepath: .\n"
21
+ "X-Poedit-Bookmarks: \n"
22
+ "X-Poedit-Country: United States\n"
23
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
24
+ "X-Poedit-Language: English\n"
25
+ "X-Poedit-SearchPath-0: .\n"
26
+ "X-Poedit-SourceCharset: utf-8\n"
27
+ "X-Textdomain-Support: yes\n"
28
+
29
+ #. translators: error message shown when a duplicated widget ID is detected
30
+ #: includes/class-admin.php:245
31
+ msgid ""
32
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
33
+ "new widget with the same content and then delete this one."
34
+ msgstr "ERREUR : ID de widget en double détecté. Pour éviter la perte de votre contenu, veuillez créer un nouveau widget avec le même contenu et supprimez celui-ci."
35
+
36
+ #. translators: text used for plugin home link
37
+ #: includes/class-admin.php:319
38
+ msgid "Home"
39
+ msgstr "Accueil"
40
+
41
+ #. translators: text used for support faq link
42
+ #: includes/class-admin.php:321
43
+ msgid "FAQ"
44
+ msgstr "FAQ"
45
+
46
+ #. translators: text used for support forum link
47
+ #: includes/class-admin.php:323
48
+ msgid "Support"
49
+ msgstr "Aide"
50
+
51
+ #. translators: text used for reviews link
52
+ #: includes/class-admin.php:325
53
+ msgid "Rate"
54
+ msgstr "Avis"
55
+
56
+ #. translators: text used for follow on twitter link
57
+ #: includes/class-admin.php:327
58
+ msgid "Follow"
59
+ msgstr "Suivre"
60
+
61
+ #. translators: text used for donation link
62
+ #: includes/class-admin.php:329
63
+ msgid "Donate"
64
+ msgstr "Don"
65
+
66
+ #. translators: text used for the icon that shows the plugin links
67
+ #: includes/class-admin.php:349
68
+ msgid "About Black Studio TinyMCE Widget plugin"
69
+ msgstr "À propos de l'extension Black Studio TinyMCE Widget"
70
+
71
+ #. translators: title of the widget
72
+ #: includes/class-widget.php:28
73
+ msgid "Visual Editor"
74
+ msgstr "Éditeur visuel"
75
+
76
+ #. translators: description of the widget, shown in available widgets
77
+ #: includes/class-widget.php:30
78
+ msgid "Arbitrary text or HTML with visual editor"
79
+ msgstr "Texte ou code HTML arbitraire avec un éditeur visuel"
80
+
81
+ #. Description of the plugin/theme
82
+ msgid ""
83
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
84
+ "TinyMCE editor."
85
+ msgstr ""
languages/black-studio-tinymce-widget-it_IT.mo CHANGED
Binary file
languages/black-studio-tinymce-widget-it_IT.po CHANGED
@@ -1,53 +1,84 @@
 
 
 
 
1
  msgid ""
2
  msgstr ""
3
  "Project-Id-Version: Black Studio TinyMCE Widget\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2014-06-12 14:55+0100\n"
6
- "PO-Revision-Date: 2014-06-12 14:56+0100\n"
7
- "Last-Translator: Marco <marco@blackstudio.it>\n"
8
- "Language-Team: Black Studio <info@blackstudio.it>\n"
9
- "Language: it_IT\n"
10
  "MIME-Version: 1.0\n"
11
  "Content-Type: text/plain; charset=UTF-8\n"
12
  "Content-Transfer-Encoding: 8bit\n"
13
- "X-Poedit-KeywordsList: _;gettext;gettext_noop;__\n"
14
- "X-Poedit-Basepath: ..\n"
15
- "X-Poedit-SourceCharset: utf-8\n"
16
- "X-Generator: Poedit 1.5.5\n"
 
 
 
 
17
  "X-Poedit-SearchPath-0: .\n"
 
 
18
 
19
- #: black-studio-tinymce-widget.php:18
20
- msgid "Arbitrary text or HTML with visual editor"
21
- msgstr "Testo o HTML libero con editor visuale"
 
 
 
22
 
23
- #: black-studio-tinymce-widget.php:20
24
- msgid "Visual Editor"
25
- msgstr "Editor Visuale"
 
26
 
27
- #: black-studio-tinymce-widget.php:106
28
- msgid "Donate"
29
- msgstr "Donazione"
 
30
 
31
- #: black-studio-tinymce-widget.php:106
 
32
  msgid "Support"
33
  msgstr "Supporto"
34
 
35
- #: black-studio-tinymce-widget.php:106
 
36
  msgid "Rate"
37
  msgstr "Vota"
38
 
39
- #: black-studio-tinymce-widget.php:106
 
40
  msgid "Follow"
41
  msgstr "Seguici"
42
 
43
- #: black-studio-tinymce-widget.php:207
44
- msgid ""
45
- "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
46
- "new one with the same content and then delete this widget."
47
- msgstr ""
48
- "ERRORE: Rilevato un widget con ID duplicato. Per evitare perdite di dati, si "
49
- "consiglia di creare un nuovo widget con il medesimo contenuto e "
50
- "successivamente cancellare questo widget."
 
 
 
 
 
 
 
 
 
 
 
51
 
52
- #~ msgid "Black Studio TinyMCE"
53
- #~ msgstr "Black Studio TinyMCE"
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
  msgid ""
6
  msgstr ""
7
  "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-06 00:00+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Italian (Italy) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/it_IT/)\n"
 
13
  "MIME-Version: 1.0\n"
14
  "Content-Type: text/plain; charset=UTF-8\n"
15
  "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: it_IT\n"
17
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
  "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
 
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr "ERRORE: Rilevato un widget con ID duplicato. Per evitare perdite di dati, si consiglia di creare un nuovo widget con il medesimo contenuto e successivamente cancellare questo."
34
 
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Home"
39
 
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "FAQ"
44
 
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
  msgid "Support"
48
  msgstr "Supporto"
49
 
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
  msgid "Rate"
53
  msgstr "Vota"
54
 
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
  msgid "Follow"
58
  msgstr "Seguici"
59
 
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "Donazione"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr "Info sul plugin Black Studio TinyMCE Widget"
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Editor Visuale"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr "Testo o HTML libero con editor visuale"
79
 
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr "Aggiunge un nuovo tipo di widget \"Editor Visuale\" basato sull'editor TinyMCE standard di WordPress."
languages/black-studio-tinymce-widget-ja.mo ADDED
Binary file
languages/black-studio-tinymce-widget-ja.po ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
+ msgid ""
6
+ msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Japanese (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/ja/)\n"
13
+ "MIME-Version: 1.0\n"
14
+ "Content-Type: text/plain; charset=UTF-8\n"
15
+ "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: ja\n"
17
+ "Plural-Forms: nplurals=1; plural=0;\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
+
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr ""
34
+
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "ホーム"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "FAQ"
44
+
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr "サポート"
49
+
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "率"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr ""
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "寄付する"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "ビジュアルエディター"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr ""
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-ko_KR.mo ADDED
Binary file
languages/black-studio-tinymce-widget-ko_KR.po ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
+ msgid ""
6
+ msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Korean (Korea) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/ko_KR/)\n"
13
+ "MIME-Version: 1.0\n"
14
+ "Content-Type: text/plain; charset=UTF-8\n"
15
+ "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: ko_KR\n"
17
+ "Plural-Forms: nplurals=1; plural=0;\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
+
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr ""
34
+
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "홈"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "질문 답변"
44
+
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr "지원"
49
+
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "등급"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr ""
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "기부"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "비주얼 편집기"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr ""
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-nl_NL.mo ADDED
Binary file
languages/black-studio-tinymce-widget-nl_NL.po ADDED
@@ -0,0 +1,85 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # Janjaap van Dijk <janjaapvandijk@gmail.com>, 2014
5
+ # Thom, 2014
6
+ msgid ""
7
+ msgstr ""
8
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
9
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
10
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
11
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
12
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
13
+ "Language-Team: Dutch (Netherlands) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/nl_NL/)\n"
14
+ "MIME-Version: 1.0\n"
15
+ "Content-Type: text/plain; charset=UTF-8\n"
16
+ "Content-Transfer-Encoding: 8bit\n"
17
+ "Language: nl_NL\n"
18
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
19
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
20
+ "X-Poedit-Basepath: .\n"
21
+ "X-Poedit-Bookmarks: \n"
22
+ "X-Poedit-Country: United States\n"
23
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
24
+ "X-Poedit-Language: English\n"
25
+ "X-Poedit-SearchPath-0: .\n"
26
+ "X-Poedit-SourceCharset: utf-8\n"
27
+ "X-Textdomain-Support: yes\n"
28
+
29
+ #. translators: error message shown when a duplicated widget ID is detected
30
+ #: includes/class-admin.php:245
31
+ msgid ""
32
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
33
+ "new widget with the same content and then delete this one."
34
+ msgstr "FOUT: Duplicate widget ID gedetecteerd. Om inhoud verlies te voorkomen, maak dan een nieuwe widget met dezelfde inhoud en verwijder deze."
35
+
36
+ #. translators: text used for plugin home link
37
+ #: includes/class-admin.php:319
38
+ msgid "Home"
39
+ msgstr "Home"
40
+
41
+ #. translators: text used for support faq link
42
+ #: includes/class-admin.php:321
43
+ msgid "FAQ"
44
+ msgstr "FAQ"
45
+
46
+ #. translators: text used for support forum link
47
+ #: includes/class-admin.php:323
48
+ msgid "Support"
49
+ msgstr "Ondersteuning"
50
+
51
+ #. translators: text used for reviews link
52
+ #: includes/class-admin.php:325
53
+ msgid "Rate"
54
+ msgstr "Beoordelen"
55
+
56
+ #. translators: text used for follow on twitter link
57
+ #: includes/class-admin.php:327
58
+ msgid "Follow"
59
+ msgstr "Volgen"
60
+
61
+ #. translators: text used for donation link
62
+ #: includes/class-admin.php:329
63
+ msgid "Donate"
64
+ msgstr "Doneren"
65
+
66
+ #. translators: text used for the icon that shows the plugin links
67
+ #: includes/class-admin.php:349
68
+ msgid "About Black Studio TinyMCE Widget plugin"
69
+ msgstr ""
70
+
71
+ #. translators: title of the widget
72
+ #: includes/class-widget.php:28
73
+ msgid "Visual Editor"
74
+ msgstr "Visuele bewerker"
75
+
76
+ #. translators: description of the widget, shown in available widgets
77
+ #: includes/class-widget.php:30
78
+ msgid "Arbitrary text or HTML with visual editor"
79
+ msgstr "Arbitraire tekst of HTML met visuele editor"
80
+
81
+ #. Description of the plugin/theme
82
+ msgid ""
83
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
84
+ "TinyMCE editor."
85
+ msgstr ""
languages/black-studio-tinymce-widget-pl_PL.mo ADDED
Binary file
languages/black-studio-tinymce-widget-pl_PL.po ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
+ msgid ""
6
+ msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Polish (Poland) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/pl_PL/)\n"
13
+ "MIME-Version: 1.0\n"
14
+ "Content-Type: text/plain; charset=UTF-8\n"
15
+ "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: pl_PL\n"
17
+ "Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
+
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr ""
34
+
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Strona główna"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "FAQ"
44
+
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr ""
49
+
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Tempo"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr "Śledź"
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr ""
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Edytor wizualny"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr "Dowolny tekst lub kod HTML - Edytor wizualny"
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-pt_BR.mo ADDED
Binary file
languages/black-studio-tinymce-widget-pt_BR.po ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
+ msgid ""
6
+ msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Portuguese (Brazil) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/pt_BR/)\n"
13
+ "MIME-Version: 1.0\n"
14
+ "Content-Type: text/plain; charset=UTF-8\n"
15
+ "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: pt_BR\n"
17
+ "Plural-Forms: nplurals=2; plural=(n > 1);\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
+
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr ""
34
+
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Home"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "FAQ"
44
+
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr "Suporte"
49
+
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Classificar"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr "Seguir"
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "Doar"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Editor visual"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr "Texto normal ou HTML com o editor visual"
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-ro_RO.mo ADDED
Binary file
languages/black-studio-tinymce-widget-ro_RO.po ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
+ msgid ""
6
+ msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Romanian (Romania) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/ro_RO/)\n"
13
+ "MIME-Version: 1.0\n"
14
+ "Content-Type: text/plain; charset=UTF-8\n"
15
+ "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: ro_RO\n"
17
+ "Plural-Forms: nplurals=3; plural=(n==1?0:(((n%100>19)||((n%100==0)&&(n!=0)))?2:1));\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
+
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr ""
34
+
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Acasă"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "Întrebări/Răspunsuri"
44
+
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr "Asistenţă"
49
+
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Viteză"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr ""
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "Donați"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Editor vizual"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr ""
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-ru_RU.mo ADDED
Binary file
languages/black-studio-tinymce-widget-ru_RU.po ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
+ msgid ""
6
+ msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-06 03:10+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Russian (Russia) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/ru_RU/)\n"
13
+ "MIME-Version: 1.0\n"
14
+ "Content-Type: text/plain; charset=UTF-8\n"
15
+ "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: ru_RU\n"
17
+ "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
+
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr ""
34
+
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Главная"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "FAQ"
44
+
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr "Поддержка"
49
+
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Частота"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr ""
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "Пожертвовать"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Редактор"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr ""
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-sk_SK.mo ADDED
Binary file
languages/black-studio-tinymce-widget-sk_SK.po ADDED
@@ -0,0 +1,85 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
+ # Michal Vittek <miso.par1c@gmail.com>, 2014
6
+ msgid ""
7
+ msgstr ""
8
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
9
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
10
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
11
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
12
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
13
+ "Language-Team: Slovak (Slovakia) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/sk_SK/)\n"
14
+ "MIME-Version: 1.0\n"
15
+ "Content-Type: text/plain; charset=UTF-8\n"
16
+ "Content-Transfer-Encoding: 8bit\n"
17
+ "Language: sk_SK\n"
18
+ "Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"
19
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
20
+ "X-Poedit-Basepath: .\n"
21
+ "X-Poedit-Bookmarks: \n"
22
+ "X-Poedit-Country: United States\n"
23
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
24
+ "X-Poedit-Language: English\n"
25
+ "X-Poedit-SearchPath-0: .\n"
26
+ "X-Poedit-SourceCharset: utf-8\n"
27
+ "X-Textdomain-Support: yes\n"
28
+
29
+ #. translators: error message shown when a duplicated widget ID is detected
30
+ #: includes/class-admin.php:245
31
+ msgid ""
32
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
33
+ "new widget with the same content and then delete this one."
34
+ msgstr "CHYBA: Zistená duplicita ID. Aby ste predišli strate obsahu, vytvorte nový widget s rovnakým obsahom a tento zmažte."
35
+
36
+ #. translators: text used for plugin home link
37
+ #: includes/class-admin.php:319
38
+ msgid "Home"
39
+ msgstr "Domov"
40
+
41
+ #. translators: text used for support faq link
42
+ #: includes/class-admin.php:321
43
+ msgid "FAQ"
44
+ msgstr "FAQ"
45
+
46
+ #. translators: text used for support forum link
47
+ #: includes/class-admin.php:323
48
+ msgid "Support"
49
+ msgstr "Podpora"
50
+
51
+ #. translators: text used for reviews link
52
+ #: includes/class-admin.php:325
53
+ msgid "Rate"
54
+ msgstr "Sadzba"
55
+
56
+ #. translators: text used for follow on twitter link
57
+ #: includes/class-admin.php:327
58
+ msgid "Follow"
59
+ msgstr "Sledovať"
60
+
61
+ #. translators: text used for donation link
62
+ #: includes/class-admin.php:329
63
+ msgid "Donate"
64
+ msgstr "Darovať"
65
+
66
+ #. translators: text used for the icon that shows the plugin links
67
+ #: includes/class-admin.php:349
68
+ msgid "About Black Studio TinyMCE Widget plugin"
69
+ msgstr ""
70
+
71
+ #. translators: title of the widget
72
+ #: includes/class-widget.php:28
73
+ msgid "Visual Editor"
74
+ msgstr "Vizuálny editor"
75
+
76
+ #. translators: description of the widget, shown in available widgets
77
+ #: includes/class-widget.php:30
78
+ msgid "Arbitrary text or HTML with visual editor"
79
+ msgstr "Ľubovoľné textové alebo HTML s vizuálny editor"
80
+
81
+ #. Description of the plugin/theme
82
+ msgid ""
83
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
84
+ "TinyMCE editor."
85
+ msgstr ""
languages/black-studio-tinymce-widget-sv_SE.mo CHANGED
Binary file
languages/black-studio-tinymce-widget-sv_SE.po CHANGED
@@ -1,58 +1,84 @@
 
 
 
 
1
  msgid ""
2
  msgstr ""
3
  "Project-Id-Version: Black Studio TinyMCE Widget\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2014-01-29 10:47+0100\n"
6
- "PO-Revision-Date: 2014-01-29 10:48+0100\n"
7
- "Last-Translator: Johan Sölve <johan@montania.se>\n"
8
- "Language-Team: Black Studio <info@blackstudio.it>\n"
9
- "Language: it_IT\n"
10
  "MIME-Version: 1.0\n"
11
  "Content-Type: text/plain; charset=UTF-8\n"
12
  "Content-Transfer-Encoding: 8bit\n"
13
- "Plural-Forms: nplurals=2; plural=n != 1;\n"
 
 
 
 
 
 
 
 
14
  "X-Poedit-SourceCharset: utf-8\n"
15
- "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;"
16
- "_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2\n"
17
- "X-Poedit-Basepath: ..\n"
18
  "X-Textdomain-Support: yes\n"
19
- "X-Generator: Poedit 1.5.7\n"
20
- "X-Poedit-SearchPath-0: .\n"
21
 
22
- # @ black-studio-tinymce-widget
23
- #: black-studio-tinymce-widget.php:21
24
- msgid "Arbitrary text or HTML with visual editor"
 
 
25
  msgstr ""
26
- "Godtycklig text eller HTML med visuell redigerare. Black Studio TinyMCE."
27
 
28
- # @ black-studio-tinymce-widget
29
- #: black-studio-tinymce-widget.php:23
30
- msgid "Black Studio TinyMCE"
31
- msgstr "Visuell text"
 
 
 
 
 
32
 
33
- # @ default
34
- #: black-studio-tinymce-widget.php:82
35
- msgid "Title:"
36
- msgstr "Titel:"
37
 
38
- # @ default
39
- #: black-studio-tinymce-widget.php:85
40
- msgid "HTML"
41
- msgstr "HTML"
42
 
43
- # @ default
44
- #: black-studio-tinymce-widget.php:86
45
- msgid "Visual"
46
- msgstr "Visuell"
47
 
48
- #: black-studio-tinymce-widget.php:94
 
49
  msgid "Donate"
50
  msgstr "Donation"
51
 
52
- #: black-studio-tinymce-widget.php:94
53
- msgid "Support"
54
- msgstr "Support"
 
55
 
56
- #: black-studio-tinymce-widget.php:94
57
- msgid "Follow"
58
- msgstr "Följ"
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
  msgid ""
6
  msgstr ""
7
  "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Swedish (Sweden) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/sv_SE/)\n"
 
13
  "MIME-Version: 1.0\n"
14
  "Content-Type: text/plain; charset=UTF-8\n"
15
  "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: sv_SE\n"
17
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
  "X-Poedit-SourceCharset: utf-8\n"
 
 
 
26
  "X-Textdomain-Support: yes\n"
 
 
27
 
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
  msgstr ""
 
34
 
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Hem"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "FAQ"
44
 
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr "Support"
49
 
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Taxa"
54
 
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr "Följ"
59
 
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
  msgid "Donate"
63
  msgstr "Donation"
64
 
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
 
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Visuell redigerare"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr "Godtycklig text eller HTML med visuell redigerare. Black Studio TinyMCE."
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-tr_TR.mo ADDED
Binary file
languages/black-studio-tinymce-widget-tr_TR.po ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # Batuhan Büyükgüzel <bbuyukguzel@gmail.com>, 2014
5
+ msgid ""
6
+ msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Turkish (Turkey) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/tr_TR/)\n"
13
+ "MIME-Version: 1.0\n"
14
+ "Content-Type: text/plain; charset=UTF-8\n"
15
+ "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: tr_TR\n"
17
+ "Plural-Forms: nplurals=1; plural=0;\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
+
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr ""
34
+
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Anasayfa"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "SSS"
44
+
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr "Destek"
49
+
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Oylayın"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr "Takip Et"
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "Bağışta Bulunun"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Görsel Editör"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr ""
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-uk.mo ADDED
Binary file
languages/black-studio-tinymce-widget-uk.po ADDED
@@ -0,0 +1,84 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # marcochiesi <marco@blackstudio.it>, 2014
5
+ msgid ""
6
+ msgstr ""
7
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
8
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
9
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
10
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
11
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
12
+ "Language-Team: Ukrainian (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/uk/)\n"
13
+ "MIME-Version: 1.0\n"
14
+ "Content-Type: text/plain; charset=UTF-8\n"
15
+ "Content-Transfer-Encoding: 8bit\n"
16
+ "Language: uk\n"
17
+ "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
18
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
19
+ "X-Poedit-Basepath: .\n"
20
+ "X-Poedit-Bookmarks: \n"
21
+ "X-Poedit-Country: United States\n"
22
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
23
+ "X-Poedit-Language: English\n"
24
+ "X-Poedit-SearchPath-0: .\n"
25
+ "X-Poedit-SourceCharset: utf-8\n"
26
+ "X-Textdomain-Support: yes\n"
27
+
28
+ #. translators: error message shown when a duplicated widget ID is detected
29
+ #: includes/class-admin.php:245
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
+ msgstr ""
34
+
35
+ #. translators: text used for plugin home link
36
+ #: includes/class-admin.php:319
37
+ msgid "Home"
38
+ msgstr "Головна"
39
+
40
+ #. translators: text used for support faq link
41
+ #: includes/class-admin.php:321
42
+ msgid "FAQ"
43
+ msgstr "ЧаПи"
44
+
45
+ #. translators: text used for support forum link
46
+ #: includes/class-admin.php:323
47
+ msgid "Support"
48
+ msgstr "Підтримка"
49
+
50
+ #. translators: text used for reviews link
51
+ #: includes/class-admin.php:325
52
+ msgid "Rate"
53
+ msgstr "Рейтинг"
54
+
55
+ #. translators: text used for follow on twitter link
56
+ #: includes/class-admin.php:327
57
+ msgid "Follow"
58
+ msgstr "Слідувати"
59
+
60
+ #. translators: text used for donation link
61
+ #: includes/class-admin.php:329
62
+ msgid "Donate"
63
+ msgstr "Жертвувати"
64
+
65
+ #. translators: text used for the icon that shows the plugin links
66
+ #: includes/class-admin.php:349
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #. translators: title of the widget
71
+ #: includes/class-widget.php:28
72
+ msgid "Visual Editor"
73
+ msgstr "Візуальний редактор"
74
+
75
+ #. translators: description of the widget, shown in available widgets
76
+ #: includes/class-widget.php:30
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr "Довільний текст або HTML з візуальним редактором"
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget-zh_CN.mo ADDED
Binary file
languages/black-studio-tinymce-widget-zh_CN.po ADDED
@@ -0,0 +1,85 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
+ # Translators:
4
+ # hsiyuano <hsiyuano@gmail.com>, 2014
5
+ # marcochiesi <marco@blackstudio.it>, 2014
6
+ msgid ""
7
+ msgstr ""
8
+ "Project-Id-Version: Black Studio TinyMCE Widget\n"
9
+ "Report-Msgid-Bugs-To: https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
10
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
11
+ "PO-Revision-Date: 2014-10-05 23:57+0000\n"
12
+ "Last-Translator: marcochiesi <marco@blackstudio.it>\n"
13
+ "Language-Team: Chinese (China) (http://www.transifex.com/projects/p/black-studio-tinymce-widget/language/zh_CN/)\n"
14
+ "MIME-Version: 1.0\n"
15
+ "Content-Type: text/plain; charset=UTF-8\n"
16
+ "Content-Transfer-Encoding: 8bit\n"
17
+ "Language: zh_CN\n"
18
+ "Plural-Forms: nplurals=1; plural=0;\n"
19
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
20
+ "X-Poedit-Basepath: .\n"
21
+ "X-Poedit-Bookmarks: \n"
22
+ "X-Poedit-Country: United States\n"
23
+ "X-Poedit-KeywordsList: __;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
24
+ "X-Poedit-Language: English\n"
25
+ "X-Poedit-SearchPath-0: .\n"
26
+ "X-Poedit-SourceCharset: utf-8\n"
27
+ "X-Textdomain-Support: yes\n"
28
+
29
+ #. translators: error message shown when a duplicated widget ID is detected
30
+ #: includes/class-admin.php:245
31
+ msgid ""
32
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
33
+ "new widget with the same content and then delete this one."
34
+ msgstr ""
35
+
36
+ #. translators: text used for plugin home link
37
+ #: includes/class-admin.php:319
38
+ msgid "Home"
39
+ msgstr "首页"
40
+
41
+ #. translators: text used for support faq link
42
+ #: includes/class-admin.php:321
43
+ msgid "FAQ"
44
+ msgstr "常见问题"
45
+
46
+ #. translators: text used for support forum link
47
+ #: includes/class-admin.php:323
48
+ msgid "Support"
49
+ msgstr "帮助与支持"
50
+
51
+ #. translators: text used for reviews link
52
+ #: includes/class-admin.php:325
53
+ msgid "Rate"
54
+ msgstr "评级"
55
+
56
+ #. translators: text used for follow on twitter link
57
+ #: includes/class-admin.php:327
58
+ msgid "Follow"
59
+ msgstr "跟随"
60
+
61
+ #. translators: text used for donation link
62
+ #: includes/class-admin.php:329
63
+ msgid "Donate"
64
+ msgstr "捐助"
65
+
66
+ #. translators: text used for the icon that shows the plugin links
67
+ #: includes/class-admin.php:349
68
+ msgid "About Black Studio TinyMCE Widget plugin"
69
+ msgstr ""
70
+
71
+ #. translators: title of the widget
72
+ #: includes/class-widget.php:28
73
+ msgid "Visual Editor"
74
+ msgstr "可视化编辑器"
75
+
76
+ #. translators: description of the widget, shown in available widgets
77
+ #: includes/class-widget.php:30
78
+ msgid "Arbitrary text or HTML with visual editor"
79
+ msgstr ""
80
+
81
+ #. Description of the plugin/theme
82
+ msgid ""
83
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
84
+ "TinyMCE editor."
85
+ msgstr ""
languages/black-studio-tinymce-widget.pot CHANGED
@@ -1,37 +1,84 @@
 
 
1
  msgid ""
2
  msgstr ""
3
- "Project-Id-Version: Black Studio TinyMCE Widget\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2014-03-06 12:08+0100\n"
6
- "PO-Revision-Date: 2014-03-06 12:08+0100\n"
7
- "Last-Translator: Marco <marco@blackstudio.it>\n"
8
- "Language-Team: Black Studio <info@blackstudio.it>\n"
9
- "Language: it_IT\n"
10
  "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
  "Content-Transfer-Encoding: 8bit\n"
13
- "X-Poedit-KeywordsList: _;gettext;gettext_noop;__\n"
14
- "X-Poedit-Basepath: ..\n"
 
 
 
 
 
 
15
  "X-Poedit-SourceCharset: utf-8\n"
16
- "X-Generator: Poedit 1.5.5\n"
 
 
 
17
  "X-Poedit-SearchPath-0: .\n"
 
18
 
19
- #: black-studio-tinymce-widget.php:21
20
- msgid "Arbitrary text or HTML with visual editor"
 
 
 
21
  msgstr ""
22
 
23
- #: black-studio-tinymce-widget.php:23
24
- msgid "Visual Editor"
 
25
  msgstr ""
26
 
27
- #: black-studio-tinymce-widget.php:99
28
- msgid "Donate"
 
29
  msgstr ""
30
 
31
- #: black-studio-tinymce-widget.php:99
 
32
  msgid "Support"
33
  msgstr ""
34
 
35
- #: black-studio-tinymce-widget.php:99
 
 
 
 
 
 
36
  msgid "Follow"
37
  msgstr ""
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2014 Black Studio
2
+ # This file is distributed under the GPLv3.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Black Studio TinyMCE Widget 2.0.0\n"
6
+ "Report-Msgid-Bugs-To: "
7
+ "https://github.com/black-studio/black-studio-tinymce-widget/issues\n"
8
+ "POT-Creation-Date: 2014-10-06 09:32:27+00:00\n"
 
 
 
9
  "MIME-Version: 1.0\n"
10
+ "Content-Type: text/plain; charset=utf-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
+ "PO-Revision-Date: 2014-MO-DA HO:MI+ZONE\n"
13
+ "Last-Translator: Black Studio <info@blackstudio.it>\n"
14
+ "Language-Team: Black Studio <info@blackstudio.it>\n"
15
+ "X-Generator: grunt-wp-i18n 0.4.8\n"
16
+ "Plural-Forms: nplurals=2; plural=n != 1;\n"
17
+ "X-Poedit-Basepath: .\n"
18
+ "X-Poedit-Language: English\n"
19
+ "X-Poedit-Country: United States\n"
20
  "X-Poedit-SourceCharset: utf-8\n"
21
+ "X-Poedit-KeywordsList: "
22
+ "__;_e;__ngettext:1,2;_n:1,2;__ngettext_noop:1,2;_n_noop:1,2;_c,_nc:4c,1,2;_"
23
+ "x:1,2c;_ex:1,2c;_nx:4c,1,2;_nx_noop:4c,1,2;\n"
24
+ "X-Poedit-Bookmarks: \n"
25
  "X-Poedit-SearchPath-0: .\n"
26
+ "X-Textdomain-Support: yes\n"
27
 
28
+ #: includes/class-admin.php:245
29
+ #. translators: error message shown when a duplicated widget ID is detected
30
+ msgid ""
31
+ "ERROR: Duplicate widget ID detected. To avoid content loss, please create a "
32
+ "new widget with the same content and then delete this one."
33
  msgstr ""
34
 
35
+ #: includes/class-admin.php:319
36
+ #. translators: text used for plugin home link
37
+ msgid "Home"
38
  msgstr ""
39
 
40
+ #: includes/class-admin.php:321
41
+ #. translators: text used for support faq link
42
+ msgid "FAQ"
43
  msgstr ""
44
 
45
+ #: includes/class-admin.php:323
46
+ #. translators: text used for support forum link
47
  msgid "Support"
48
  msgstr ""
49
 
50
+ #: includes/class-admin.php:325
51
+ #. translators: text used for reviews link
52
+ msgid "Rate"
53
+ msgstr ""
54
+
55
+ #: includes/class-admin.php:327
56
+ #. translators: text used for follow on twitter link
57
  msgid "Follow"
58
  msgstr ""
59
+
60
+ #: includes/class-admin.php:329
61
+ #. translators: text used for donation link
62
+ msgid "Donate"
63
+ msgstr ""
64
+
65
+ #: includes/class-admin.php:349
66
+ #. translators: text used for the icon that shows the plugin links
67
+ msgid "About Black Studio TinyMCE Widget plugin"
68
+ msgstr ""
69
+
70
+ #: includes/class-widget.php:28
71
+ #. translators: title of the widget
72
+ msgid "Visual Editor"
73
+ msgstr ""
74
+
75
+ #: includes/class-widget.php:30
76
+ #. translators: description of the widget, shown in available widgets
77
+ msgid "Arbitrary text or HTML with visual editor"
78
+ msgstr ""
79
+
80
+ #. Description of the plugin/theme
81
+ msgid ""
82
+ "Adds a new \"Visual Editor\" widget type based on the native WordPress "
83
+ "TinyMCE editor."
84
+ msgstr ""
languages/black-studio-tinymce-widget_sk_SK.mo DELETED
Binary file
languages/black-studio-tinymce-widget_sk_SK.po DELETED
@@ -1,37 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Black Studio TinyMCE Widget\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2012-07-31 10:28+0100\n"
6
- "PO-Revision-Date: 2013-01-16 02:04+0300\n"
7
- "Last-Translator: \n"
8
- "Language-Team: Black Studio <info@blackstudio.it>\n"
9
- "MIME-Version: 1.0\n"
10
- "Content-Type: text/plain; charset=UTF-8\n"
11
- "Content-Transfer-Encoding: 8bit\n"
12
- "X-Poedit-KeywordsList: _;gettext;gettext_noop;__\n"
13
- "X-Poedit-Basepath: ..\n"
14
- "X-Poedit-SourceCharset: utf-8\n"
15
- "Language: it_IT\n"
16
- "X-Generator: Poedit 1.5.4\n"
17
- "X-Poedit-SearchPath-0: .\n"
18
-
19
- #: black-studio-tinymce-widget.php:19
20
- msgid "Arbitrary text or HTML with visual editor"
21
- msgstr "Ľubovoľné textové alebo HTML s vizuálny editor"
22
-
23
- #: black-studio-tinymce-widget.php:21
24
- msgid "Black Studio TinyMCE"
25
- msgstr "Čierne Studio TinyMCE"
26
-
27
- #: black-studio-tinymce-widget.php:79
28
- msgid "Donate"
29
- msgstr "Darovať"
30
-
31
- #: black-studio-tinymce-widget.php:79
32
- msgid "Support"
33
- msgstr "Podpora"
34
-
35
- #: black-studio-tinymce-widget.php:79
36
- msgid "Follow"
37
- msgstr "Postupujte podľa"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
languages/black-studio-tinymce-widget_uk_UA.mo DELETED
Binary file
languages/black-studio-tinymce-widget_uk_UA.po DELETED
@@ -1,37 +0,0 @@
1
- msgid ""
2
- msgstr ""
3
- "Project-Id-Version: Black Studio TinyMCE Widget\n"
4
- "Report-Msgid-Bugs-To: \n"
5
- "POT-Creation-Date: 2014-03-06 12:08+0100\n"
6
- "PO-Revision-Date: 2014-05-22 17:42+0200\n"
7
- "Last-Translator: Michael Yunat <Michael.Yunat@gmail.com>\n"
8
- "Language-Team: http://getvoip.com/\n"
9
- "Language: uk\n"
10
- "MIME-Version: 1.0\n"
11
- "Content-Type: text/plain; charset=UTF-8\n"
12
- "Content-Transfer-Encoding: 8bit\n"
13
- "X-Poedit-KeywordsList: _;gettext;gettext_noop;__\n"
14
- "X-Poedit-Basepath: ..\n"
15
- "X-Poedit-SourceCharset: utf-8\n"
16
- "X-Generator: Poedit 1.6.5\n"
17
- "X-Poedit-SearchPath-0: .\n"
18
-
19
- #: black-studio-tinymce-widget.php:21
20
- msgid "Arbitrary text or HTML with visual editor"
21
- msgstr "Довільний текст або HTML з візуальним редактором"
22
-
23
- #: black-studio-tinymce-widget.php:23
24
- msgid "Visual Editor"
25
- msgstr "Візуальний редактор"
26
-
27
- #: black-studio-tinymce-widget.php:99
28
- msgid "Donate"
29
- msgstr "Жертвувати"
30
-
31
- #: black-studio-tinymce-widget.php:99
32
- msgid "Support"
33
- msgstr "Підтримка"
34
-
35
- #: black-studio-tinymce-widget.php:99
36
- msgid "Follow"
37
- msgstr "Слідувати"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
readme.txt CHANGED
@@ -1,261 +1,301 @@
1
- === Black Studio TinyMCE Widget ===
2
- Contributors: marcochiesi, thedarkmist
3
- Donate link: http://www.blackstudio.it/en/wordpress-plugins/black-studio-tinymce-widget/
4
- Tags: wysiwyg, widget, tinymce, editor, image, media, rich text, rich text editor, visual editor, wysiwyg editor, tinymce editor, widget editor, html editor, wysiwyg widget, html widget, editor widget, text widget, rich text widget, enhanced text widget, tinymce widget, visual widget, image widget, media widget
5
- Requires at least: 3.0
6
- Tested up to: 4.0
7
- Stable tag: 1.4.8
8
- License: GPLv3
9
- License URI: http://www.gnu.org/licenses/gpl.html
10
-
11
- Adds a WYSIWYG widget based on the standard TinyMCE WordPress visual editor.
12
-
13
- == Description ==
14
-
15
- This plugin adds a WYSIWYG text widget based on the standard TinyMCE WordPress visual editor. This is intended to overcome the limitations of the default WordPress text widget, so that you can visually add rich text contents to your sidebars, with no knowledge of HTML required.
16
-
17
- = Features =
18
-
19
- * Add rich text widgets to your sidebars and edit them using visual editor
20
- * Switch between Visual mode and HTML mode
21
- * Insert images/videos from WordPress Media Library
22
- * Insert links to existing WordPress pages/posts
23
- * Fullscreen editing mode supported
24
- * Widgets accessibility mode supported
25
- * WordPress networks (Multi-site) supported
26
- * WPML (Multi-language) supported
27
- * Live preview of widgets in Theme customizer supported (since WordPress 3.9)
28
-
29
- = Links =
30
-
31
- * [Plugin's web page](http://www.blackstudio.it/en/wordpress-plugins/black-studio-tinymce-widget/)
32
- * [Support forum](http://wordpress.org/support/plugin/black-studio-tinymce-widget)
33
- * [Follow us on Twitter](https://twitter.com/blackstudioita)
34
-
35
- == Installation ==
36
-
37
- This section describes how to install and use the plugin.
38
-
39
- 1. Install automatically through the `Plugins` menu and `Add New` button (or upload the entire `black-studio-tinymce-widget` folder to the `/wp-content/plugins/` directory)
40
- 2. Activate the plugin
41
- 3. Go to `Appearance` -> `Widgets`
42
- 4. Drag and drop the `Visual Editor` widget to the desired sidebar (or, if using Accesibility mode, click the `Add` link)
43
- 5. Fill in title and (rich) text
44
-
45
- == Screenshots ==
46
-
47
- 1. Black Studio TinyMCE Widget editor window
48
- 2. Black Studio TinyMCE Widget combined with Ultimate TinyMCE plugin
49
-
50
- == Frequently Asked Questions ==
51
-
52
- = Troubleshooting =
53
-
54
- If you are experiencing issues with the plugin, check our [support forum](http://wordpress.org/support/plugin/black-studio-tinymce-widget), but please read entirely these FAQ before posting a new topic in the forum. Most of the times issues are caused by incompatibility with other plugins or themes, which don't comply with WordPress coding standars and thus may prevent our plugin from working as expected. If you have any issues with the plugin, please do the following:
55
-
56
- 1. Ensure the you have understood the purpose of the plugin. It only adds the ability to use the visual editor (TinyMCE) in widgets as you do in posts and pages, but it doesn't alter the editor behavior or functions. So if you are experiencing issues with the editor even when editing posts or pages, they're definitely not related to our plugin (unless you're using some additional plugins that provides widgets support for pages, i.e. Page Builder).
57
- 2. Ensure that you are running the latest versions of both WordPress and the plugin.
58
- 3. Search in our [support forum](http://wordpress.org/support/plugin/black-studio-tinymce-widget) for threads with similar issues.
59
- 4. Disable all other plugins and switch to a WordPress default theme for a while. If the problem persists, open a topic in the forum (see below for instructions). Otherwise enable the other plugins ony by one and figure out which one is causing the issue, then post to the support forum mentioning it. Please see [Conflict Diagnosis Guide for WordPress plugins](https://rtcamp.com/rtmedia/docs/troubleshooting/conflict-diagnosis-guide-wordpress-plugins/) for further info.
60
-
61
- When you post a message in the [support forum](http://wordpress.org/support/plugin/black-studio-tinymce-widget) please provide the following information:
62
-
63
- * Description of the problem and steps to reproduce it
64
- * Error messages if any, in particular in [browser's javascript console](http://webmasters.stackexchange.com/questions/8525/how-to-open-the-javascript-console-in-different-browsers)
65
- * Browser and Operating System in use
66
- * WordPress version in use
67
- * WordPress theme in use
68
- * WordPress plugins causing conflicts if any
69
- * A link to a screenshot if it can be useful to undesrtand the problem
70
-
71
- = Widgets disappeared after migrating or changing the site URL =
72
-
73
- When dealing with a WordPress site URL change it is necessary to face the "serialized fields" issue: data may become corrupted if using a simple search/replace (see the [Codex](http://codex.wordpress.org/Moving_WordPress#When_Your_Domain_Name_or_URLs_Change) for further info). This is not an issue specifically related to our plugin, but it affects all the parts (plugins, themes and WordPress core files too) that use serialized data archiviation. When changing the site URL, the recommended way is to use the [Search and Replace for WordPress Databases Script](https://interconnectit.com/products/search-and-replace-for-wordpress-databases/), as suggested by the Codex.
74
-
75
- = How to translate widgets using WPML =
76
-
77
- The current version of `Black Studio TinyMCE Widget` plugin works together with the `WPML String translation` plugin. To translate a widget created with `Black Studio TinyMCE Widget` plugin you have to create it on the widgets panel and then go to `WPML` -> `String translation` and translate the title and text from there (unfortunately the translation textarea has not the visual editor).
78
- Note: If you installed WPML after the creation of the widgets, just re-save them and they will appear on the String translation list.
79
-
80
- = How to embed video and other contents =
81
-
82
- WordPress has a nice [autoembed feature](http://codex.wordpress.org/Embeds) that allows you to embed videos and other stuff in an easy way, by just putting the URL in the content area. This is also possible for widgets created with this plugin, but for best results it is recommended to put the URL inside an `[embed]` shortcode.
83
- Example:
84
- `[embed]http://www.youtube.com/watch?v=XXXXXXXXXXX[/embed]`
85
- Ensure that the URL has not an hyperlink on it.
86
- Alternatively, if you don't want to use `[embed]` shortcode, ensure that the URL is not surrounded by a `<p>` tag, which is added automatically by the WYSIWYG editor (switch to HTML mode to remove enclosing `<p>` tags).
87
-
88
- = How to customize widget HTML markup =
89
-
90
- Most of the HTML markup around widgets is generated by WordPress and you can control it using the proper arguments (`class`, `before_widget`, `after_widget`, `before_title`, `after_title`) passed to the [`register_sidebar`](http://codex.wordpress.org/Function_Reference/register_sidebar) function (this is usually done by your theme). The only piece of HTML code added by the plugin is there for compatibility with the markup of native WordPress text widgets, and it is the following:
91
- `<div class="textwidget"> ... widget text ... </div>`
92
- You may customize it using the `black_studio_tinymce_before_text` and `black_studio_tinymce_after_text` filter hooks. They both take two parameters, the first one is the default text and the second is the widget instance. See examples below.
93
-
94
- Example 1: Custom markup
95
- `
96
- add_filter( 'black_studio_tinymce_before_text', 'my_widget_before_text', 10, 2 );
97
- function my_widget_before_text( $before_text, $instance ) {
98
- return '<div class="myclass">';
99
- }
100
- add_filter( 'black_studio_tinymce_after_text', 'my_widget_after_text', 10, 2 );
101
- function my_widget_after_text( $after_text, $instance ) {
102
- return '';
103
- }
104
- `
105
-
106
- Example 2: Totally remove markup
107
- `
108
- add_filter( 'black_studio_tinymce_before_text', '__return_empty_string' );
109
- add_filter( 'black_studio_tinymce_after_text', '__return_empty_string' );
110
- `
111
-
112
- == Changelog ==
113
-
114
- = 1.4.8 =
115
- * Fixed bug on image captions on WordPress 4.0 (part 2)
116
-
117
- = 1.4.7 =
118
- * Fixed bug on image captions on WordPress 4.0
119
-
120
- = 1.4.6 =
121
- * Bugfix on widget display
122
-
123
- = 1.4.5 =
124
- * Fixed compatibility issue with Page Builder + WPML String Translation
125
-
126
- = 1.4.4 =
127
- * Fixed z-index compatibility issue with Shortcodes Ultimate plugin
128
-
129
- = 1.4.3 =
130
- * Added filter hooks to modify the markup before and after the widget text
131
- * Fixed z-index issue in fullscreen mode
132
- * Added widget icon for theme customizer
133
- * Updated danish translation
134
- * Updated FAQ and readme.txt
135
-
136
- = 1.4.2 =
137
- * Added support for `wp_enqueue_editor` hook
138
- * Added compatibility with Advanced Image Styles plugin
139
- * Added danish translation (Contributor: Mikkel Rommelhoff)
140
-
141
- = 1.4.1 =
142
- * Enhanced HTML source code formatting
143
-
144
- = 1.4 =
145
- * HTML and CSS optimization by using WordPress native editor markup and styles
146
- * Adoption of WordPress JS minification conventions (".min" suffix)
147
- * Integration with WordPress SCRIPT_DEBUG constant for javascript debugging purposes
148
- * Enhanced compatibility with 3rd party media buttons provider (i.e. Shortcodes Ultimate)
149
- * Enhanced plugin internal version handling
150
- * Duplicated widget IDs detection
151
- * Added Rate link
152
- * Added compatibility with WordPress Language packs
153
- * Added ukrainian translation (Contributor: Michael Yunat [getvoip.com](http://getvoip.com/blog))
154
- * Fixed notice on theme_advanced_buttons1 parameter
155
- * Fixed z-index issue with WordPress 3.9 admin menu on small screens
156
-
157
- = 1.3.3 =
158
- * Fixed visualization bug upon widget saving
159
- * Enhanced support WordPress 3.9 Theme Customizer (live edit)
160
-
161
- = 1.3.2 =
162
- * Fixed compatibility issue with WordPress 3.9 Beta 3
163
- * Added support for WordPress 3.9 Theme Customizer
164
- * Added swedish translation (Contributor: macsolve)
165
- * Updated installation documentation
166
- * Updated FAQ
167
-
168
- = 1.3.1 =
169
- * Renamed the widget to "Visual Editor" for better user friendliness
170
- * Fixed compatibility issue with FirmaSite Theme Enhancer plugin
171
-
172
- = 1.3.0 =
173
- * Added support for smilies conversion (based on the general WordPress option)
174
- * Updated styling to match the new default WordPress editor appearence
175
- * Refactoring of PHP and JS code to be compliant to WordPress coding standard
176
- * Fixed compatibility issue with WordPress 3.9 alpha and TinyMCE 4.0
177
- * Fixed compatibility issue with Jetpack / After the Deadline plugin
178
- * Fixed editor behavior on widget title clicks
179
- * Fixed CSS issue affecting Firefox on WordPress 3.8
180
- * Added finnish translation (Contributor: Timo Leiniö)
181
- * Better handling of "More tag" button
182
- * Included JS dev version
183
-
184
- = 1.2.0 =
185
- * Fixed issue with WordPress widgets accessibility mode
186
- * Fixed compatibility issue with WPML plugin generating an error in debug mode
187
- * Fixed compatibility issue with WP Page Widget plugin
188
- * Added slovak translation (Contributor: Branco Radenovich - [WebHostingGeeks.com](http://webhostinggeeks.com/user-reviews/))
189
- * Tested compatibility with Worpdress 3.6 beta
190
-
191
- = 1.1.1 =
192
- * Fixed editor issue when dragging widgets from a sidebar to another
193
-
194
- = 1.1.0 =
195
- * Compatibility fixes for upcoming WordPress 3.5
196
- * Added support for the new WordPress media library dialog
197
- * Enhanced javascript event handling using jquery .on(...) method
198
-
199
- = 1.0.0 =
200
- * Added full image options when adding content from media library
201
- * Added german translation (Contributor: Christian Foellmann)
202
- * Overall Javascript code optimization
203
- * Better Javascript compression
204
- * Fixed editor background color
205
- * Fixed compatibility issue with "WP Page Widget" plugin
206
- * Fixed issue about editor partially hidden on narrow screens
207
-
208
- = 0.9.5 =
209
- * Added support for autoembed urls (youtube, etc)
210
-
211
- = 0.9.4 =
212
- * Bug fixes
213
-
214
- = 0.9.3 =
215
- * Added support for accessibility mode
216
-
217
- = 0.9.2 =
218
- * Optimized for use in conjunction with Ultimate TinyMCE plugin
219
-
220
- = 0.9.1 =
221
- * Added spanish translation (Contributor: Lucia García Martínez)
222
- * Increased width of editor window
223
-
224
- = 0.9 =
225
- * Added support for WPML plugin (for multilanguage sites)
226
-
227
- = 0.8.2 =
228
- * Added support for shortcodes in widget text
229
-
230
- = 0.8.1 =
231
- * Fixed issue when inserting images on WordPress 3.3
232
-
233
- = 0.8 =
234
- * Added support for WordPress networks (Multisite)
235
-
236
- = 0.7 =
237
- * Added compatibility for upcoming WordPress 3.3
238
- * Added compatibility for previous WordPress 3.0 and 3.1
239
- * Optimization/compression of javascript code
240
-
241
- = 0.6.5 =
242
- * Forced TinyMCE editor to not automatically add/remove paragraph tags when switching to HTML mode (you may need to re-edit your widgets to adjust linebreaks, if you were using multiple paragraphs)
243
-
244
- = 0.6.4 =
245
- * Fixed compatibility issue with Jetpack / After the Deadline plugin
246
- * Optimization of javascript/css loading
247
-
248
- = 0.6.3 =
249
- * Fixed javascript issue preventing the plugin from working correctly with some browsers
250
-
251
- = 0.6.2 =
252
- * Fixed javascript issue with WordPress Media Library inserts in HTML mode
253
-
254
- = 0.6.1 =
255
- * Fixed javascript issue preventing editor to show up in some cases
256
-
257
- = 0.6 =
258
- * Added support for WordPress Media Library
259
-
260
- = 0.5 =
261
- * First Beta release
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ === Black Studio TinyMCE Widget ===
2
+ Contributors: marcochiesi, thedarkmist
3
+ Donate link: http://www.blackstudio.it/en/wordpress-plugins/black-studio-tinymce-widget/
4
+ Tags: wysiwyg, widget, tinymce, editor, image, media, rich text, rich text editor, visual editor, wysiwyg editor, tinymce editor, widget editor, html editor, wysiwyg widget, html widget, editor widget, text widget, rich text widget, enhanced text widget, tinymce widget, visual widget, image widget, media widget
5
+ Requires at least: 3.1
6
+ Tested up to: 4.1
7
+ Stable tag: 2.0.0
8
+ License: GPLv3
9
+ License URI: http://www.gnu.org/licenses/gpl.html
10
+
11
+ The visual editor widget for Wordpress.
12
+
13
+ == Description ==
14
+
15
+ This plugin adds a new `Visual Editor` widget type that allows you to insert rich text and media objects in your sidebars with no hassle. The default WordPress text widget lacks of functionalities and it requires HTML knowledge, this plugin was born to overcome these limitations. With Black Studio TinyMCE Widget you will be able to edit your widgets in a WYSIWYG manner using the native WordPress TinyMCE editor, just like you do in posts and pages. And if you are a developer you may still switch back and forth from Visual to HTML mode.
16
+
17
+ = Features =
18
+
19
+ * Add rich text widgets to your sidebars and edit them using visual editor
20
+ * Switch between Visual mode and HTML mode (including Quicktags toolbar)
21
+ * Insert images/videos from WordPress Media Library
22
+ * Insert links to existing WordPress pages/posts or external resources
23
+ * Support for fullscreen editing mode
24
+ * Support for widgets accessibility mode
25
+ * Support for WordPress networks (multi-site)
26
+ * Support for WPML (multi-language)
27
+ * Live preview in theme customizer
28
+ * Available in 20+ languages
29
+
30
+ = Links =
31
+
32
+ * [Plugin's web page](http://www.blackstudio.it/en/wordpress-plugins/black-studio-tinymce-widget/)
33
+ * [FAQ](https://wordpress.org/plugins/black-studio-tinymce-widget/faq/)
34
+ * [Support forum](https://wordpress.org/support/plugin/black-studio-tinymce-widget)
35
+ * [Follow us on Twitter](https://twitter.com/blackstudioita)
36
+
37
+ = Get involved =
38
+
39
+ * Developers can contribute to the source code on our [GitHub repository](https://github.com/black-studio/black-studio-tinymce-widget).
40
+ * Translators can contribute through [Transifex](https://www.transifex.com/projects/p/black-studio-tinymce-widget/).
41
+ * Users can contribute by leaving a 5 stars [review](https://wordpress.org/support/view/plugin-reviews/black-studio-tinymce-widget#postform) or making a [donation](http://www.blackstudio.it/en/wordpress-plugins/black-studio-tinymce-widget/).
42
+
43
+ == Installation ==
44
+
45
+ This section describes how to install and use the plugin.
46
+
47
+ 1. Install automatically through the `Plugins` menu and `Add New` button (or upload the entire `black-studio-tinymce-widget` folder to the `/wp-content/plugins/` directory)
48
+ 2. Activate the plugin
49
+ 3. Go to `Appearance` => `Widgets`
50
+ 4. Drag and drop the `Visual Editor` widget to the desired sidebar (or, if using Accesibility mode, click the `Add` link)
51
+ 5. Fill in title and (rich) text
52
+
53
+ == Screenshots ==
54
+
55
+ 1. Black Studio TinyMCE Widget in Visual mode
56
+ 2. Black Studio TinyMCE Widget in HTML mode
57
+ 3. Black Studio TinyMCE Widget combined with WP Edit plugin
58
+
59
+ == Frequently Asked Questions ==
60
+
61
+ = Troubleshooting =
62
+
63
+ If you are experiencing issues with the plugin please read entirely these FAQ before posting a new topic in our [support forum](http://wordpress.org/support/plugin/black-studio-tinymce-widget). Most of the times issues are caused by incompatibility with other plugins or themes, which may prevent our plugin from working as expected. In order to troubleshoot issues please complete the following steps:
64
+
65
+ 1. First, ensure you have understood the purpose of the plugin. What this plugin does is to give you the ability to use the WordPress visual editor (TinyMCE) in widgets as you do in posts and pages, but it doesn't alter the editor behavior itself or its functionalities. So if you are experiencing issues with the editor even when editing posts or pages, they're definitely not related to our plugin (unless you're using some additional plugins that provides widgets support for pages, i.e. Page Builder).
66
+ 2. Ensure that you are running the latest versions of both WordPress and the plugin.
67
+ 3. Search in our [support forum](http://wordpress.org/support/plugin/black-studio-tinymce-widget) for threads with similar issues.
68
+ 4. Disable all other plugins and check if the problem is fixed. In that case enable the other plugins one by one and figure out which one is causing the issue. Please see [Conflict Diagnosis Guide for WordPress plugins](https://rtcamp.com/rtmedia/docs/troubleshooting/conflict-diagnosis-guide-wordpress-plugins/) for further info.
69
+ 5. If the problem persists even with all other plugins disabled, try to switch to a WordPress default theme (i.e. Twenty Fourteen) and check if that fixes the issue.
70
+
71
+ If you found a conflict with a plugin or theme, or if your problem is still present after the steps above, open a topic in the [support forum](http://wordpress.org/support/plugin/black-studio-tinymce-widget) and provide the following information:
72
+
73
+ * Detailed description of the problem, including the steps to reproduce it
74
+ * Error messages, if any, in particular in [browser's javascript console](http://webmasters.stackexchange.com/questions/8525/how-to-open-the-javascript-console-in-different-browsers)
75
+ * Browser and Operating System in use
76
+ * Plugin version in use
77
+ * WordPress version in use
78
+ * WordPress theme in use
79
+ * WordPress default language in use, if other than english
80
+ * WordPress plugins causing conflicts, if any
81
+ * A link to a screenshot, if it can be useful to understand the problem
82
+ * A link to your website, if it can be useful to show the problem
83
+
84
+ = Can't find it in my available widgets =
85
+
86
+ Since version 1.3.1 the name of the widget changed from `Black Studio TinyMCE Widget` to `Visual Editor` to enhance user friendliness. `Black Studio TinyMCE Widget` is still the name of the plugin, but it was a bit too long and not very intuitive for inexperienced users. You may find references to the old name in articles and videos on the web, so don't panic if you don't see the `Black Studio TinyMCE Widget` in your available widgets, just look for `Visual Editor`. Note: if you are using WordPress in a language other than english you may have a corresponding name translated in your language.
87
+
88
+ = Widgets disappeared after migrating or changing the site URL =
89
+
90
+ When dealing with a WordPress site URL change it is necessary to face the serialized fields issue: data may become corrupted if using a simple search/replace (see the [Codex](http://codex.wordpress.org/Moving_WordPress#When_Your_Domain_Name_or_URLs_Change) for further info). This is not an issue specifically related to our plugin, but it affects all the parts (plugins, themes and WordPress core files too) that use serialized data archiviation. When changing the site URL, the recommended way is to use the [Search and Replace for WordPress Databases Script](https://interconnectit.com/products/search-and-replace-for-wordpress-databases/), as suggested by the Codex.
91
+
92
+ = How to translate widgets using WPML =
93
+
94
+ The current version of `Black Studio TinyMCE Widget` plugin works together with the `WPML String translation` plugin. To translate a widget created with `Black Studio TinyMCE Widget` plugin you have to create it on the widgets panel and then go to `WPML` => `String translation` and translate the title and text from there (unfortunately the translation textarea has not the visual editor).
95
+ Note: If you installed WPML after the creation of the widgets, just re-save them and they will appear on the String translation list.
96
+
97
+ = How to embed video and other contents =
98
+
99
+ WordPress has a nice [autoembed feature](http://codex.wordpress.org/Embeds) that allows you to embed videos and other stuff in an easy way, by just putting the URL in the content area. This is also possible for widgets created with this plugin.
100
+ If you are using a version of WordPress prior to 4.0 or a version of Black Studio TinyMCE Widget prior to 2.0, for best results it is recommended to put the URL inside an `[embed]` shortcode. Example:
101
+ `[embed]http://www.youtube.com/watch?v=XXXXXXXXXXX[/embed]`
102
+ Ensure that the URL has not an hyperlink on it.
103
+ Alternatively, if you don't want to use `[embed]` shortcode, ensure that the URL is not surrounded by a `<p>` tag.
104
+
105
+ = How to customize widget HTML markup =
106
+
107
+ Most of the HTML markup around widgets is generated by WordPress and you can control it using the proper arguments (`class`, `before_widget`, `after_widget`, `before_title`, `after_title`) passed to the [`register_sidebar`](http://codex.wordpress.org/Function_Reference/register_sidebar) function (this is usually done by your theme). The only piece of HTML code added by the plugin is there for compatibility with the markup of native WordPress text widgets, and it is the following:
108
+ `<div class="textwidget"> ... widget text ... </div>`
109
+ You may customize it using the `black_studio_tinymce_before_text` and `black_studio_tinymce_after_text` filter hooks. They both take two parameters, the first one is the default text and the second is the widget instance. See examples below.
110
+
111
+ Example 1: Custom markup
112
+ `
113
+ add_filter( 'black_studio_tinymce_before_text', 'my_widget_before_text', 10, 2 );
114
+ function my_widget_before_text( $before_text, $instance ) {
115
+ return '<div class="myclass">';
116
+ }
117
+ add_filter( 'black_studio_tinymce_after_text', 'my_widget_after_text', 10, 2 );
118
+ function my_widget_after_text( $after_text, $instance ) {
119
+ return '</div>';
120
+ }
121
+ `
122
+
123
+ Example 2: Totally remove markup
124
+ `
125
+ add_filter( 'black_studio_tinymce_before_text', '__return_empty_string' );
126
+ add_filter( 'black_studio_tinymce_after_text', '__return_empty_string' );
127
+ `
128
+
129
+ = Plugin's data location and cleanup =
130
+
131
+ Plugin's data is stored in serialized format inside a record in the `wp_options` table having `option_name` = `'widget_black-studio-tinymce'`. Data storage is handled by WordPress and not directly by the plugin itslef. The widgets data is intentionally kept in the datatbase upon plugin deactivation / deletion to avoid content loss. If you want to totally remove the plugin including its data, just remove that record after plugin removal.
132
+
133
+ == Changelog ==
134
+
135
+ = 2.0.0 (2014-10-06) =
136
+ * Total refactoring of plugin's source code
137
+ * Enhanced integration with TinyMCE editor for better compatibility with other plugins
138
+ * Added support for QuickTags toolbar in HTML mode
139
+ * Added support for mobile devices (responsive width in widgets administration page)
140
+ * Added project to [GitHub](https://github.com/black-studio/black-studio-tinymce-widget)
141
+ * Added project to [Transifex](https://www.transifex.com/projects/p/black-studio-tinymce-widget/) translation platform
142
+ * Added many new translations thanks to [WP-Translation.org](http://wp-translations.org/) team
143
+ * Added several filter and action hooks
144
+ * Improved code quality and security thanks to [Scrutinizer](https://scrutinizer-ci.com/g/black-studio/black-studio-tinymce-widget/) service
145
+ * Improved development workflow thanks to [Grunt](http://gruntjs.com/)
146
+ * Improved performance and user experience
147
+ * A huge Thanks to @cfoellmann for his precious support and contributions
148
+
149
+ = 1.4.8 (2014-09-13) =
150
+ * Fixed bug on image captions on WordPress 4.0 (part 2)
151
+
152
+ = 1.4.7 (2014-09-11) =
153
+ * Fixed bug on image captions on WordPress 4.0
154
+
155
+ = 1.4.6 (2014-07-25) =
156
+ * Bugfix on widget display
157
+
158
+ = 1.4.5 (2014-07-25) =
159
+ * Fixed compatibility issue with Page Builder + WPML String Translation
160
+
161
+ = 1.4.4 (2014-07-16) =
162
+ * Fixed z-index compatibility issue with Shortcodes Ultimate plugin
163
+
164
+ = 1.4.3 (2014-07-13) =
165
+ * Added filter hooks to modify the markup before and after the widget text
166
+ * Fixed z-index issue in fullscreen mode
167
+ * Added widget icon for theme customizer
168
+ * Updated danish translation
169
+ * Updated FAQ and readme.txt
170
+
171
+ = 1.4.2 (2014-07-07) =
172
+ * Added support for `wp_enqueue_editor` hook
173
+ * Added compatibility with Advanced Image Styles plugin
174
+ * Added danish translation (Contributor: Mikkel Rommelhoff)
175
+
176
+ = 1.4.1 (2014-06-12) =
177
+ * Enhanced HTML source code formatting
178
+
179
+ = 1.4 (2014-06-12) =
180
+ * HTML and CSS optimization by using WordPress native editor markup and styles
181
+ * Adoption of WordPress JS minification conventions (`.min` suffix)
182
+ * Integration with WordPress SCRIPT_DEBUG constant for javascript debugging purposes
183
+ * Enhanced compatibility with 3rd party media buttons provider (i.e. Shortcodes Ultimate)
184
+ * Enhanced plugin internal version handling
185
+ * Duplicated widget IDs detection
186
+ * Added Rate link
187
+ * Added compatibility with WordPress Language packs
188
+ * Added ukrainian translation (Contributor: Michael Yunat [getvoip.com](http://getvoip.com/blog))
189
+ * Fixed notice on theme_advanced_buttons1 parameter
190
+ * Fixed z-index issue with WordPress 3.9 admin menu on small screens
191
+
192
+ = 1.3.3 (2014-04-04) =
193
+ * Fixed visualization bug upon widget saving
194
+ * Enhanced support WordPress 3.9 Theme Customizer (live edit)
195
+
196
+ = 1.3.2 (2014-04-03) =
197
+ * Fixed compatibility issue with WordPress 3.9 Beta 3
198
+ * Added support for WordPress 3.9 Theme Customizer
199
+ * Added swedish translation (Contributor: macsolve)
200
+ * Updated installation documentation
201
+ * Updated FAQ
202
+
203
+ = 1.3.1 (2014-03-06) =
204
+ * Renamed the widget to `Visual Editor` for better user friendliness
205
+ * Fixed compatibility issue with FirmaSite Theme Enhancer plugin
206
+
207
+ = 1.3.0 (2014-01-29) =
208
+ * Added support for smilies conversion (based on the general WordPress option)
209
+ * Updated styling to match the new default WordPress editor appearence
210
+ * Refactoring of PHP and JS code to be compliant to WordPress coding standard
211
+ * Fixed compatibility issue with WordPress 3.9 alpha and TinyMCE 4.0
212
+ * Fixed compatibility issue with Jetpack / After the Deadline plugin
213
+ * Fixed editor behavior on widget title clicks
214
+ * Fixed CSS issue affecting Firefox on WordPress 3.8
215
+ * Added finnish translation (Contributor: Timo Leiniö)
216
+ * Better handling of More tag button
217
+ * Included JS dev version
218
+
219
+ = 1.2.0 (2013-05-04) =
220
+ * Fixed issue with WordPress widgets accessibility mode
221
+ * Fixed compatibility issue with WPML plugin generating an error in debug mode
222
+ * Fixed compatibility issue with WP Page Widget plugin
223
+ * Added slovak translation (Contributor: Branco Radenovich - [WebHostingGeeks.com](http://webhostinggeeks.com/user-reviews/))
224
+ * Tested compatibility with Worpdress 3.6 beta
225
+
226
+ = 1.1.1 (2012-12-31) =
227
+ * Fixed editor issue when dragging widgets from a sidebar to another
228
+
229
+ = 1.1.0 (2012-11-15) =
230
+ * Compatibility fixes for upcoming WordPress 3.5
231
+ * Added support for the new WordPress media library dialog
232
+ * Enhanced javascript event handling using jquery .on(...) method
233
+
234
+ = 1.0.0 (2012-10-19) =
235
+ * Added full image options when adding content from media library
236
+ * Added german translation (Contributor: Christian Foellmann)
237
+ * Overall Javascript code optimization
238
+ * Better Javascript compression
239
+ * Fixed editor background color
240
+ * Fixed compatibility issue with WP Page Widget plugin
241
+ * Fixed issue about editor partially hidden on narrow screens
242
+
243
+ = 0.9.5 (2012-10-01) =
244
+ * Added support for autoembed urls (youtube, etc)
245
+
246
+ = 0.9.4 (2012-07-31) =
247
+ * Bug fixes
248
+
249
+ = 0.9.3 (2012-07-31) =
250
+ * Added support for accessibility mode
251
+
252
+ = 0.9.2 (2012-07-27) =
253
+ * Optimized for use in conjunction with Ultimate TinyMCE plugin
254
+
255
+ = 0.9.1 (2012-06-07) =
256
+ * Added spanish translation (Contributor: Lucia García Martínez)
257
+ * Increased width of editor window
258
+
259
+ = 0.9 (2012-01-20) =
260
+ * Added support for WPML plugin (for multilanguage sites)
261
+
262
+ = 0.8.2 (2011-12-21) =
263
+ * Added support for shortcodes in widget text
264
+
265
+ = 0.8.1 (2011-12-20) =
266
+ * Fixed issue when inserting images on WordPress 3.3
267
+
268
+ = 0.8 (2011-11-29) =
269
+ * Added support for WordPress networks (Multisite)
270
+
271
+ = 0.7 (2011-11-24) =
272
+ * Added compatibility for upcoming WordPress 3.3
273
+ * Added compatibility for previous WordPress 3.0 and 3.1
274
+ * Optimization/compression of javascript code
275
+
276
+ = 0.6.5 (2011-11-17) =
277
+ * Forced TinyMCE editor to not automatically add/remove paragraph tags when switching to HTML mode (you may need to re-edit your widgets to adjust linebreaks, if you were using multiple paragraphs)
278
+
279
+ = 0.6.4 (2011-11-14) =
280
+ * Fixed compatibility issue with Jetpack / After the Deadline plugin
281
+ * Optimization of javascript/css loading
282
+
283
+ = 0.6.3 (2011-11-13) =
284
+ * Fixed javascript issue preventing the plugin from working correctly with some browsers
285
+
286
+ = 0.6.2 (2011-11-12) =
287
+ * Fixed javascript issue with WordPress Media Library inserts in HTML mode
288
+
289
+ = 0.6.1 (2011-11-12) =
290
+ * Fixed javascript issue preventing editor to show up in some cases
291
+
292
+ = 0.6 (2011-11-11) =
293
+ * Added support for WordPress Media Library
294
+
295
+ = 0.5 (2011-11-10) =
296
+ * First Beta release
297
+
298
+ == Upgrade Notice ==
299
+
300
+ = 2.0.0 =
301
+ 2.0 is a major update. If you are upgrading from version 1.x please ensure to backup your database before upgrading.
screenshot-1.png DELETED
Binary file
screenshot-2.png DELETED
Binary file