Skip to content

Commit

Permalink
Fixing drawing in firefox.
Browse files Browse the repository at this point in the history
  • Loading branch information
gtramontina committed May 20, 2011
1 parent 2e53b18 commit d110a39
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Check it out: http://writeboard.nodester.com
Features
--------
The only, yet main, feature are the rooms.
When you access the Writeboard via http://writeboard.nodester.com you'll be redirected to a new room with a random identifier. But, if you want your rooms to have an easy name to remember, you can go straight to http://whiteboard.nodester.com/gtramontina for example.
When you access the Writeboard via http://writeboard.nodester.com you'll be redirected to a new room with a random identifier. But, if you want your rooms to have an easy name to remember, you can go straight to http://writeboard.nodester.com/gtramontina for example.

Tips
----
Expand All @@ -15,7 +15,7 @@ Tips

Roadmap
-------
- Keep drawings in the room so that new attendees can see what's been drawn so far.
- Keep drawings in the room so that new attendees can see what's been drawn so far. (DONE: improvement required though)
- Make password-protected private rooms, so you can have a safe meeting.
- Add 'Save as... PNG/JPEG' option, for emailing the board to the attendees.
- (...)
Expand Down
2 changes: 1 addition & 1 deletion public/javascripts/writeboard-page.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@ writeboardPage = ->
(loading 'Loading. Please wait...').show()
writeboard = createWriteboard dom.canvas[0], window.innerWidth, window.innerHeight

dom.canvas.bind 'selectstart', -> false
dom.helpButton.click ->
$.get '/about', { noLayout: true }, (aboutPage) ->
about = $ "#{aboutPage}"
about.hide()
dom.body.append about
about.fadeIn()
dom.canvas.bind 'selectstart', -> false

enableCanvas = (drawings) ->
replay writeboard, drawings
Expand Down
3 changes: 2 additions & 1 deletion public/javascripts/writeboard.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
startDrawing = (x, y) ->
[lastX, lastY] = [x, y]
context.beginPath()
context.moveTo x, y
lastCanvasData = context.getImageData 0, 0, width, height
draw x+.1, y+.1

Expand All @@ -25,7 +26,7 @@
context.stroke()
[lastX, lastY] = [x, y]

stopDrawing = -> # ?
stopDrawing = -> lastX = lastY = 0 # ?

setColor 'rgba(20, 20, 20, 0.8)'

Expand Down

0 comments on commit d110a39

Please sign in to comment.