diff --git a/include/class_tabs.inc b/include/class_tabs.inc
index 9c0ebfd560b258cee81aa4adebb47a101a4b341f..fc1af5227fff3637bc355cc45634c6d7ab86c5bd 100644 (file)
--- a/include/class_tabs.inc
+++ b/include/class_tabs.inc
var $disabled= "";
var $by_name= array();
var $by_object= array();
+ var $SubDialog = false;
function tabs($config, $data, $dn)
{
}
/* Paint tab */
- $display.= "<td style=\"vertical-align:bottom; width:100px;\">";
+ $display.= "<td style=\"vertical-align:bottom;width:1px;\">";
/* Shorten string if its too long for the tab headers*/
- $title= _($name);
- if (mb_strlen($title, 'UTF-8') > 14){
- $title= mb_substr($title,0, 12, 'UTF-8')."...";
+ $title= '<nobr>'._($name).'</nobr>';
+ if (mb_strlen($title, 'UTF-8') > 28){
+ $title= mb_substr($title,0, 25, 'UTF-8')."...";
}
if ($_SESSION['js']==FALSE){
function delete()
{
+ /* Check if all plugins will ACK for deletion */
+ foreach (array_reverse($this->by_object) as $key => $obj){
+ $reason= $obj->allow_remove();
+ if ($reason != ""){
+ print_red(sprintf(_("Delete process has been canceled by plugin '%s': %s"), $key, $reason));
+ return;
+ }
+ }
+
/* Delete for all plugins */
foreach (array_reverse($this->by_object) as $key => $obj){
$obj->remove_from_parent();
function saveCopyDialog()
{
foreach ($this->by_object as $key => $obj){
- $this->by_object[$key]->saveCopyDialog();
+ if($obj->is_account){
+ $this->by_object[$key]->saveCopyDialog();
+ }
}
}
function getCopyDialog()
{
$ret = "";
+ $this->SubDialog = false;
foreach ($this->by_object as $key => $obj){
- $ret .= $this->by_object[$key]->getCopyDialog();
+ if($obj->is_account){
+ $tmp = $this->by_object[$key]->getCopyDialog();
+ if($tmp['status'] == "SubDialog"){
+ $this->SubDialog = true;
+ return($tmp['string']);
+ }else{
+ $ret .= $tmp['string'];
+ }
+ }
}
return($ret);
}
+
+ function addSpecialTabs()
+ {
+ $this->by_name['acl']= _("ACL");
+ $this->by_object['acl']= new acl($this->config, $this, $this->dn);
+ $this->by_object['acl']->parent= &$this;
+ $this->by_name['reference']= _("References");
+ $this->by_object['reference']= new reference($this->config, $this->dn);
+ $this->by_object['reference']->parent= &$this;
+ }
+
+
}
?>