493 Private slot to handle the Commit context menu entry. |
494 Private slot to handle the Commit context menu entry. |
494 """ |
495 """ |
495 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
496 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
496 for itm in self.__getModifiedItems()] |
497 for itm in self.__getModifiedItems()] |
497 if not names: |
498 if not names: |
498 QMessageBox.information(self, |
499 E5MessageBox.information(self, |
499 self.trUtf8("Commit"), |
500 self.trUtf8("Commit"), |
500 self.trUtf8("""There are no uncommitted changes available/selected.""")) |
501 self.trUtf8("""There are no uncommitted changes available/selected.""")) |
501 return |
502 return |
502 |
503 |
503 if Preferences.getVCS("AutoSaveFiles"): |
504 if Preferences.getVCS("AutoSaveFiles"): |
519 Private slot to handle the Add context menu entry. |
520 Private slot to handle the Add context menu entry. |
520 """ |
521 """ |
521 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
522 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
522 for itm in self.__getUnversionedItems()] |
523 for itm in self.__getUnversionedItems()] |
523 if not names: |
524 if not names: |
524 QMessageBox.information(self, |
525 E5MessageBox.information(self, |
525 self.trUtf8("Add"), |
526 self.trUtf8("Add"), |
526 self.trUtf8("""There are no unversioned entries available/selected.""")) |
527 self.trUtf8("""There are no unversioned entries available/selected.""")) |
527 return |
528 return |
528 |
529 |
529 self.vcs.vcsAdd(names) |
530 self.vcs.vcsAdd(names) |
539 Private slot to handle the Revert context menu entry. |
540 Private slot to handle the Revert context menu entry. |
540 """ |
541 """ |
541 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
542 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
542 for itm in self.__getModifiedItems()] |
543 for itm in self.__getModifiedItems()] |
543 if not names: |
544 if not names: |
544 QMessageBox.information(self, |
545 E5MessageBox.information(self, |
545 self.trUtf8("Revert"), |
546 self.trUtf8("Revert"), |
546 self.trUtf8("""There are no uncommitted changes available/selected.""")) |
547 self.trUtf8("""There are no uncommitted changes available/selected.""")) |
547 return |
548 return |
548 |
549 |
549 self.vcs.vcsRevert(names) |
550 self.vcs.vcsRevert(names) |
559 Private slot to handle the Lock context menu entry. |
560 Private slot to handle the Lock context menu entry. |
560 """ |
561 """ |
561 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
562 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
562 for itm in self.__getLockActionItems(self.unlockedIndicators)] |
563 for itm in self.__getLockActionItems(self.unlockedIndicators)] |
563 if not names: |
564 if not names: |
564 QMessageBox.information(self, |
565 E5MessageBox.information(self, |
565 self.trUtf8("Lock"), |
566 self.trUtf8("Lock"), |
566 self.trUtf8("""There are no unlocked files available/selected.""")) |
567 self.trUtf8("""There are no unlocked files available/selected.""")) |
567 return |
568 return |
568 |
569 |
569 self.vcs.svnLock(names, parent = self) |
570 self.vcs.svnLock(names, parent = self) |
574 Private slot to handle the Unlock context menu entry. |
575 Private slot to handle the Unlock context menu entry. |
575 """ |
576 """ |
576 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
577 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
577 for itm in self.__getLockActionItems(self.lockedIndicators)] |
578 for itm in self.__getLockActionItems(self.lockedIndicators)] |
578 if not names: |
579 if not names: |
579 QMessageBox.information(self, |
580 E5MessageBox.information(self, |
580 self.trUtf8("Unlock"), |
581 self.trUtf8("Unlock"), |
581 self.trUtf8("""There are no locked files available/selected.""")) |
582 self.trUtf8("""There are no locked files available/selected.""")) |
582 return |
583 return |
583 |
584 |
584 self.vcs.svnUnlock(names, parent = self) |
585 self.vcs.svnUnlock(names, parent = self) |
589 Private slot to handle the Break Lock context menu entry. |
590 Private slot to handle the Break Lock context menu entry. |
590 """ |
591 """ |
591 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
592 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
592 for itm in self.__getLockActionItems(self.stealBreakLockIndicators)] |
593 for itm in self.__getLockActionItems(self.stealBreakLockIndicators)] |
593 if not names: |
594 if not names: |
594 QMessageBox.information(self, |
595 E5MessageBox.information(self, |
595 self.trUtf8("Break Lock"), |
596 self.trUtf8("Break Lock"), |
596 self.trUtf8("""There are no locked files available/selected.""")) |
597 self.trUtf8("""There are no locked files available/selected.""")) |
597 return |
598 return |
598 |
599 |
599 self.vcs.svnUnlock(names, parent = self, breakIt = True) |
600 self.vcs.svnUnlock(names, parent = self, breakIt = True) |
604 Private slot to handle the Break Lock context menu entry. |
605 Private slot to handle the Break Lock context menu entry. |
605 """ |
606 """ |
606 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
607 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
607 for itm in self.__getLockActionItems(self.stealBreakLockIndicators)] |
608 for itm in self.__getLockActionItems(self.stealBreakLockIndicators)] |
608 if not names: |
609 if not names: |
609 QMessageBox.information(self, |
610 E5MessageBox.information(self, |
610 self.trUtf8("Steal Lock"), |
611 self.trUtf8("Steal Lock"), |
611 self.trUtf8("""There are no locked files available/selected.""")) |
612 self.trUtf8("""There are no locked files available/selected.""")) |
612 return |
613 return |
613 |
614 |
614 self.vcs.svnLock(names, parent=self, stealIt=True) |
615 self.vcs.svnLock(names, parent=self, stealIt=True) |
619 Private slot to add entries to a changelist. |
620 Private slot to add entries to a changelist. |
620 """ |
621 """ |
621 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
622 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
622 for itm in self.__getNonChangelistItems()] |
623 for itm in self.__getNonChangelistItems()] |
623 if not names: |
624 if not names: |
624 QMessageBox.information(self, |
625 E5MessageBox.information(self, |
625 self.trUtf8("Remove from Changelist"), |
626 self.trUtf8("Remove from Changelist"), |
626 self.trUtf8( |
627 self.trUtf8( |
627 """There are no files available/selected not """ |
628 """There are no files available/selected not """ |
628 """belonging to a changelist.""" |
629 """belonging to a changelist.""" |
629 ) |
630 ) |
637 Private slot to remove entries from their changelists. |
638 Private slot to remove entries from their changelists. |
638 """ |
639 """ |
639 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
640 names = [os.path.join(self.dname, itm.text(self.__pathColumn)) \ |
640 for itm in self.__getChangelistItems()] |
641 for itm in self.__getChangelistItems()] |
641 if not names: |
642 if not names: |
642 QMessageBox.information(self, |
643 E5MessageBox.information(self, |
643 self.trUtf8("Remove from Changelist"), |
644 self.trUtf8("Remove from Changelist"), |
644 self.trUtf8( |
645 self.trUtf8( |
645 """There are no files available/selected belonging to a changelist.""" |
646 """There are no files available/selected belonging to a changelist.""" |
646 ) |
647 ) |
647 ) |
648 ) |