Merged
Merge Request #34 · created by Elena Budnik


Simplified view checkbox


From simplified-view-checkbox into master

Merged by Elena Budnik

Source branch has been removed
1 participants

07 Feb, 2019

1 commit


06 Feb, 2019

3 commits


04 Feb, 2019

3 commits


01 Feb, 2019

1 commit


help/plotHOWTO
1 1 <li>1. To plot a parameter <i>drag</i> it from the Parameters tree and <i>drop</i> onto the panel
2 2 <li>2. <i>Link to MultiPlot</i> replaces the individual plot tab TimeSelector with the common for all plot tabs "MultiTime" Selector
3   -<li>3. <i>Simplified View</i> hides all request elements except <i>panel</i> and <i>parameter</i>
  3 +<li>3. Check <i>Extended Plot Options</i> to get control over all available plot oprions
4 4  
5 5  
6 6 \ No newline at end of file
... ...
js/app/models/PlotObjects/PlotObjectConfig.js
... ... @@ -23,7 +23,7 @@ Ext.define(&#39;amdaPlotObj.PlotObjectConfig&#39;, {
23 23 oneFilePerInterval: false
24 24 },
25 25 tree : {
26   - simplifiedView : true
  26 + fullView : false
27 27 },
28 28 page : {
29 29 xMargin : 5.,
... ...
js/app/models/PlotObjects/PlotTabObject.js
... ... @@ -27,7 +27,7 @@ Ext.define(&#39;amdaPlotObj.PlotTabObject&#39;, {
27 27  
28 28 fields : [
29 29 {name: 'id', type: 'int'},
30   - {name: 'tree-simplified-view', type: 'boolean'},
  30 + {name: 'tree-full-view', type: 'boolean'},
31 31 {name: 'multi-plot-linked', type: 'boolean'},
32 32 {name: 'page-node-state', type: 'int', defaultValue: 2}, //0 : collapsed, 1 : expanded, 2 : not set
33 33 {name: 'panels-node-state', type: 'int', defaultValue: 2}, //0 : collapsed, 1 : expanded, 2 : not set
... ... @@ -153,7 +153,7 @@ Ext.define(&#39;amdaPlotObj.PlotTabObject&#39;, {
153 153  
154 154 setDefaultValues: function()
155 155 {
156   - this.set('tree-simplified-view', amdaPlotObj.PlotObjectConfig.defaultValues.tree.simplifiedView);
  156 + this.set('tree-full-view', amdaPlotObj.PlotObjectConfig.defaultValues.tree.fullView);
157 157  
158 158 this.set('multi-plot-linked', false);
159 159  
... ... @@ -223,7 +223,7 @@ Ext.define(&#39;amdaPlotObj.PlotTabObject&#39;, {
223 223 var tabValues = new Object();
224 224  
225 225 tabValues['id'] = this.get('id');
226   - tabValues['tree-simplified-view'] = this.get('tree-simplified-view');
  226 + tabValues['tree-full-view'] = this.get('tree-full-view');
227 227 tabValues['multi-plot-linked'] = this.get('multi-plot-linked');
228 228 tabValues['page-node-state'] = this.get('page-node-state');
229 229 tabValues['panels-node-state'] = this.get('panels-node-state');
... ...
js/app/views/PlotComponents/PlotPanelForm.js
... ... @@ -119,7 +119,7 @@ Ext.define(&#39;amdaPlotComp.PlotPanelForm&#39;, {
119 119 if (value != me.object.get('panel-plot-type'))
120 120 {
121 121 me.object.changePlotType(value);
122   - if (!me.crtTree.tabObject.get('tree-simplified-view'))
  122 + if (me.crtTree.tabObject.get('tree-full-view'))
123 123 {
124 124 me.crtTree.buildPanelAxesNode(me.object);
125 125 me.crtTree.buildPanelAdditionalObjectsNode(me.object);
... ...
js/app/views/PlotComponents/PlotTree.js
... ... @@ -46,15 +46,11 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
46 46 this.store.getRootNode().removeAll();
47 47  
48 48 this.tabObject = tabObject;
49   -
50   - this.simplifiedViewCombo.setValue(this.tabObject.get('tree-simplified-view'));
51   - this.linkToMultiPlotCombo.setValue(this.tabObject.get('multi-plot-linked'));
52   -
53   - if (!this.tabObject.get('tree-simplified-view'))
  49 +
  50 + if (this.tabObject.get('tree-full-view') && this.simplifiedViewCombo.getValue())
54 51 {
55 52 //Page Node
56 53 var pageNode = this.store.getRootNode().appendChild(new amdaPlotObj.PlotPageTreeNode({object : tabObject}));
57   -
58 54 //Layout node
59 55 pageNode.appendChild(new amdaPlotObj.PlotLayoutTreeNode({object : tabObject}));
60 56  
... ... @@ -63,8 +59,12 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
63 59 }
64 60 else
65 61 this.panelsNode = this.store.getRootNode();
66   -
  62 +
  63 + this.suspendLayouts();
67 64 this.buildPanelsNode();
  65 + this.simplifiedViewCombo.setValue(this.tabObject.get('tree-full-view'));
  66 + this.linkToMultiPlotCombo.setValue(this.tabObject.get('multi-plot-linked'));
  67 + this.resumeLayouts(true);
68 68 },
69 69  
70 70 buildPanelsNode: function(paramNodeToSelect) {
... ... @@ -137,7 +137,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
137 137 //Retrieve corresponding panel node
138 138 if (panelNode.object == panelObject)
139 139 {
140   - if (!me.tabObject.get('tree-simplified-view'))
  140 + if (me.tabObject.get('tree-full-view'))
141 141 {
142 142 //Retrieve params node
143 143 paramsNode = panelNode.findChild('type', 'params');
... ... @@ -283,7 +283,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
283 283  
284 284 addPanelNode: function(panelObject, paramNodeToSelect) {
285 285 var panelNode = this.panelsNode.appendChild(new amdaPlotObj.PlotPanelTreeNode({object : panelObject}));
286   - if (!this.tabObject.get('tree-simplified-view'))
  286 + if (this.tabObject.get('tree-full-view'))
287 287 {
288 288 //Axes node
289 289 this.buildPanelAxesNode(panelObject);
... ... @@ -337,7 +337,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
337 337 var toIndex = targetNode.parentNode.indexOf(targetNode);
338 338  
339 339 var fromPanelObject = null;
340   - if (!this.tabObject.get('tree-simplified-view'))
  340 + if (this.tabObject.get('tree-full-view'))
341 341 {
342 342 fromPanelObject = record.parentNode.parentNode.object;
343 343 }
... ... @@ -374,7 +374,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
374 374 return true;
375 375 case 'amdaPlotObj.PlotParamTreeNode' :
376 376 var toPanelObject = null;
377   - if (!this.tabObject.get('tree-simplified-view'))
  377 + if (this.tabObject.get('tree-full-view'))
378 378 {
379 379 toPanelObject = targetNode.parentNode.parentNode.object;
380 380 }
... ... @@ -453,7 +453,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
453 453 break;
454 454 case 'param' :
455 455 var panelObject = null;
456   - if (!this.tabObject.get('tree-simplified-view'))
  456 + if (this.tabObject.get('tree-full-view'))
457 457 panelObject = record.parentNode.parentNode.object;
458 458 else
459 459 panelObject = record.parentNode.object;
... ... @@ -463,7 +463,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
463 463 break;
464 464 case 'text-legend' :
465 465 var panelObject = null;
466   - if (!this.tabObject.get('tree-simplified-view'))
  466 + if (this.tabObject.get('tree-full-view'))
467 467 panelObject = record.parentNode.parentNode.object;
468 468 else
469 469 panelObject = record.parentNode.object;
... ... @@ -472,7 +472,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
472 472 break;
473 473 case 'constant' :
474 474 var panelObject = null;
475   - if (!this.tabObject.get('tree-simplified-view'))
  475 + if (this.tabObject.get('tree-full-view'))
476 476 panelObject = record.parentNode.parentNode.object;
477 477 else
478 478 panelObject = record.parentNode.object;
... ... @@ -481,7 +481,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
481 481 break;
482 482 case 'text-obj' :
483 483 var panelObject = null;
484   - if (!this.tabObject.get('tree-simplified-view'))
  484 + if (this.tabObject.get('tree-full-view'))
485 485 panelObject = record.parentNode.parentNode.object;
486 486 else
487 487 panelObject = record.parentNode.object;
... ... @@ -490,7 +490,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
490 490 break;
491 491 case 'curve' :
492 492 var panelObject = null;
493   - if (!this.tabObject.get('tree-simplified-view'))
  493 + if (this.tabObject.get('tree-full-view'))
494 494 panelObject = record.parentNode.parentNode.object;
495 495 else
496 496 panelObject = record.parentNode.object;
... ... @@ -499,7 +499,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
499 499 break;
500 500 case 'fill' :
501 501 var panelObject = null;
502   - if (!this.tabObject.get('tree-simplified-view'))
  502 + if (this.tabObject.get('tree-full-view'))
503 503 panelObject = record.parentNode.parentNode.object;
504 504 else
505 505 panelObject = record.parentNode.object;
... ... @@ -560,7 +560,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
560 560 return record.isLeaf();
561 561 case 'amdaPlotObj.PlotParamTreeNode' :
562 562 var fromPanelObject = null;
563   - if (!this.tabObject.get('tree-simplified-view'))
  563 + if (this.tabObject.get('tree-full-view'))
564 564 {
565 565 fromPanelObject = record.parentNode.parentNode.object;
566 566 }
... ... @@ -577,7 +577,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
577 577 toPanelObject = targetNode.object;
578 578 break;
579 579 case 'amdaPlotObj.PlotParamTreeNode' :
580   - if (!this.tabObject.get('tree-simplified-view'))
  580 + if (this.tabObject.get('tree-full-view'))
581 581 {
582 582 toPanelObject = targetNode.parentNode.parentNode.object;
583 583 }
... ... @@ -813,7 +813,7 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
813 813  
814 814 init : function(config) {
815 815 var me = this;
816   -
  816 +
817 817 this.plotElementPanel = config.plotElementPanel;
818 818  
819 819 var store = Ext.create('Ext.data.TreeStore', {
... ... @@ -822,15 +822,22 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
822 822 }
823 823 });
824 824  
825   - this.plotElementPanel = config.plotElementPanel;
  825 + // this.plotElementPanel = config.plotElementPanel;
826 826  
827 827 this.simplifiedViewCombo = Ext.create('Ext.form.field.Checkbox', {
828 828 xtype: 'checkbox',
829   - boxLabel: 'Simplified View',
  829 + boxLabel: 'Extended Plot Options',
830 830 listeners: {
  831 +// render: function(c) {
  832 +// Ext.create('Ext.tip.ToolTip', {
  833 +// target: c.getEl(),
  834 +// html: "SOME TEXT"
  835 +// });
  836 +// },
831 837 change: function(combo, newValue, oldValue, eOpts) {
832 838 if (this.tabObject)
833   - this.tabObject.set('tree-simplified-view', newValue);
  839 + this.tabObject.set('tree-full-view', newValue);
  840 +
834 841 if (newValue != oldValue)
835 842 this.buildTree(this.tabObject);
836 843 },
... ... @@ -905,13 +912,13 @@ Ext.define(&#39;amdaPlotComp.PlotTree&#39;, {
905 912 },
906 913 scope: this
907 914 },
908   - '->',
  915 + '-', '->',
909 916 this.linkToMultiPlotCombo,
910 917 ' ',
911 918 this.simplifiedViewCombo
912 919 ]
913 920 };
914 921  
915   - Ext.apply (this , Ext.apply (arguments, myConf));
  922 + Ext.apply(this,Ext.apply(arguments, myConf));
916 923 }
917 924 });
918 925 \ No newline at end of file
... ...