diff --git a/views/bootstrap/class.Bootstrap.php b/views/bootstrap/class.Bootstrap.php index 702253bc6..e55045362 100644 --- a/views/bootstrap/class.Bootstrap.php +++ b/views/bootstrap/class.Bootstrap.php @@ -172,21 +172,6 @@ background-image: linear-gradient(to bottom, #882222, #111111);; } } /* }}} */ - function documentListItem() { /* {{{ */ - $dms = $this->params['dms']; - $user = $this->params['user']; - $previewwidth = $this->params['previewWidthList']; - $cachedir = $this->params['cachedir']; - $document = $dms->getDocument($_GET['id']); - if($document) { - if ($document->getAccessMode($user) >= M_READ) { - $previewer = new SeedDMS_Preview_Previewer($cachedir, $previewwidth); - $content = $this->documentListRow($document, $previewer, true); - echo $content; - } - } - } /* }}} */ - function missingLanguageKeys() { /* {{{ */ global $MISSING_LANG, $LANG; if($MISSING_LANG) { @@ -247,45 +232,6 @@ background-image: linear-gradient(to bottom, #882222, #111111);; echo "\n"; } /* }}} */ - /** - * Returns the html needed for the clipboard list in the menu - * - * This function renders the clipboard in a way suitable to be - * used as a menu - * - * @param array $clipboard clipboard containing two arrays for both - * documents and folders. - * @return string html code - */ - function menuClipboard($clipboard) { /* {{{ */ - if ($this->params['user']->isGuest() || (count($clipboard['docs']) + count($clipboard['folders'])) == 0) { - return ''; - } - $content = ''; - $content .= " \n"; - return $content; - } /* }}} */ - function globalNavigation($folder=null) { /* {{{ */ $dms = $this->params['dms']; echo "
\n"; @@ -355,7 +301,7 @@ background-image: linear-gradient(to bottom, #882222, #111111);; if($this->params['enableclipboard']) { echo "
"; - echo $this->menuClipboard($this->params['session']->getClipboard()); + echo "
"; echo "
"; } @@ -1513,88 +1459,6 @@ $(function() { } } /* }}} */ - /** - * Return clipboard content rendered as html - * - * @param array clipboard - * @return string rendered html content - */ - function mainClipboard($clipboard, $previewer){ /* {{{ */ - $dms = $this->params['dms']; - $content = ''; - $foldercount = $doccount = 0; - if($clipboard['folders']) { - foreach($clipboard['folders'] as $folderid) { - /* FIXME: check for access rights, which could have changed after adding the folder to the clipboard */ - if($folder = $dms->getFolder($folderid)) { - $comment = $folder->getComment(); - if (strlen($comment) > 150) $comment = substr($comment, 0, 147) . "..."; - $content .= "getID()."\" class=\"folder table-row-folder\" formtoken=\"".createFormKey('movefolder')."\">"; - $content .= "getID()."&showtree=".showtree()."\">imgpath."folder.png\" width=\"24\" height=\"24\" border=0>\n"; - $content .= "getID()."&showtree=".showtree()."\">" . htmlspecialchars($folder->getName()) . ""; - if($comment) { - $content .= "
".htmlspecialchars($comment).""; - } - $content .= "\n"; - $content .= "\n"; - $content .= "
params['folder']) ? $this->params['folder']->getID() : '')."&id=".$folderid."&type=folder\" title=\"".getMLText('rm_from_clipboard')."\">
"; - $content .= "\n"; - $content .= "\n"; - $foldercount++; - } - } - } - if($clipboard['docs']) { - foreach($clipboard['docs'] as $docid) { - /* FIXME: check for access rights, which could have changed after adding the document to the clipboard */ - if($document = $dms->getDocument($docid)) { - $comment = $document->getComment(); - if (strlen($comment) > 150) $comment = substr($comment, 0, 147) . "..."; - if($latestContent = $document->getLatestContent()) { - $previewer->createPreview($latestContent); - $version = $latestContent->getVersion(); - $status = $latestContent->getStatus(); - - $content .= ""; - - if (file_exists($dms->contentDir . $latestContent->getPath())) { - $content .= ""; - if($previewer->hasPreview($latestContent)) { - $content .= "getID()."&version=".$latestContent->getVersion()."&width=40\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">"; - } else { - $content .= "getMimeIcon($latestContent->getFileType())."\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">"; - } - $content .= ""; - } else - $content .= "getMimeIcon($latestContent->getFileType())."\" title=\"".htmlspecialchars($latestContent->getMimeType())."\">"; - - $content .= "" . htmlspecialchars($document->getName()) . ""; - if($comment) { - $content .= "
".htmlspecialchars($comment).""; - } - $content .= "\n"; - $content .= "\n"; - $content .= "
params['folder']) ? $this->params['folder']->getID() : '')."&id=".$docid."&type=document\" title=\"".getMLText('rm_from_clipboard')."\">
"; - $content .= "\n"; - $content .= ""; - $doccount++; - } - } - } - } - - /* $foldercount or $doccount will only count objects which are - * actually available - */ - if($foldercount || $doccount) { - $content = "".$content; - $content .= "
"; - } else { - } - $content .= "
".getMLText("drag_icon_here")."
"; - return $content; - } /* }}} */ - /** * Print clipboard in div container * @@ -1603,7 +1467,9 @@ $(function() { function printClipboard($clipboard, $previewer){ /* {{{ */ $this->contentHeading(getMLText("clipboard"), true); echo "
\n"; - echo $this->mainClipboard($clipboard, $previewer); +?> +
+\n"; } /* }}} */