Subversion Repositories oidplus

Compare Revisions

Regard whitespace Rev 1124 → Rev 1123

/trunk/includes/classes/OIDplusObject.class.php
462,6 → 462,7
} else {
$ra_email = $row['ra_email'];
}
// TODO: have different icons for Leaf-Nodes
 
$dirs = glob(OIDplus::localpath().'plugins/'.'*'.'/objectTypes/'.$namespace.'/');
 
469,26 → 470,12
 
$dir = substr($dirs[0], strlen(OIDplus::localpath()));
 
if ($this->isRoot()) {
$icon = $dir . '/' . $this::treeIconFilename('root'); // see also OIDplusPagePublicObjects::get_treeicon_root()
} else {
// We use $this:: instead of self:: , because we want to call the overridden methods
if (OIDplus::authUtils()->isRaLoggedIn($ra_email)) {
if ($this->isLeafNode()) {
$icon = $dir . '/' . $this::treeIconFilename('own_leaf');
if (!file_exists($icon)) $icon = $dir . '/' . $this::treeIconFilename('own');
} else {
$icon = $dir . '/' . $this::treeIconFilename('own');
}
} else {
if ($this->isLeafNode()) {
$icon = $dir . '/' . $this::treeIconFilename('general_leaf');
if (!file_exists($icon)) $icon = $dir . '/' . $this::treeIconFilename('general');
} else {
$icon = $dir . '/' . $this::treeIconFilename('general');
}
}
}
 
if (!file_exists($icon)) return null; // default icon (folder)