|
@@ -25,9 +25,11 @@
|
|
|
hoverIntent: {sensitivity: 10, interval: 300, timeout: 50},
|
|
|
positionTop: 12,
|
|
|
positionLeft: 12,
|
|
|
- tooltipID: 'smf_tooltip',
|
|
|
- tooltipClass: 'tooltip',
|
|
|
- tooltipTextID: 'smf_tooltipText'
|
|
|
+ tooltipID: 'smf_tooltip',
|
|
|
+ tooltipTextID: 'smf_tooltipText',
|
|
|
+ tooltipClass: 'tooltip',
|
|
|
+ tooltipSwapClass: 'smf_swaptip',
|
|
|
+ tooltipContent: 'html'
|
|
|
};
|
|
|
|
|
|
|
|
@@ -36,7 +38,7 @@
|
|
|
|
|
|
$(this).each(function()
|
|
|
{
|
|
|
- var sTitle = $('<span class="' + oSettings.tooltipClass + '">' + this.title + '</span>').hide();
|
|
|
+ var sTitle = $('<span class="' + oSettings.tooltipSwapClass + '">' + this.title + '</span>').hide();
|
|
|
$(this).append(sTitle).attr('title', '');
|
|
|
});
|
|
|
|
|
@@ -128,8 +130,8 @@
|
|
|
|
|
|
function smf_tooltip_on(event)
|
|
|
{
|
|
|
-
|
|
|
- if ($(this).children('.' + oSettings.tooltipClass).text())
|
|
|
+
|
|
|
+ if ($(this).children('.' + oSettings.tooltipSwapClass).text())
|
|
|
{
|
|
|
|
|
|
$('body').append('<div id="' + oSettings.tooltipID + '" class="' + oSettings.tooltipClass + '"><div id="' + oSettings.tooltipTextID + '" style="display:none;"></div></div>');
|
|
@@ -137,12 +139,16 @@
|
|
|
|
|
|
var $tt = $('#' + oSettings.tooltipID);
|
|
|
var $ttContent = $('#' + oSettings.tooltipID + ' #' + oSettings.tooltipTextID);
|
|
|
-
|
|
|
-
|
|
|
- $ttContent.text($(this).children('.' + oSettings.tooltipClass).text());
|
|
|
- $tt.show();
|
|
|
+
|
|
|
+ if (oSettings.tooltipContent == 'html')
|
|
|
+ $ttContent.html($(this).children('.' + oSettings.tooltipSwapClass).html());
|
|
|
+ else
|
|
|
+ $ttContent.text($(this).children('.' + oSettings.tooltipSwapClass).text());
|
|
|
+
|
|
|
+ oSettings.tooltipContent
|
|
|
|
|
|
|
|
|
+ $tt.show();
|
|
|
showTooltip();
|
|
|
positionTooltip(event);
|
|
|
}
|