Show More
@@ -111,13 +111,13 b' class filectx(object):' | |||||
111 | def manifest(self): return self.changectx().manifest() |
|
111 | def manifest(self): return self.changectx().manifest() | |
112 |
|
112 | |||
113 | def data(self): return self._filelog.read(self._filenode) |
|
113 | def data(self): return self._filelog.read(self._filenode) | |
114 | def metadata(self): return self._filelog.readmeta(self._filenode) |
|
|||
115 | def renamed(self): return self._filelog.renamed(self._filenode) |
|
114 | def renamed(self): return self._filelog.renamed(self._filenode) | |
116 | def path(self): return self._path |
|
115 | def path(self): return self._path | |
117 |
|
116 | |||
118 | def parents(self): |
|
117 | def parents(self): | |
119 | p = [ (self._path, n) for n in self._filelog.parents(self._filenode) ] |
|
118 | p = [ (self._path, n) for n in self._filelog.parents(self._filenode) ] | |
120 | r = self.renamed() |
|
119 | r = self.renamed() | |
|
120 | ||||
121 | if r: |
|
121 | if r: | |
122 | p[0] = r |
|
122 | p[0] = r | |
123 | return [ filectx(self._repo, p, fileid=n) for p,n in p if n != nullid ] |
|
123 | return [ filectx(self._repo, p, fileid=n) for p,n in p if n != nullid ] |
@@ -37,7 +37,7 b' class filelog(revlog):' | |||||
37 | s = t.index('\1\n', 2) |
|
37 | s = t.index('\1\n', 2) | |
38 | return t[s+2:] |
|
38 | return t[s+2:] | |
39 |
|
39 | |||
40 | def readmeta(self, node): |
|
40 | def _readmeta(self, node): | |
41 | t = self.revision(node) |
|
41 | t = self.revision(node) | |
42 | if not t.startswith('\1\n'): |
|
42 | if not t.startswith('\1\n'): | |
43 | return {} |
|
43 | return {} | |
@@ -60,7 +60,7 b' class filelog(revlog):' | |||||
60 | def renamed(self, node): |
|
60 | def renamed(self, node): | |
61 | if self.parents(node)[0] != nullid: |
|
61 | if self.parents(node)[0] != nullid: | |
62 | return False |
|
62 | return False | |
63 | m = self.readmeta(node) |
|
63 | m = self._readmeta(node) | |
64 | if m and m.has_key("copy"): |
|
64 | if m and m.has_key("copy"): | |
65 | return (m["copy"], bin(m["copyrev"])) |
|
65 | return (m["copy"], bin(m["copyrev"])) | |
66 | return False |
|
66 | return False |
General Comments 0
You need to be logged in to leave comments.
Login now