Skip to content

Commit bbca182

Browse files
author
Micheal Harker
committed
Added CTRL + W and CTRL + Q, quitting the app. Fixes #19
1 parent b707835 commit bbca182

File tree

4 files changed

+18
-2
lines changed

4 files changed

+18
-2
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
*~
12
javascript/*.js
23
.sass-cache
34
node_modules

coffeescript/app.coffee

+6-1
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ Splitter = require './javascript/lib/splitter'
1616
modal = require './javascript/lib/modal'
1717
autogrow = require './javascript/lib/autogrow'
1818
rangyinputs = require './javascript/lib/rangyinputs'
19+
mt = require 'mousetrap'
1920

2021
window.isOpen = (port, host, callback) ->
2122
isOpen = false
@@ -339,7 +340,11 @@ window.noted =
339340
window.noted.window = gui.Window.get()
340341
window.noted.window.show()
341342
window.noted.window.title = "Springseed"
342-
# window.noted.window.showDevTools()
343+
window.noted.window.showDevTools()
344+
345+
# Key Combos
346+
mt.bind ['ctrl+w', 'ctrl+q'], (e) ->
347+
window.noted.window.close()
343348

344349
window.noted.load.notebooks()
345350
window.noted.load.notes("all")

javascript/lib/mousetrap.js

+9
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
"marked": "0.2.x",
2323
"handlebars": "1.0.x",
2424
"dropbox": "0.9.x",
25-
"string": "1.3.x"
25+
"string": "1.3.x",
26+
"mousetrap": "0.0.1"
2627
}
2728
}

0 commit comments

Comments
 (0)