2 * WYMeditor : what you see is What You Mean web-based editor
3 * Copyright (c) 2005 - 2009 Jean-Francois Hovinne, http://www.wymeditor.org/
4 * Dual licensed under the MIT (MIT-license.txt)
5 * and GPL (GPL-license.txt) licenses.
7 * For further information visit:
8 * http://www.wymeditor.org/
11 * jquery.wymeditor.hovertools.js
12 * hovertools plugin for WYMeditor
15 * Jean-Francois Hovinne (jf.hovinne a-t wymeditor dotorg)
19 WYMeditor.editor.prototype.hovertools = function() {
23 //bind events on buttons
24 jQuery(this._box).find(this._options.toolSelector).hover(
26 wym.status(jQuery(this).html());
33 //classes: add/remove a style attr to matching elems
34 //while mouseover/mouseout
35 jQuery(this._box).find(this._options.classSelector).hover(
37 var aClasses = eval(wym._options.classesItems);
38 var sName = jQuery(this).attr(WYMeditor.NAME);
39 var oClass = WYMeditor.Helper.findByName(aClasses, sName);
43 //don't use jQuery.find() on the iframe body
44 //because of MSIE + jQuery + expando issue (#JQ1143)
45 if(!jQuery.browser.msie)
46 jQuery(wym._doc).find(jqexpr).css('background-color','#cfc');
50 //don't use jQuery.find() on the iframe body
51 //because of MSIE + jQuery + expando issue (#JQ1143)
52 if(!jQuery.browser.msie)
53 jQuery(wym._doc).find('*').removeAttr('style');