You can now use functions as the fill/stroke style for any drawing

- Fixed a potential bug where the wrong layer might be dragged
- Fixed a bug that triggered the dragstart event on mousedown, even if
the layer had not been dragged