From 3931c5fcf342563a2a1cbbf517a94393f5e43f01 Mon Sep 17 00:00:00 2001 From: zero Date: Sun, 1 Apr 2007 11:27:01 +0000 Subject: [PATCH] git-svn-id: http://xe-core.googlecode.com/svn/trunk@853 201d5d3c-b55e-5fd7-737f-ddc643e51545 --- common/css/default.css | 26 ++++++++++++++------------ common/js/common.js | 24 ++++++++++-------------- common/tpl/common_layout.html | 8 +++++--- 3 files changed, 29 insertions(+), 29 deletions(-) diff --git a/common/css/default.css b/common/css/default.css index edae4fc63..cf282cbe8 100644 --- a/common/css/default.css +++ b/common/css/default.css @@ -88,6 +88,18 @@ h6 { visibility:hidden; } +#fororiginalimageareabg { + z-index:1001; + background-color:#FFFFFF; + width:100%; + height:100%; + top:0px; + left:0px; + position:relative; + padding:10px; + border:1px solid #000000; +} + #fororiginalimagearea { visibility:hidden; padding:0px; @@ -106,20 +118,10 @@ h6 { z-index:1002; } -#fororiginalimageareabg { - z-index:1001; - background-color:#000000; - width:100%; - height:100%; - top:0px; - left:0px; - position:relative; -} - #closeOriginalImageBtn { position:absolute; - right:10px; - top:10px; + right:5px; + top:5px; cursor:pointer; width:60px; height:20px; diff --git a/common/js/common.js b/common/js/common.js index f17a31341..ea146563f 100644 --- a/common/js/common.js +++ b/common/js/common.js @@ -248,39 +248,34 @@ function showOriginalImage(evt) { var orig_image = xGetElementById("fororiginalimage"); var tmp_image = new Image(); tmp_image.src = src; + var image_width = tmp_image.width; + var image_height = tmp_image.height; - orig_image.style.position = "absolute"; orig_image.style.margin = "0px 0px 0px 0px"; - orig_image.style.cursor = "pointer"; + orig_image.style.cursor = "move"; orig_image.src = src; - orig_image.style.opacity = 1; - orig_image.style.filter = 'alpha(opacity=100)'; var areabg = xGetElementById("fororiginalimageareabg"); - areabg.style.opacity = 0.90; - areabg.style.filter = 'alpha(opacity=90)'; areabg.style.visibility = "visible"; + xWidth(areabg, image_width+22); + xHeight(areabg, image_height+22); var area = xGetElementById("fororiginalimagearea"); - xLeft(area, xScrollLeft()); xTop(area, xScrollTop()); xWidth(area, xWidth(document)); xHeight(area, xHeight(document)); area.style.visibility = "visible"; - var area_width = xWidth(area); var area_height = xHeight(area); - var image_width = tmp_image.width; - var image_height = tmp_image.height; var x = parseInt((area_width-image_width)/2,10); var y = parseInt((area_height-image_height)/2,10); if(x<0) x = 0; if(y<0) y = 0; - xLeft(orig_image, x); - xTop(orig_image, y); + xLeft(areabg, x); + xTop(areabg, y); var sel_list = xGetElementsByTagName("select"); for (var i = 0; i < sel_list.length; ++i) sel_list[i].style.visibility = "hidden"; @@ -332,8 +327,9 @@ function origImageDrag(obj, px, py) { var x = px - obj.startX; var y = py - obj.startY; - xLeft(obj, xLeft(obj)+x); - xTop(obj, xTop(obj)+y); + var areabg = xGetElementById("fororiginalimageareabg"); + xLeft(areabg, xLeft(areabg)+x); + xTop(areabg, xTop(areabg)+y); obj.startX = px; obj.startY = py; diff --git a/common/tpl/common_layout.html b/common/tpl/common_layout.html index 175e5b806..93641cd21 100644 --- a/common/tpl/common_layout.html +++ b/common/tpl/common_layout.html @@ -2,6 +2,7 @@ + {Context::getBrowserTitle()} @@ -25,9 +26,10 @@ {Context::getHtmlFooter()}
{$lang->msg_call_server}
- original image - close original image -
+
+ original image + close original image +