Skip to content

Commit

Permalink
Fix bind-input example to use valueAsNumber
Browse files Browse the repository at this point in the history
  • Loading branch information
bbinet committed Aug 13, 2013
1 parent afee1ab commit 2dd6321
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions examples/bind-input.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,23 +22,23 @@ var visible = new ol.dom.Input(document.getElementById('visible'));
visible.bindTo('checked', layer, 'visible');

var opacity = new ol.dom.Input(document.getElementById('opacity'));
opacity.bindTo('value', layer, 'opacity');
opacity.bindTo('valueAsNumber', layer, 'opacity');

var hue = new ol.dom.Input(document.getElementById('hue'));
hue.bindTo('value', layer, 'hue');
hue.bindTo('valueAsNumber', layer, 'hue');

var saturation = new ol.dom.Input(document.getElementById('saturation'));
saturation.bindTo('value', layer, 'saturation');
saturation.bindTo('valueAsNumber', layer, 'saturation');

var contrast = new ol.dom.Input(document.getElementById('contrast'));
contrast.bindTo('value', layer, 'contrast');
contrast.bindTo('valueAsNumber', layer, 'contrast');

var brightness = new ol.dom.Input(document.getElementById('brightness'));
brightness.bindTo('value', layer, 'brightness');
brightness.bindTo('valueAsNumber', layer, 'brightness');


var rotation = new ol.dom.Input(document.getElementById('rotation'));
rotation.bindTo('value', map.getView(), 'rotation');
rotation.bindTo('valueAsNumber', map.getView(), 'rotation');

var resolution = new ol.dom.Input(document.getElementById('resolution'));
resolution.bindTo('value', map.getView(), 'resolution');
resolution.bindTo('valueAsNumber', map.getView(), 'resolution');

0 comments on commit 2dd6321

Please sign in to comment.