From 974c494795f273616bd411c7ea4fdcf8165cedd9 Mon Sep 17 00:00:00 2001 From: Florent Bruneau Date: Tue, 8 Mar 2011 22:15:52 +0100 Subject: [PATCH] Fix bad position of the popup in case of window resizing. Signed-off-by: Florent Bruneau --- htdocs/javascript/xorg.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/htdocs/javascript/xorg.js b/htdocs/javascript/xorg.js index 20221e2..0bd885f 100644 --- a/htdocs/javascript/xorg.js +++ b/htdocs/javascript/xorg.js @@ -882,7 +882,6 @@ function sendTestEmail(token, hruid) function buildPopup(input, destination, linkBindFunction) { - var pos = findPos(input.get(0)); var $popup = destination; var selected = null; var hovered = 0; @@ -932,7 +931,6 @@ function sendTestEmail(token, hruid) position: 'absolute', width: '300px', top: input.css('bottom'), - left: pos.x - 300 + input.width(), clear: 'both', 'text-align': 'left' }); @@ -951,7 +949,8 @@ function sendTestEmail(token, hruid) }, show: function() { - $popup.show(); + var pos = findPos(input.get(0)); + $popup.css('left', pos.x - 300 + input.width()).show(); return true; }, -- 2.1.4