Use - as filename seperator for coffee script files. Fixes #15.

Also clean unused files and wrong file names.
This commit is contained in:
Cheng Zhao 2013-05-30 20:16:54 +08:00
parent 9ea1f9956e
commit bb69d99423
15 changed files with 28 additions and 39 deletions

View file

@ -0,0 +1,29 @@
EventEmitter = require('events').EventEmitter
v8Util = process.atomBinding 'v8_util'
objectsRegistry = require '../../atom/objects-registry.js'
BrowserWindow = process.atomBinding('window').BrowserWindow
BrowserWindow::__proto__ = EventEmitter.prototype
BrowserWindow::toggleDevTools = ->
opened = v8Util.getHiddenValue this, 'devtoolsOpened'
if opened
@closeDevTools()
v8Util.setHiddenValue this, 'devtoolsOpened', false
else
@openDevTools()
v8Util.setHiddenValue this, 'devtoolsOpened', true
BrowserWindow::restart = ->
@loadUrl(@getUrl())
BrowserWindow.getFocusedWindow = ->
windows = objectsRegistry.getAllWindows()
return window for window in windows when window.isFocused()
BrowserWindow.fromProcessIdAndRoutingId = (processId, routingId) ->
windows = objectsRegistry.getAllWindows()
return window for window in windows when window.getProcessId() == processId and
window.getRoutingId() == routingId
module.exports = BrowserWindow