Changeset 2de46fd147d0…
Parent df658fdcdf9c…
by
Changes to one file · Browse files at 2de46fd147d0 Showing diff from parent df658fdcdf9c Diff from another changeset...
@@ -323,7 +323,7 @@ return
path, status, mst, upath, ext, sz = row
wfile = util.pconvert(path)
- self.fileview.setContext(self.wctx)
+ self.fileview.setContext(self.repo[None])
self.fileview.displayFile(wfile, status=status)
@@ -334,11 +334,11 @@
def __init__(self, repo, pats, opts, parent=None):
super(StatusThread, self).__init__()
- self.repo = repo
+ self.repo = hg.repository(repo.ui, repo.root)
self.pats = pats
self.opts = opts
self.wctx = None
- self.patchecked = None
+ self.patchecked = {}
def run(self):
self.repo.dirstate.invalidate()
@@ -358,10 +358,19 @@ d = dict([(fn, True) for fn in status[i]])
patchecked.update(d)
wctx = context.workingctx(self.repo, changes=status)
+ self.patchecked = patchecked
else:
wctx = self.repo[None]
wctx.status(**stopts)
- except (OSError, IOError), e:
+ self.wctx = wctx
+
+ wctx.dirtySubrepos = []
+ for s in wctx.substate:
+ if wctx.sub(s).dirty():
+ wctx.dirtySubrepos.append(s)
+ except EnvironmentError, e:
+ self.showMessage.emit(hglib.tounicode(str(e)))
+ except (error.RepoLookupError, error.ConfigError), e:
self.showMessage.emit(hglib.tounicode(str(e)))
except util.Abort, e:
if e.hint:
@@ -370,22 +379,6 @@ else:
err = hglib.tounicode(str(e))
self.showMessage.emit(err)
- try:
- wctx.dirtySubrepos = []
- for s in wctx.substate:
- if wctx.sub(s).dirty():
- wctx.dirtySubrepos.append(s)
- except (OSError, IOError, error.RepoLookupError, error.ConfigError), e:
- self.showMessage.emit(hglib.tounicode(str(e)))
- except util.Abort, e:
- if e.hint:
- err = _('%s (hint: %s)') % (hglib.tounicode(str(e)),
- hglib.tounicode(e.hint))
- else:
- err = hglib.tounicode(str(e))
- self.showMessage.emit(err)
- self.wctx = wctx
- self.patchecked = patchecked
class WctxFileTree(QTreeView):
|
Loading...