Plugin Directory

Changeset 934715


Ignore:
Timestamp:
06/18/2014 09:10:16 PM (12 years ago)
Author:
ihouse
Message:

Fix MCE button in Wordpress 3.9

File:
1 edited

Legend:

Unmodified
Added
Removed
  • idxpro/trunk/tinymce/editor_plugin.js

    r717451 r934715  
    3636
    3737            // Register idxpro_embed button
    38             /*ed.addButton('idxpro_embed', {
     38            ed.addButton('idxpro_embed', {
    3939                title : 'Embed IDXPro Application or Widget',
    4040                //cmd : 'mceidxpro_embed',
     
    5050                        ed.execCommand('mceInsertContent', false, "[idxpro]");
    5151                }
    52             });*/
     52            });
    5353
    5454            // Add a node change handler, selects the button in the UI when a image is selected
     
    6868         * @return {tinymce.ui.Control} New control instance or null if no control was created.
    6969         */
    70         createControl : function(n, cm) {
    71             switch (n) {
    72                 case 'idxpro_embed':
    73                 {
    74                             c = cm.createSplitButton(n, {title : 'IDXPro', image : pl_url + '/idxpro_button.png'});
    75                             c.onRenderMenu.add( function(c, m) {
    76                                 each( idx_widget_buttons, function( v, k ) { m.add( { title : v.title, onclick : function() { tinyMCE.activeEditor.execCommand( 'mceInsertContent', false, v.value);  }  } ).setDisabled( 0 ); } );
    77                             } );
    78                     return c;
    79                 }
    80             }
    81             return null;
    82         },
     70//      createControl : function(n, cm) {
     71//          switch (n) {
     72//              case 'idxpro_embed':
     73//              {
     74//                          c = cm.createSplitButton(n, {title : 'IDXPro', image : pl_url + '/idxpro_button.png'});
     75//                          c.onRenderMenu.add( function(c, m) {
     76//                              each( idx_widget_buttons, function( v, k ) { m.add( { title : v.title, onclick : function() { tinyMCE.activeEditor.execCommand( 'mceInsertContent', false, v.value);  }  } ).setDisabled( 0 ); } );
     77//                          } );
     78//                  return c;
     79//              }
     80//          }
     81//          return null;
     82//      },
    8383
    8484        /**
Note: See TracChangeset for help on using the changeset viewer.