268 items = self.browser.getSelectedItems([ProjectBrowserFileItem]) |
268 items = self.browser.getSelectedItems([ProjectBrowserFileItem]) |
269 names = [itm.fileName() for itm in items] |
269 names = [itm.fileName() for itm in items] |
270 |
270 |
271 dlg = DeleteFilesConfirmationDialog( |
271 dlg = DeleteFilesConfirmationDialog( |
272 self.parent(), |
272 self.parent(), |
273 self.trUtf8("Remove from repository (and disk)"), |
273 self.tr("Remove from repository (and disk)"), |
274 self.trUtf8( |
274 self.tr( |
275 "Do you really want to remove these translation files from" |
275 "Do you really want to remove these translation files from" |
276 " the repository (and disk)?"), |
276 " the repository (and disk)?"), |
277 names) |
277 names) |
278 else: |
278 else: |
279 items = self.browser.getSelectedItems() |
279 items = self.browser.getSelectedItems() |
288 files = [self.browser.project.getRelativePath(name) |
288 files = [self.browser.project.getRelativePath(name) |
289 for name in names] |
289 for name in names] |
290 |
290 |
291 dlg = DeleteFilesConfirmationDialog( |
291 dlg = DeleteFilesConfirmationDialog( |
292 self.parent(), |
292 self.parent(), |
293 self.trUtf8("Remove from repository (and disk)"), |
293 self.tr("Remove from repository (and disk)"), |
294 self.trUtf8( |
294 self.tr( |
295 "Do you really want to remove these files/directories" |
295 "Do you really want to remove these files/directories" |
296 " from the repository (and disk)?"), |
296 " from the repository (and disk)?"), |
297 files) |
297 files) |
298 |
298 |
299 if dlg.exec_() == QDialog.Accepted: |
299 if dlg.exec_() == QDialog.Accepted: |
314 try: |
314 try: |
315 fn = itm.fileName() |
315 fn = itm.fileName() |
316 except AttributeError: |
316 except AttributeError: |
317 fn = itm.dirName() |
317 fn = itm.dirName() |
318 self.vcs.vcsLog(fn) |
318 self.vcs.vcsLog(fn) |
|
319 |
|
320 def _VCSLogBrowser(self): |
|
321 """ |
|
322 Protected slot called by the context menu to show the log browser for a |
|
323 file. |
|
324 """ |
|
325 itm = self.browser.currentItem() |
|
326 try: |
|
327 fn = itm.fileName() |
|
328 isFile = True |
|
329 except AttributeError: |
|
330 fn = itm.dirName() |
|
331 isFile = False |
|
332 self.vcs.vcsLogBrowser(fn, isFile=isFile) |
319 |
333 |
320 def _VCSDiff(self): |
334 def _VCSDiff(self): |
321 """ |
335 """ |
322 Protected slot called by the context menu to show the difference of a |
336 Protected slot called by the context menu to show the difference of a |
323 file/directory to the repository. |
337 file/directory to the repository. |