Adding basic color picker

This commit is contained in:
Vince
2012-08-28 22:24:58 +02:00
parent bfaea76eb6
commit 6616ec2870
8 changed files with 976 additions and 0 deletions

View File

@@ -41,6 +41,7 @@
this.initDrawingArea();
this.initPreviewSlideshow();
this.initAnimationPreview();
this.initColorPicker();
},
setActiveFrame: function(index) {
@@ -67,6 +68,14 @@
return activeFrameIndex;
},
initColorPicker: function() {
var colorPicker = document.getElementById('color-picker');
colorPicker.value = DEFAULT_PEN_COLOR;
colorPicker.addEventListener('change', function(evt) {
penColor = colorPicker.value;
});
},
initDrawingArea : function() {
drawingAreaContainer = $('drawing-canvas-container');