pmaTooltip(): no return value, additional check
This commit is contained in:
@@ -8,6 +8,7 @@ $Source$
|
|||||||
2005-11-14 Sebastian Mendel <cybot_tm@users.sourceforge.net>
|
2005-11-14 Sebastian Mendel <cybot_tm@users.sourceforge.net>
|
||||||
* themes/*/css/theme_right.css.php, css/phpmyadmin.css.php:
|
* themes/*/css/theme_right.css.php, css/phpmyadmin.css.php:
|
||||||
bug #1342683 Wrong URL to error.ico
|
bug #1342683 Wrong URL to error.ico
|
||||||
|
* libraries/tooltip.js: no return value, additional check
|
||||||
|
|
||||||
2005-11-13 Michal Čihař <michal@cihar.com>
|
2005-11-13 Michal Čihař <michal@cihar.com>
|
||||||
* Documentation.html, config.default.php, main.php, server_links.inc.php,
|
* Documentation.html, config.default.php, main.php, server_links.inc.php,
|
||||||
|
@@ -43,10 +43,10 @@ function textTooltip(theText) {
|
|||||||
layerNS4.write(theText);
|
layerNS4.write(theText);
|
||||||
layerNS4.close();
|
layerNS4.close();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var integer
|
* @var integer
|
||||||
*/
|
*/
|
||||||
var ttTimerID = 0;
|
var ttTimerID = 0;
|
||||||
|
|
||||||
@@ -127,7 +127,7 @@ function moveTooltip(posX, posY) {
|
|||||||
*
|
*
|
||||||
* @param string theText tooltip content
|
* @param string theText tooltip content
|
||||||
*/
|
*/
|
||||||
function pmaTooltip(theText) {
|
function pmaTooltip( theText ) {
|
||||||
// reference to TooltipContainer
|
// reference to TooltipContainer
|
||||||
if ( null == myTooltipContainer ) {
|
if ( null == myTooltipContainer ) {
|
||||||
if (ttNS4) {
|
if (ttNS4) {
|
||||||
@@ -137,10 +137,14 @@ function pmaTooltip(theText) {
|
|||||||
} else if (ttDOM) {
|
} else if (ttDOM) {
|
||||||
myTooltipContainer = document.getElementById('TooltipContainer');
|
myTooltipContainer = document.getElementById('TooltipContainer');
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ( typeof( myTooltipContainer ) == 'undefined' ) {
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
var plusX=0, plusY=0, docX=0; docY=0;
|
var plusX=0, plusY=0, docX=0; docY=0;
|
||||||
var divHeight = myTooltipContainer.clientHeight;
|
var divHeight = myTooltipContainer.clientHeight;
|
||||||
var divWidth = myTooltipContainer.clientWidth;
|
var divWidth = myTooltipContainer.clientWidth;
|
||||||
@@ -160,15 +164,15 @@ function pmaTooltip(theText) {
|
|||||||
docX = document.body.clientWidth;
|
docX = document.body.clientWidth;
|
||||||
docY = document.body.clientHeight;
|
docY = document.body.clientHeight;
|
||||||
}
|
}
|
||||||
|
|
||||||
ttXpos = ttXpos + plusX;
|
ttXpos = ttXpos + plusX;
|
||||||
ttYpos = ttYpos + plusY;
|
ttYpos = ttYpos + plusY;
|
||||||
|
|
||||||
if ((ttXpos + divWidth) > docX)
|
if ((ttXpos + divWidth) > docX)
|
||||||
ttXpos = ttXpos - (divWidth + (ttXadd * 2));
|
ttXpos = ttXpos - (divWidth + (ttXadd * 2));
|
||||||
if ((ttYpos + divHeight) > docY)
|
if ((ttYpos + divHeight) > docY)
|
||||||
ttYpos = ttYpos - (divHeight + (ttYadd * 2));
|
ttYpos = ttYpos - (divHeight + (ttYadd * 2));
|
||||||
|
|
||||||
textTooltip(theText);
|
textTooltip(theText);
|
||||||
moveTooltip((ttXpos + ttXadd), (ttYpos + ttYadd));
|
moveTooltip((ttXpos + ttXadd), (ttYpos + ttYadd));
|
||||||
holdTooltip();
|
holdTooltip();
|
||||||
|
Reference in New Issue
Block a user