From ef189f30ffcb622c8cdde39387bcb58b8dbc4e99 Mon Sep 17 00:00:00 2001 From: girish Date: Wed, 9 Feb 2011 15:01:19 +0000 Subject: [PATCH] shape Size remains constant as per zoomed factor(for subprocess) --- workflow/engine/templates/bpmn/SubProcess.js | 17 ++++++++++++++++- workflow/engine/templates/bpmn/designer.js | 13 ------------- 2 files changed, 16 insertions(+), 14 deletions(-) diff --git a/workflow/engine/templates/bpmn/SubProcess.js b/workflow/engine/templates/bpmn/SubProcess.js index 145f48a82..5e7e18837 100755 --- a/workflow/engine/templates/bpmn/SubProcess.js +++ b/workflow/engine/templates/bpmn/SubProcess.js @@ -37,8 +37,23 @@ bpmnSubProcess.prototype.coord_converter = function (bound_width, bound_height, //curWidth = this.getWidth(); bpmnSubProcess.prototype.paint = function () { - VectorFigure.prototype.paint.call(this); + VectorFigure.prototype.paint.call(this); + if(typeof workflow.sType == 'undefined') + workflow.sType = 1; + //For Zooming + if(typeof this.limitFlag == 'undefined' || this.limitFlag == false) + { + this.originalWidth = 165; + this.originalHeight = 40; + this.orgXPos = this.getX(); + this.orgYPos = this.getY(); + this.orgFontSize =this.fontSize; + } + + this.width = this.originalWidth * workflow.sType; + this.height = this.originalHeight * workflow.sType; + var x = new Array(6, this.getWidth() - 3, this.getWidth(), this.getWidth(), this.getWidth() - 3, 6, 3, 3, 6); var y = new Array(3, 3, 6, this.getHeight() - 3, this.getHeight(), this.getHeight(), this.getHeight() - 3, 6, 3); this.graphics.setStroke(this.stroke); diff --git a/workflow/engine/templates/bpmn/designer.js b/workflow/engine/templates/bpmn/designer.js index 70aa889f1..3c12a026b 100755 --- a/workflow/engine/templates/bpmn/designer.js +++ b/workflow/engine/templates/bpmn/designer.js @@ -309,19 +309,6 @@ win.on('move', function() { }); - //Getting Process name and setting Title of center region to that processname - /*var urlparams = '?action=load&data={"uid":"'+ pro_uid +'"}'; - Ext.Ajax.request({ - url: "processes_Ajax.php"+ urlparams, - success: function(response) { - var processes = Ext.util.JSON.decode(response.responseText); - main.items.items[2].setTitle(processes.title.label); //items[2]=>center region - }, - failure: function(){ - Ext.Msg.alert ('Failure'); - } - });*/ - //Get main into workflow object workflow.main = main; //items[3]=>'center region'