2007-01-05 22:49:36 +01:00
|
|
|
<?php
|
2007-02-05 20:28:38 +01:00
|
|
|
require_once(EGW_INCLUDE_ROOT . '/phpgwapi/inc/class.dragdrop.inc.php');
|
2007-01-02 15:08:32 +01:00
|
|
|
|
2007-02-05 20:28:38 +01:00
|
|
|
if($GLOBALS['egw_info']['user']['preferences']['common']['enable_dragdrop'])
|
|
|
|
{
|
|
|
|
$dragdrop = new dragdrop();
|
2007-02-05 21:22:01 +01:00
|
|
|
$maxOffLeft = $this->sideboxwidth - 200;
|
|
|
|
$maxOffRight = 500 - $this->sideboxwidth;
|
|
|
|
$maxOffLeft < 0 && $maxOffLeft = 0;
|
|
|
|
$maxOffRight < 0 && $maxOffRight = 0;
|
2007-01-02 15:08:32 +01:00
|
|
|
|
2007-02-05 20:28:38 +01:00
|
|
|
$dragdrop->addCustom(
|
|
|
|
'thesideboxcolumn',
|
2007-02-05 21:22:01 +01:00
|
|
|
array('NO_DRAG')
|
2007-02-05 20:28:38 +01:00
|
|
|
);
|
|
|
|
|
|
|
|
$dragdrop->addCustom(
|
|
|
|
'sideresize',
|
2007-02-05 21:22:01 +01:00
|
|
|
array('CURSOR_W_RESIZE','HORIZONTAL','MAXOFFLEFT+'.$maxOffLeft,'MAXOFFRIGHT+'.$maxOffRight),
|
2007-02-05 20:28:38 +01:00
|
|
|
array('sideboxwidth'=>$this->sideboxwidth),
|
|
|
|
'phpgwapi.dragDropFunctions.dragSidebar',
|
|
|
|
'phpgwapi.dragDropFunctions.dropSidebar'
|
|
|
|
);
|
|
|
|
|
|
|
|
$dragdrop->setJSCode();
|
|
|
|
}
|