mirror of
https://github.com/atom/atom.git
synced 2026-01-25 06:48:28 -05:00
window.atom, window.atom.app
This commit is contained in:
@@ -4,12 +4,12 @@ require 'window'
|
||||
|
||||
module.exports =
|
||||
class App
|
||||
@startup: ->
|
||||
constructor: ->
|
||||
KeyBinder.register "app", @
|
||||
window.startup()
|
||||
|
||||
@open: (path) ->
|
||||
open: (path) ->
|
||||
OSX.NSApp.open path
|
||||
|
||||
@quit: ->
|
||||
OSX.NSApp.terminate null
|
||||
quit: ->
|
||||
OSX.NSApp.terminate null
|
||||
|
||||
@@ -30,8 +30,7 @@ class Native
|
||||
|
||||
@openURL: (url) ->
|
||||
window.location = url
|
||||
App = require 'app'
|
||||
App.activeWindow.setTitle _.last url.replace(/\/$/,'').split '/'
|
||||
atom.app.activeWindow.setTitle _.last url.replace(/\/$/,'').split '/'
|
||||
|
||||
# Returns null or a file path.
|
||||
@savePanel: ->
|
||||
|
||||
@@ -1,3 +1,6 @@
|
||||
# Like sands through the hourglass, so are the days of our lives.
|
||||
|
||||
App = require 'app'
|
||||
App.startup()
|
||||
|
||||
window.atom = {}
|
||||
window.atom.app = new App
|
||||
|
||||
Reference in New Issue
Block a user