mirror of https://github.com/luileito/jsketch.git
Added `cssCursors` option
This commit is contained in:
parent
0b4988c9d3
commit
ed9eb33b22
|
|
@ -49,6 +49,10 @@
|
||||||
// Fix Chrome "bug".
|
// Fix Chrome "bug".
|
||||||
this.onselectstart = function(){ return false };
|
this.onselectstart = function(){ return false };
|
||||||
}
|
}
|
||||||
|
if (options.cssCursors) {
|
||||||
|
// Visually indicate whether this element is interactive or not.
|
||||||
|
elem[0].style.cursor = options.interactive ? "pointer" : "not-allowed";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
var sketch = new jSketch(this, options.graphics);
|
var sketch = new jSketch(this, options.graphics);
|
||||||
// Reconfigure element data.
|
// Reconfigure element data.
|
||||||
|
|
@ -230,6 +234,7 @@
|
||||||
* mouseupMovements: false,
|
* mouseupMovements: false,
|
||||||
* relTimestamps: false,
|
* relTimestamps: false,
|
||||||
* multitouch: true,
|
* multitouch: true,
|
||||||
|
* cssCursors: true,
|
||||||
* events: {
|
* events: {
|
||||||
* init: function(elem, data){ },
|
* init: function(elem, data){ },
|
||||||
* clear: function(elem, data){ },
|
* clear: function(elem, data){ },
|
||||||
|
|
@ -259,6 +264,8 @@
|
||||||
relTimestamps: false,
|
relTimestamps: false,
|
||||||
// Enable multitouch drawing.
|
// Enable multitouch drawing.
|
||||||
multitouch: true,
|
multitouch: true,
|
||||||
|
// Display CSS cursors, mainly to indicate whether the element is interactive or not.
|
||||||
|
cssCursors: true,
|
||||||
// Event callbacks.
|
// Event callbacks.
|
||||||
events: {
|
events: {
|
||||||
// init: function(elem, data){ },
|
// init: function(elem, data){ },
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue