0
0
mirror of https://github.com/Doodle3D/doodle3d-client.git synced 2024-12-20 04:13:48 +01:00
doodle3d-client/js_src/verticalShapes.js
Adriaan Wormgoor f0f97198ec Big changes to order and placement of JS files:
- grunt file updated to include automatic production of doodle3d-client.js and doodle3d-client.min.js
- all individual JS files moved to outside scope of 'www' dir to reflect these changes
2013-10-22 12:04:46 +02:00

41 lines
1.1 KiB
JavaScript

var VERTICALSHAPE;
var verticalShapes = {
"NONE": 'none',
"DIVERGING": 'diverging',
"CONVERGING": 'converging',
"SINUS": 'sinus'
};
function initVerticalShapes() {
// TODO give these vertical shapes a better spot
VERTICALSHAPE = verticalShapes.NONE;
$(".verticalShapes, .straight").on('mouseup touchend', function(e) {
e.preventDefault();
console.log("diverging");
VERTICALSHAPE = verticalShapes.NONE;
redrawRenderedPreview();
})
$(".verticalShapes, .diverging").on('mouseup touchend', function(e) {
e.preventDefault();
console.log("diverging");
VERTICALSHAPE = verticalShapes.DIVERGING;
redrawRenderedPreview();
})
$(".verticalShapes, .converging").on('mouseup touchend', function(e) {
e.preventDefault();
console.log("converging");
VERTICALSHAPE = verticalShapes.CONVERGING;
redrawRenderedPreview();
})
$(".verticalShapes, .sinus").on('mouseup touchend', function(e) {
e.preventDefault();
console.log("sinus");
VERTICALSHAPE = verticalShapes.SINUS;
redrawRenderedPreview();
})
}
function resetVerticalShapes() {
VERTICALSHAPE = verticalShapes.NONE;
}