You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openmeetings.apache.org by se...@apache.org on 2020/05/04 21:29:33 UTC

[openmeetings] branch feature/OPENMEETINGS-2344-file-explorer-files-to-use-whitespace updated: OPENMEETINGS-2344 Add iterative more width depending on tree level. Up to maximum of 7 levels down.

This is an automated email from the ASF dual-hosted git repository.

sebawagner pushed a commit to branch feature/OPENMEETINGS-2344-file-explorer-files-to-use-whitespace
in repository https://gitbox.apache.org/repos/asf/openmeetings.git


The following commit(s) were added to refs/heads/feature/OPENMEETINGS-2344-file-explorer-files-to-use-whitespace by this push:
     new 42adc47  OPENMEETINGS-2344 Add iterative more width depending on tree level. Up to maximum of 7 levels down.
42adc47 is described below

commit 42adc474d7cadd0c8088a44127cd9a6abe6a117e
Author: Sebastian Wagner <se...@apache.org>
AuthorDate: Tue May 5 09:29:02 2020 +1200

    OPENMEETINGS-2344 Add iterative more width depending on tree level. Up to maximum of 7 levels down.
---
 .../openmeetings/web/common/tree/FolderPanel.java  | 16 ++++++++
 openmeetings-web/src/main/webapp/css/raw-tree.css  | 44 +++++++++++++++++++++-
 2 files changed, 59 insertions(+), 1 deletion(-)

diff --git a/openmeetings-web/src/main/java/org/apache/openmeetings/web/common/tree/FolderPanel.java b/openmeetings-web/src/main/java/org/apache/openmeetings/web/common/tree/FolderPanel.java
index fcc0afe..c3b2cba 100644
--- a/openmeetings-web/src/main/java/org/apache/openmeetings/web/common/tree/FolderPanel.java
+++ b/openmeetings-web/src/main/java/org/apache/openmeetings/web/common/tree/FolderPanel.java
@@ -24,6 +24,7 @@ import static org.apache.openmeetings.util.OpenmeetingsVariables.ATTR_TITLE;
 import java.util.Map.Entry;
 
 import org.apache.openmeetings.db.dao.file.FileItemDao;
+import org.apache.openmeetings.db.dao.file.FileItemLogDao;
 import org.apache.openmeetings.db.dao.record.RecordingDao;
 import org.apache.openmeetings.db.entity.file.BaseFileItem;
 import org.apache.openmeetings.db.entity.file.BaseFileItem.Type;
@@ -66,6 +67,8 @@ public class FolderPanel extends Panel implements IDraggableListener, IDroppable
 	private RecordingDao recDao;
 	@SpringBean
 	private FileItemDao fileDao;
+	@SpringBean
+	private FileItemLogDao fileLogDao;
 
 	public FolderPanel(String id, final IModel<BaseFileItem> model, final FileTreePanel treePanel) {
 		super(id, model);
@@ -225,6 +228,19 @@ public class FolderPanel extends Panel implements IDraggableListener, IDroppable
 		}
 		String cls = f instanceof Recording ? "recorditem " : "fileitem ";
 		style.append(f.isReadOnly() ? "readonlyitem " : cls);
+
+		long errorCount = fileLogDao.countErrors(f);
+		boolean hasError = errorCount != 0;
+		if (BaseFileItem.Type.RECORDING == f.getType()) {
+			Recording r = (Recording)f;
+			hasError |= (Status.RECORDING != r.getStatus() && Status.CONVERTING != r.getStatus() && !f.exists());
+		} else {
+			hasError |= !f.exists();
+		}
+		if (hasError) {
+			style.append("error");
+		}
+
 		return style;
 	}
 
diff --git a/openmeetings-web/src/main/webapp/css/raw-tree.css b/openmeetings-web/src/main/webapp/css/raw-tree.css
index a2d7e0c..0323285 100644
--- a/openmeetings-web/src/main/webapp/css/raw-tree.css
+++ b/openmeetings-web/src/main/webapp/css/raw-tree.css
@@ -26,7 +26,49 @@
 .file-tree .file.item .name
 	, .file-tree .file.item .name span
 {
-	max-width: calc(var(--room-sidebar-width) - 100px);
+	max-width: calc(var(--room-sidebar-width) - 58px);
+	min-width: 60px;
+}
+.file-tree .tree-subtree .file.item .name
+	, .file-tree .tree-subtree .file.item .name span
+{
+	max-width: calc(var(--room-sidebar-width) - 76px);
+	min-width: 60px;
+}
+.file-tree .tree-subtree .tree-subtree .file.item .name
+	, .file-tree .tree-subtree .tree-subtree .file.item .name span
+{
+	max-width: calc(var(--room-sidebar-width) - 94px);
+	min-width: 60px;
+}
+.file-tree .tree-subtree .tree-subtree .tree-subtree .file.item .name
+	, .file-tree .tree-subtree .tree-subtree .tree-subtree .file.item .name span
+{
+	max-width: calc(var(--room-sidebar-width) - 112px);
+	min-width: 60px;
+}
+.file-tree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .file.item .name
+	, .file-tree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .file.item .name span
+{
+	max-width: calc(var(--room-sidebar-width) - 130px);
+	min-width: 60px;
+}
+.file-tree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .file.item .name
+	, .file-tree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .file.item .name span
+{
+	max-width: calc(var(--room-sidebar-width) - 148px);
+	min-width: 60px;
+}
+.file-tree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .file.item .name
+	, .file-tree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .file.item .name span
+{
+	max-width: calc(var(--room-sidebar-width) - 166px);
+	min-width: 60px;
+}
+.file-tree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .file.item .name
+	, .file-tree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .tree-subtree .file.item .name span
+{
+	max-width: calc(var(--room-sidebar-width) - 184px);
 	min-width: 60px;
 }
 .trash-toolbar {