diff --git a/livesupport/modules/htmlUI/var/templates/script/alttext.js.tpl b/livesupport/modules/htmlUI/var/templates/script/alttext.js.tpl index 19a6c6fa1..d58917242 100755 --- a/livesupport/modules/htmlUI/var/templates/script/alttext.js.tpl +++ b/livesupport/modules/htmlUI/var/templates/script/alttext.js.tpl @@ -44,6 +44,8 @@ if (clickY + alttextHeight > winY + scrollY) var yPos = winY - alttextHeight + scrollY; else var yPos = clickY; + if (yPos < scrollY) yPos = scrollY; + alttexthide = false; setTimeout("showalttextnow("+xPos+", "+yPos+")"); document.onmouseover = null; diff --git a/livesupport/modules/htmlUI/var/templates/script/contextmenu.js.tpl b/livesupport/modules/htmlUI/var/templates/script/contextmenu.js.tpl index b50d0e917..3f6070101 100755 --- a/livesupport/modules/htmlUI/var/templates/script/contextmenu.js.tpl +++ b/livesupport/modules/htmlUI/var/templates/script/contextmenu.js.tpl @@ -152,6 +152,9 @@ if (clickY + contextmenuHeight > winY + scrollY) var yPos = clickY - contextmenuHeight; else var yPos = clickY; + if (yPos < scrollY) yPos = scrollY; + + setTimeout("document.getElementById('contextmenu').style.left = "+xPos+"; document.getElementById('contextmenu').style.top = "+yPos+";", 10); contextmenuStatus = 1; document.onclick = hidecontextmenu;