id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc
708	HQ Resolution Fix/patch for Xinha/ImageManager	Rolf	yermol	"This makes the ImageManager resize to show more pictures inside the iframe if the resolution on the client pc is good.

Ofcorse you need to copy plugins/ImageManager/assets/manager.css to plugins/ImageManager/assets/managerHQ.css and edit it to fit the screen.

Changed this in plugins/ImageManager/assets/managerHQ.css:
{{{
form { padding: 0px;  margin: 0 auto; width: 1150px;}
[...]
.imageFrame { width: 100%; height: 550px; margin: 0 auto; margin-top: 1em; background-color: White;}
}}}

Changes in plugins/ImageManager/manager.php:
{{{
[...]
 <link href=""<?php print $IMConfig['base_url'];?>assets/manager<?=($_COOKIE[""HQ""])?""HQ"":""""; ?>.css"" rel=""stylesheet"" type=""text/css"" />
<script type=""text/javascript"" src=""../../popups/popup.js""></script>
<script type=""text/javascript"" src=""assets/popup.js""></script>
<script type=""text/javascript"" src=""../../popups/color_picker.js""></script>
<script type=""text/javascript"" src=""<?php print $IMConfig['base_url'];?>assets/dialog.js""></script>

<script type=""text/javascript"">
 var today = new Date();
 var expire = new Date();
if ((screen.width>=1200) && (screen.height>=900))
{
 <? if (!$_COOKIE[""HQ""]) { ?>
 alert('High resolution detected ('+screen.width+'x'+screen.height+'). Setting HQ Cookie..');
 expire.setTime(today.getTime() + 3600000*24*5);
 document.cookie = ""HQ=1"" + "";expires=""+expire.toGMTString();
 document.location=document.location;
<? } ?>
} else {
 <? if ($_COOKIE[""HQ""]) { ?>
 alert('Resolution changed! ('+screen.width+'x'+screen.height+'). Deleting HQ Cookie..');
 expire.setTime(today.getTime() - 1);
 document.cookie = ""HQ=0"" + "";expires=""+expire.toGMTString();
 document.location=document.location;
<? } ?>
}
</script>
[...]
}}}

The plugins/ImageManager/editor.php could be changed to:
{{{
//      window.resizeTo(673, 531);  * old
        window.resizeTo((screen.width*0.9), (screen.height*0.9));
}}}

The plugins/ImageManager/assets/editor.css could be:

{{{
[...]
               #tools
                {
                        width: 100%;
[...]
               #toolbar
                {
                        width: 53px;
                        height: 100%;
[...]

                #contents
                {
                        width: 100%;
                        height: 100%;
                        position: absolute;
                        left: 64px; top: 51px;
                }

                #editor
                {
                        width: 100%;
                        height: 100%;
                }
[...]
#bottom
{
        position: relative;
        top: 100%;
}

}}}"	defect	closed	normal		Plugin_ImageManager	trunk	normal	invalid		
