Browse Source

20.8.19 release

David Benson 2 years ago
parent
commit
7cbff2d278

+ 4 - 0
ChangeLog

@@ -1,3 +1,7 @@
+09-FEB-2023: 20.8.19
+
+- Disables object selection in locked layers [drawio-3343] 
+
 07-FEB-2023: 20.8.18
 
 - Fixes locked is not defined in read-only diagrams [DS-944]

+ 1 - 1
VERSION

@@ -1 +1 @@
-20.8.18
+20.8.19

File diff suppressed because it is too large
+ 603 - 603
src/main/webapp/js/app.min.js


+ 22 - 6
src/main/webapp/js/grapheditor/Graph.js

@@ -1171,6 +1171,14 @@ Graph = function(container, model, renderHint, stylesheet, themes, standalone)
 			return graphHandlerShouldRemoveCellsFromParent.apply(this, arguments);
 		};
 
+		// Cells in locked layers are not selectable
+		var graphIsCellSelectable = this.isCellSelectable;
+		this.isCellSelectable = function(cell)
+		{
+			return graphIsCellSelectable.apply(this, arguments) &&
+				!this.isCellLocked(this.getLayerForCell(cell));
+		};
+
 		// Returns true if the given cell is locked
 		this.isCellLocked = function(cell)
 		{
@@ -4038,6 +4046,19 @@ Graph.prototype.formatDate = function(date, mask, utc)
     });
 };
 
+/**
+ * 
+ */
+Graph.prototype.getLayerForCell = function(cell)
+{
+	while (cell != null && !this.model.isLayer(cell))
+	{
+		cell = this.model.getParent(cell);
+	}
+
+	return cell;
+};
+
 /**
  * 
  */
@@ -4047,12 +4068,7 @@ Graph.prototype.getLayerForCells = function(cells)
 	
 	if (cells.length > 0)
 	{
-		result = cells[0];
-		
-		while (!this.model.isLayer(result))
-		{
-			result = this.model.getParent(result);
-		}
+		result = this.getLayerForCell(cells[0]);
 		
 		for (var i = 1; i < cells.length; i++)
 		{

File diff suppressed because it is too large
+ 603 - 603
src/main/webapp/js/integrate.min.js


File diff suppressed because it is too large
+ 1262 - 1261
src/main/webapp/js/viewer-static.min.js


File diff suppressed because it is too large
+ 1262 - 1261
src/main/webapp/js/viewer.min.js


File diff suppressed because it is too large
+ 1 - 1
src/main/webapp/mxgraph/mxClient.js


File diff suppressed because it is too large
+ 1 - 1
src/main/webapp/service-worker.js


File diff suppressed because it is too large
+ 1 - 1
src/main/webapp/service-worker.js.map