mirror of
https://github.com/pulsar-edit/pulsar.git
synced 2024-09-21 07:58:04 +03:00
Put 'atom' in window title when no panes are open
Previously the title would revert to 'index.html' when focus was gained and no panes were open.
This commit is contained in:
parent
d136837c79
commit
0b9f6b14ba
@ -175,10 +175,10 @@ describe "RootView", ->
|
||||
expect(rootView.title).toBe "#{item.getTitle()} - #{project.getPath()}"
|
||||
|
||||
describe "when the last pane item is removed", ->
|
||||
it "sets the title to the project's path", ->
|
||||
it "update the title to contain the project's path", ->
|
||||
rootView.getActivePane().remove()
|
||||
expect(rootView.getActivePaneItem()).toBeUndefined()
|
||||
expect(rootView.title).toBe project.getPath()
|
||||
expect(rootView.title).toBe "atom -#{project.getPath()}"
|
||||
|
||||
describe "when an inactive pane's item changes", ->
|
||||
it "does not update the title", ->
|
||||
|
@ -82,7 +82,7 @@ class RootView extends View
|
||||
@getActivePane().focus()
|
||||
false
|
||||
else
|
||||
@setTitle(null)
|
||||
@updateTitle()
|
||||
focusableChild = this.find("[tabindex=-1]:visible:first")
|
||||
if focusableChild.length
|
||||
focusableChild.focus()
|
||||
@ -115,7 +115,7 @@ class RootView extends View
|
||||
if item = @getActivePaneItem()
|
||||
@setTitle("#{item.getTitle?() ? 'untitled'} - #{projectPath}")
|
||||
else
|
||||
@setTitle(projectPath)
|
||||
@setTitle("atom - #{projectPath}")
|
||||
else
|
||||
@setTitle('untitled')
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user