equal
deleted
inserted
replaced
33 |
33 |
34 def __init__(self, repo): |
34 def __init__(self, repo): |
35 self._names = util.sortdict() |
35 self._names = util.sortdict() |
36 self._repo = weakref.ref(repo) |
36 self._repo = weakref.ref(repo) |
37 |
37 |
|
38 # we need current mercurial named objects (bookmarks, tags, and |
|
39 # branches) to be initialized somewhere, so that place is here |
|
40 self.addnamespace("bookmarks", |
|
41 lambda repo, name: tolist(repo._bookmarks.get(name))) |
|
42 |
38 @property |
43 @property |
39 def repo(self): |
44 def repo(self): |
40 return self._repo() |
45 return self._repo() |
41 |
46 |
42 def addnamespace(self, namespace, namemap, order=None): |
47 def addnamespace(self, namespace, namemap, order=None): |