tabs dont know bout no browser

This commit is contained in:
Chris Wanstrath
2011-11-12 02:22:18 -08:00
parent 45e5924ee4
commit 64b547dbb6

View File

@@ -2,7 +2,6 @@ $ = require 'jquery'
_ = require 'underscore'
Pane = require 'pane'
Browser = require 'browser'
module.exports =
class TabsPane extends Pane
@@ -42,12 +41,7 @@ class TabsPane extends Pane
existing = $("#tabs [data-path='#{path}']")
return @switchToTab existing if existing.length
name = if not path
"untitled"
else if Browser.isPathUrl path
path.match(/(\w+:\/\/)([^\/]+)?/)[2]
else
_.last path.split '/'
name = _.last (path or 'untitled').split '/'
$("#tabs ul .active").removeClass()
$("#tabs ul").append """