Kiln » TortoiseHg » TortoiseHg
Clone URL:  
Pushed to one repository · View In Graph Contained in 2.0, 2.0.1, and 2.0.2

stable resolve: give a warning about subrepo visual diffs

Changeset 2d695b7d49fd

Parent 62089388a516

by Steve Borho

Changes to one file · Browse files at 2d695b7d49fd Showing diff from parent 62089388a516 Diff from another changeset...

 
194
195
196
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
197
198
 
199
200
201
202
203
204
 
207
208
209
210
 
211
212
213
214
215
216
 
219
220
221
222
 
223
224
225
226
227
228
 
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
 
214
215
 
 
216
217
218
 
221
222
223
 
224
225
 
 
226
227
228
 
231
232
233
 
234
235
 
 
236
237
238
@@ -194,11 +194,25 @@
  abspaths = [os.path.join(r,w) for r,w in paths]   wctxactions.edit(self, self.repo.ui, self.repo, abspaths)   + def getVdiffFiles(self, tree): + paths = self.getSelectedPaths(self.rtree) + if not paths: + return [] + files, sub = [], False + for root, wfile in paths: + if root == self.repo.root: + files.append(wfile) + else: + sub = True + if sub: + qtlib.InfoMsgBox(_('Unable to show subrepository files'), + _('Visual diffs are not supported for files in ' + 'subrepositories. They will not be shown.')) + return files +   def v3way(self): - paths = self.getSelectedPaths(self.rtree) + paths = self.getVdiffFiles(self.rtree)   if paths: - paths = [w for r,w in paths] - # TODO: will not work for subrepos   opts = {}   opts['rev'] = []   opts['tool'] = self.tcombo.readValue() @@ -207,10 +221,8 @@
  dlg.exec_()     def vp0(self): - paths = self.getSelectedPaths(self.rtree) + paths = self.getVdiffFiles(self.rtree)   if paths: - paths = [w for r,w in paths] - # TODO: will not work for subrepos   opts = {}   opts['rev'] = ['p1()']   opts['tool'] = self.tcombo.readValue() @@ -219,10 +231,8 @@
  dlg.exec_()     def vp1(self): - paths = self.getSelectedPaths(self.rtree) + paths = self.getVdiffFiles(self.rtree)   if paths: - paths = [w for r,w in paths] - # TODO: will not work for subrepos   opts = {}   opts['rev'] = ['p2()']   opts['tool'] = self.tcombo.readValue()