project has an activeResource, returns it in responder()

This commit is contained in:
Chris Wanstrath
2011-11-12 02:05:29 -08:00
parent 990d10bbe6
commit 47278fee1b

View File

@@ -18,6 +18,11 @@ class Project extends Resource
resources: []
activeResource: null
responder: ->
@activeResource
open: (url) ->
if not @url
# Can only open directories.
@@ -43,7 +48,7 @@ class Project extends Resource
break if success = resource.open url
if success
@resources.push resource
@resources.push @activeResource = resource
true
# Determines if a passed URL is a child of @url.