Sha256: 064918e5e1103067fd972f53af11b01b8dbe0ba04d4af5b6527cf821b6bc222a
Contents?: true
Size: 1.52 KB
Versions: 9
Compression:
Stored size: 1.52 KB
Contents
/*jslint evil: true */ /** WYMeditor.hovertools ==================== A hovertools plugin. */ WYMeditor.editor.prototype.hovertools = function() { var wym = this; wym.status(' '); // Bind events on buttons jQuery(wym._box).find(wym._options.toolSelector).hover( function() { var button = this; wym.status(jQuery(button).html()); }, function() { wym.status(' '); } ); // Classes: add/remove a style attr to matching elems // while mouseover/mouseout jQuery(wym._box).find(wym._options.classSelector).hover( function() { var button = this, aClasses = eval(wym._options.classesItems), sName = jQuery(button).attr(WYMeditor.NAME), oClass = WYMeditor.Helper._getFromArrayByName(aClasses, sName); if (oClass){ jqexpr = oClass.expr; // Don't use jQuery.find() on the iframe body // because of MSIE + jQuery + expando issue (#JQ1143) if (!WYMeditor.isInternetExplorerPre11()) { wym.$body().find(jqexpr).css('background-color','#cfc'); } } }, function() { // Don't use jQuery.find() on the iframe body // because of MSIE + jQuery + expando issue (#JQ1143) if (!WYMeditor.isInternetExplorerPre11()) { wym.$body().find('*').removeAttr('style'); } } ); };
Version data entries
9 entries across 9 versions & 1 rubygems