Dotclear

Changeset 3826:e2716fb376e6 for plugins


Ignore:
Timestamp:
08/26/18 19:10:29 (7 years ago)
Author:
franck <carnet.franck.paul@…>
Branch:
default
Message:

Activate dcLegacyEditor (if it is the HTML editor set in user pref) for new instances of widgets having textarea in settings.
Doing same for CKEditor seems to be a little bit harder than that, may be completed in future…

Location:
plugins/widgets
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • plugins/widgets/index.php

    r3825 r3826  
    223223} 
    224224if ($rte_flag) { 
     225    echo dcPage::jsVars(array('dotclear.widget_noeditor' => 0)); 
    225226    echo $core->callBehavior('adminPostEditor', $widget_editor['xhtml'], 'widget', 
    226227        array('#sidebarsWidgets textarea:not(.noeditor)'), 'xhtml'); 
     228} else { 
     229    echo dcPage::jsVars(array('dotclear.widget_noeditor' => 1)); 
    227230} 
    228231echo (dcPage::jsConfirmClose('sidebarsWidgets')); 
  • plugins/widgets/js/dragdrop.js

    r3709 r3826  
    7171        'width': $('#widgets-ref > li').css('width') 
    7272      }); 
     73    }, 
     74    stop: function(event, ui) { 
     75      if (!dotclear.widget_noeditor) { 
     76        ui.helper.find('textarea:not(.noeditor)').each(function() { 
     77          if ($.isFunction(jsToolBar)) { 
     78            var tbWidgetText = new jsToolBar(this); 
     79            tbWidgetText.draw('xhtml'); 
     80          } 
     81        }) 
     82      } 
    7383    } 
    7484  }); 
Note: See TracChangeset for help on using the changeset viewer.

Sites map