Commit 0ceb8de80026201c863a17cd82609a9629419e68
1 parent
9162d169
Exists in
master
and in
24 other branches
Add symbolic link to color map definition into histo2D form
Showing
1 changed file
with
9 additions
and
3 deletions
Show diff stats
js/app/views/PlotComponents/PlotHistogram2DSerieForm.js
@@ -18,7 +18,7 @@ Ext.define('amdaPlotComp.PlotHistogram2DSerieForm', { | @@ -18,7 +18,7 @@ Ext.define('amdaPlotComp.PlotHistogram2DSerieForm', { | ||
18 | 18 | ||
19 | setParentObject: function (parentObject) { | 19 | setParentObject: function (parentObject) { |
20 | this.callParent(arguments); | 20 | this.callParent(arguments); |
21 | - this.updateAxesRanges(parentObject); | 21 | + this.updateAxesRangesAndColourMap(parentObject); |
22 | }, | 22 | }, |
23 | 23 | ||
24 | updateOptions: function(functionType) { | 24 | updateOptions: function(functionType) { |
@@ -28,13 +28,16 @@ Ext.define('amdaPlotComp.PlotHistogram2DSerieForm', { | @@ -28,13 +28,16 @@ Ext.define('amdaPlotComp.PlotHistogram2DSerieForm', { | ||
28 | zParamField.setVisible(!isDensity) | 28 | zParamField.setVisible(!isDensity) |
29 | }, | 29 | }, |
30 | 30 | ||
31 | - updateAxesRanges: function(parentObject) { | 31 | + updateAxesRangesAndColourMap: function(parentObject) { |
32 | var xAxisObj = parentObject.axes().getById('xaxis_id'); | 32 | var xAxisObj = parentObject.axes().getById('xaxis_id'); |
33 | var yAxisObj = parentObject.axes().getById('y-left'); | 33 | var yAxisObj = parentObject.axes().getById('y-left'); |
34 | + var colorAxisObj = parentObject.axes().getById('color'); | ||
35 | + | ||
34 | this.getForm().findField('histo2d-xmin').setValue(xAxisObj.get('axis-range-min')); | 36 | this.getForm().findField('histo2d-xmin').setValue(xAxisObj.get('axis-range-min')); |
35 | this.getForm().findField('histo2d-xmax').setValue(xAxisObj.get('axis-range-max')); | 37 | this.getForm().findField('histo2d-xmax').setValue(xAxisObj.get('axis-range-max')); |
36 | this.getForm().findField('histo2d-ymin').setValue(yAxisObj.get('axis-range-min')); | 38 | this.getForm().findField('histo2d-ymin').setValue(yAxisObj.get('axis-range-min')); |
37 | this.getForm().findField('histo2d-ymax').setValue(yAxisObj.get('axis-range-max')); | 39 | this.getForm().findField('histo2d-ymax').setValue(yAxisObj.get('axis-range-max')); |
40 | + this.getForm().findField('histo2d-color-map').setValue(colorAxisObj.get('axis-color-map')); | ||
38 | }, | 41 | }, |
39 | 42 | ||
40 | getRangeForms: function(){ | 43 | getRangeForms: function(){ |
@@ -104,7 +107,10 @@ Ext.define('amdaPlotComp.PlotHistogram2DSerieForm', { | @@ -104,7 +107,10 @@ Ext.define('amdaPlotComp.PlotHistogram2DSerieForm', { | ||
104 | }), | 107 | }), |
105 | this.addStandardInteger('histo2d-xbinnumber', 'X - Nb. of bins'), | 108 | this.addStandardInteger('histo2d-xbinnumber', 'X - Nb. of bins'), |
106 | this.addStandardInteger('histo2d-ybinnumber', 'Y - Nb. of bins'), | 109 | this.addStandardInteger('histo2d-ybinnumber', 'Y - Nb. of bins'), |
107 | - this.addStandardInteger('histo2d-smoothfactor', 'Smooth factor') | 110 | + this.addStandardInteger('histo2d-smoothfactor', 'Smooth factor'), |
111 | + this.addColorMapCombo('histo2d-color-map', function(name, newValue, oldValue){ | ||
112 | + me.parentObject.axes().getById('color').set('axis-color-map', newValue); | ||
113 | + }) | ||
108 | 114 | ||
109 | ]; | 115 | ]; |
110 | return histogram2DItems; | 116 | return histogram2DItems; |