Put window.onerror method in the window file.

This commit is contained in:
Corey Johnson & Nathan Sobo
2011-12-12 15:05:07 -08:00
parent 212c10cd79
commit dcf474b9d2
2 changed files with 1 additions and 4 deletions

View File

@@ -12,10 +12,6 @@
<script src='src/stdlib/require.js'></script>
<script>
window.onerror = function() {
window.showConsole(true)
}
window.onload = function() {
require('startup');
}

View File

@@ -8,6 +8,7 @@ _ = require 'underscore'
# window:load - Same as window.onLoad. Final event of app startup.
windowAdditions =
url: $atomController.url?.toString()
onerror: -> @showConsole true
startup: ->
if not @resource = atom.router.open @url