Commit 8816e270c13753b2cd7f7c86fffe45353d867f5b

Authored by Elena.Budnik
1 parent 210a6ee7

simplified vies checkbox modif

js/app/models/PlotObjects/PlotObjectConfig.js
... ... @@ -23,7 +23,7 @@ Ext.define('amdaPlotObj.PlotObjectConfig', {
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('amdaPlotObj.PlotTabObject', {
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('amdaPlotObj.PlotTabObject', {
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('amdaPlotObj.PlotTabObject', {
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('amdaPlotComp.PlotPanelForm', {
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
... ... @@ -47,10 +47,10 @@ Ext.define('amdaPlotComp.PlotTree', {
47 47  
48 48 this.tabObject = tabObject;
49 49  
50   - this.simplifiedViewCombo.setValue(this.tabObject.get('tree-simplified-view'));
  50 + this.simplifiedViewCombo.setValue(this.tabObject.get('tree-full-view'));
51 51 this.linkToMultiPlotCombo.setValue(this.tabObject.get('multi-plot-linked'));
52 52  
53   - if (!this.tabObject.get('tree-simplified-view'))
  53 + if (this.tabObject.get('tree-full-view'))
54 54 {
55 55 //Page Node
56 56 var pageNode = this.store.getRootNode().appendChild(new amdaPlotObj.PlotPageTreeNode({object : tabObject}));
... ... @@ -137,7 +137,7 @@ Ext.define('amdaPlotComp.PlotTree', {
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('amdaPlotComp.PlotTree', {
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('amdaPlotComp.PlotTree', {
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('amdaPlotComp.PlotTree', {
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('amdaPlotComp.PlotTree', {
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('amdaPlotComp.PlotTree', {
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('amdaPlotComp.PlotTree', {
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('amdaPlotComp.PlotTree', {
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('amdaPlotComp.PlotTree', {
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('amdaPlotComp.PlotTree', {
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('amdaPlotComp.PlotTree', {
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('amdaPlotComp.PlotTree', {
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 }
... ... @@ -826,11 +826,17 @@ Ext.define('amdaPlotComp.PlotTree', {
826 826  
827 827 this.simplifiedViewCombo = Ext.create('Ext.form.field.Checkbox', {
828 828 xtype: 'checkbox',
829   - boxLabel: 'Simplified View',
  829 + boxLabel: 'All PlotOptions',
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);
834 840 if (newValue != oldValue)
835 841 this.buildTree(this.tabObject);
836 842 },
... ... @@ -905,13 +911,13 @@ Ext.define('amdaPlotComp.PlotTree', {
905 911 },
906 912 scope: this
907 913 },
908   - '->',
  914 + '-', '->',
909 915 this.linkToMultiPlotCombo,
910 916 ' ',
911 917 this.simplifiedViewCombo
912 918 ]
913 919 };
914 920  
915   - Ext.apply (this , Ext.apply (arguments, myConf));
  921 + Ext.apply(this,Ext.apply(arguments, myConf));
916 922 }
917 923 });
918 924 \ No newline at end of file
... ...