summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 600fd9b)
raw | patch | inline | side by side (parent: 600fd9b)
author | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 2 Mar 2010 08:35:31 +0000 (08:35 +0000) | ||
committer | cajus <cajus@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 2 Mar 2010 08:35:31 +0000 (08:35 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@15827 594d385d-05f5-0310-b6e9-bd551577e9d8
index 4304e81f47c429709e6ad6943c4d8f51a7696afc..333fbb5e344dd732d5a3129a64945ef05f920fac 100644 (file)
border:0;
padding:0;
margin:0;
+ margin-top:-2px;
display:inline-block;
display:-moz-inline-block;
background-color:transparent;
}
.listScrollContent td div.img {
- padding-right:1px;
+ margin-right:1px;
}
.listScrollContent td input[type=submit].img {
index 7b2cab1807c9923965c06e46a7888a3ddfddac02..ef7e038c30b9a64fa145bdd5306112e639047671 100644 (file)
isset($config['sortType'])) {
$this->sortAttribute= $config['sortAttribute'];
$this->sortType= $config['sortType'];
- $sorter= " <img border='0' title='".($this->sortDirection[$index]?_("Up"):_("Down"))."' src='images/lists/sort-".($this->sortDirection[$index]?"up":"down").".png' align='top'>";
+ $sorter= " ".image("images/lists/sort-".($this->sortDirection[$index]?"up":"down").".png", null, null, $this->sortDirection[$index]?_("Up"):_("Down"), "text-top");
}
$sortable= (isset($config['sortAttribute']));
// Load shortcut
$actions= &$this->xmlData['actionmenu']['action'];
$result= "<input type='hidden' name='act' id='actionmenu' value=''><div style='display:none'><input type='submit' name='exec_act' id='exec_act' value=''></div>".
- "<ul class='level1' id='root'><li><a href='#'>"._("Actions")." <img ".
- "border=0 class='center' src='images/lists/sort-down.png'></a>";
+ "<ul class='level1' id='root'><li><a href='#'>"._("Actions")." ".image("images/lists/sort-down.png")."</a>";
// Build ul/li list
$result.= $this->recurseActions($actions);
// Fill image if set
$img= "";
if (isset($action['image'])){
- $img= "<img border='0' class='center' src='".$action['image']."'> ";
+ $img= image($action['image'])." ";
}
if ($action['type'] == "separator"){
if ($action['type'] == "sub" && isset($action['action'])) {
$level++;
if (isset($action['label'])){
- $result.= "<li$separator><a href='#'>$img"._($action['label'])." <img border='0' src='images/forward-arrow.png'></a>";
+ $result.= "<li$separator><a href='#'>$img"._($action['label'])." ".image('images/forward-arrow.png')."</a>";
}
// Ensure we've an array of actions, this enables sub menus with only one action.
// Copy entry
if($copy){
- $result.= "<li$separator><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"copy\";document.getElementById(\"exec_act\").click();'><img src='images/lists/copy.png' alt='' border='0' class='center'> "._("Copy")."</a></li>";
+ $result.= "<li$separator><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"copy\";document.getElementById(\"exec_act\").click();'>".image('images/lists/copy.png')." "._("Copy")."</a></li>";
$separator= "";
}
// Cut entry
if($cut){
- $result.= "<li$separator><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"cut\";document.getElementById(\"exec_act\").click();'><img src='images/lists/cut.png' alt='' border='0' class='center'> "._("Cut")."</a></li>";
+ $result.= "<li$separator><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"cut\";document.getElementById(\"exec_act\").click();'>".image("images/lists/cut.png")." "._("Cut")."</a></li>";
$separator= "";
}
}
// Draw entries that allow pasting entries
if($paste){
if($this->copyPasteHandler->entries_queued()){
- $result.= "<li$separator><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"paste\";document.getElementById(\"exec_act\").click();'><img src='images/lists/paste.png' alt='' border='0' class='center'> "._("Paste")."</a></li>";
+ $result.= "<li$separator><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"paste\";document.getElementById(\"exec_act\").click();'>".image("images/lists/paste.png")." "._("Paste")."</a></li>";
}else{
- $result.= "<li$separator><a href='#'><img src='images/lists/paste-grey.png' alt='' border='0' class='center'> "._("Paste")."</a></li>";
+ $result.= "<li$separator><a href='#'>".image('images/lists/paste-grey.png')." "._("Paste")."</a></li>";
}
}
// Draw icons according to the restore flag
if($restore){
- $result.= "<li$separator><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"restore\";document.getElementById(\"exec_act\").click();'><img src='images/lists/restore.png' alt='' border='0' class='center'> "._("Restore snapshots")."</a></li>";
+ $result.= "<li$separator><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"restore\";document.getElementById(\"exec_act\").click();'>".image('images/lists/restore.png')." "._("Restore snapshots")."</a></li>";
}else{
- $result.= "<li$separator><a href='#'><img src='images/lists/restore_grey.png' alt='' border='0' class='center'> "._("Restore snapshots")."</a></li>";
+ $result.= "<li$separator><a href='#'>".image('images/lists/restore_grey.png')." "._("Restore snapshots")."</a></li>";
}
}
$result = "";
// Draw entries
- $result.= "<li$separator><a href='#'><img border='0' class='center' src='images/lists/export.png'> "._("Export list")." <img border='0' src='images/forward-arrow.png'></a><ul class='level3'>";
+ $result.= "<li$separator><a href='#'>".image('images/lists/export.png')." "._("Export list")." ".image("images/forward-arrow.png")."</a><ul class='level3'>";
// Export CVS as build in exporter
foreach ($this->exporter as $action => $exporter) {
- $result.= "<li><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"$action\";document.getElementById(\"exec_act\").click();'><img border='0' class='center' src='".$exporter['image']."'> ".$exporter['label']."</a></li>";
+ $result.= "<li><a href='#' onClick='document.getElementById(\"actionmenu\").value= \"$action\";document.getElementById(\"exec_act\").click();'>".image($exporter['image'])." ".$exporter['label']."</a></li>";
}
// Finalize list
index 24d9328ae29d984925b03cadf984c30a79a2a8b6..21813350df90975a6d736eae9f2b96a658cba1d3 100644 (file)
/* Return an image description using the path */
-function image($path, $label= null, $action= "", $title= "")
+function image($path, $label= null, $action= "", $title= "", $align= "middle")
{
global $config;
global $BASE_DIR;
}
}
+ // Non middle layout?
+ if ($align == "middle") {
+ $align= "";
+ } else {
+ $align= ";vertical-align:$align";
+ }
+
// Clickable image or not?
if ($title != "") {
$title= "title='$title'";
}
if ($action == "") {
- return "<div class='img' $title style='".$styles[$path]."'>$lbl</div>";
+ return "<div class='img' $title style='".$styles[$path]."$align'>$lbl</div>";
} else {
- return "<input type='submit' class='img' id='$action' value='' name='$action' $title style='".$styles[$path]."'>";
+ return "<input type='submit' class='img' id='$action' value='' name='$action' $title style='".$styles[$path]."$align'>";
}
}
diff --git a/gosa-core/plugins/admin/users/user-list.tpl b/gosa-core/plugins/admin/users/user-list.tpl
index e3a6438e5737e5bb3479916f5f5bbcb32ee3828f..009710dff58984269b958aaa110080ce652bae1a 100644 (file)
<div class="mainlist-nav">
<table>
<tr>
- <td>{$ROOT} </td><td>{$BACK} </td><td>{$HOME} </td><td>{$RELOAD} </td><td>{$SEPARATOR} </td><td>{t}Base{/t} {$BASE} </td><td>{$SEPARATOR} </td><td><img src='images/rocket.png' alt='' class='center'></td><td> {$ACTIONS}</td>
+ <td>{$ROOT} </td><td>{$BACK} </td><td>{$HOME} </td><td>{$RELOAD} </td><td>{$SEPARATOR} </td><td>{t}Base{/t} {$BASE} </td><td>{$SEPARATOR} </td><td> {$ACTIONS}</td>
</tr>
</table>
</div>
diff --git a/gosa-core/plugins/admin/users/user-list.xml b/gosa-core/plugins/admin/users/user-list.xml
index a7a12ba85b5b912775f3a15105bdfed993ef8140..6cc1dcbd83deb1e448179952eb7ec6ee07d5d47d 100644 (file)
<action>
<name>new</name>
<type>entry</type>
- <image>plugins/users/images/list_new_user.png</image>
+ <image>plugins/users/images/select_user.png</image>
<label>User</label>
</action>