dpillot 2005/12/16 17:14:38 CET
Modified files:
core/src/webapp/jsp/jahia/javascript jahia.js
Log:
check to adapt the size of engines windows to small screens
http://www.jahia.org/jira/browse/JAHIA-594
Revision Changes Path
1.9 +12 -2 jahia/core/src/webapp/jsp/jahia/javascript/jahia.js
http://jahia.mine.nu:8080/cgi-bin/cvsweb.cgi/jahia/core/src/webapp/jsp/jahia/javascript/jahia.js.diff?r1=1.8&r2=1.9&f=h
Index: jahia.js
===================================================================
RCS file:
/home/cvs/repository/jahia/core/src/webapp/jsp/jahia/javascript/jahia.js,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- jahia.js 22 Nov 2005 15:57:02 -0000 1.8
+++ jahia.js 16 Dec 2005 16:14:38 -0000 1.9
@@ -9,6 +9,8 @@
// This ensure that when the page
is closed or unloaded,any engine popup that is left open is closed !!!!
// Whitout that, more than one
engine can be left open and this means -> possible engine session conflict !!!!
// MC 30.08.2005 Removed matrix param
+//
+// $Id: jahia.js,v 1.9 2005/12/16 16:14:38 dpillot Exp $
// global popup
@@ -18,7 +20,10 @@
function OpenJahiaWindow( url, name, width, height )
{
var params;
- if (screen.availHeight <= 600) {
+ // check for veryvery small screens
+ if (screen.availHeight <= 712 || screen.availWidth <= 940) {
+ width=screen.availWidth;
+ height=screen.availHeight;
params = "width=" + width + ",height=" + height +
",resizable=yes,scrollbars=yes,status=no";
} else {
params = "width=" + width + ",height=" + height +
",resizable=yes,scrollbars=no,status=no";
@@ -49,8 +54,13 @@
function OpenJahiaScrollableWindow( url, name, width, height )
{
- var params = "width=" + width + ",height=" + height +
",resizable=1,scrollbars=1,status=0";
+ // check for veryvery small screens
+ if (screen.availHeight <= 712 || screen.availWidth <= 940) {
+ width=screen.availWidth;
+ height=screen.availHeight;
+ }
+ var params = "width=" + width + ",height=" + height +
",resizable=1,scrollbars=1,status=0";
// Check if the popup is alread opened, if so, give it the focus
if ( myEngineWin != null ){
if ( myEngineWin.closed ){ // need to test it first...