299 font.setBold(True) |
299 font.setBold(True) |
300 act.setFont(font) |
300 act.setFont(font) |
301 menu.addSeparator() |
301 menu.addSeparator() |
302 |
302 |
303 act = menu.addAction( |
303 act = menu.addAction( |
304 UI.PixmapCache.getIcon("vcsCommit"), |
304 EricPixmapCache.getIcon("vcsCommit"), |
305 self.tr("Commit changes to repository..."), |
305 self.tr("Commit changes to repository..."), |
306 self._VCSCommit, |
306 self._VCSCommit, |
307 ) |
307 ) |
308 self.vcsMenuActions.append(act) |
308 self.vcsMenuActions.append(act) |
309 self.__addExtensionsMenu(menu, "mainMenu") |
309 self.__addExtensionsMenu(menu, "mainMenu") |
310 menu.addSeparator() |
310 menu.addSeparator() |
311 act = menu.addAction( |
311 act = menu.addAction( |
312 UI.PixmapCache.getIcon("vcsAdd"), self.tr("Add to repository"), self._VCSAdd |
312 EricPixmapCache.getIcon("vcsAdd"), |
|
313 self.tr("Add to repository"), |
|
314 self._VCSAdd, |
313 ) |
315 ) |
314 self.vcsAddMenuActions.append(act) |
316 self.vcsAddMenuActions.append(act) |
315 act = menu.addAction( |
317 act = menu.addAction( |
316 UI.PixmapCache.getIcon("vcsRemove"), |
318 EricPixmapCache.getIcon("vcsRemove"), |
317 self.tr("Remove from repository (and disk)"), |
319 self.tr("Remove from repository (and disk)"), |
318 self._VCSRemove, |
320 self._VCSRemove, |
319 ) |
321 ) |
320 self.vcsMenuActions.append(act) |
322 self.vcsMenuActions.append(act) |
321 act = menu.addAction( |
323 act = menu.addAction( |
322 UI.PixmapCache.getIcon("vcsRemove"), |
324 EricPixmapCache.getIcon("vcsRemove"), |
323 self.tr("Remove from repository only"), |
325 self.tr("Remove from repository only"), |
324 self.__HgForget, |
326 self.__HgForget, |
325 ) |
327 ) |
326 self.vcsMenuActions.append(act) |
328 self.vcsMenuActions.append(act) |
327 menu.addSeparator() |
329 menu.addSeparator() |
329 self.vcsMenuActions.append(act) |
331 self.vcsMenuActions.append(act) |
330 act = menu.addAction(self.tr("Move"), self.__HgMove) |
332 act = menu.addAction(self.tr("Move"), self.__HgMove) |
331 self.vcsMenuActions.append(act) |
333 self.vcsMenuActions.append(act) |
332 menu.addSeparator() |
334 menu.addSeparator() |
333 act = menu.addAction( |
335 act = menu.addAction( |
334 UI.PixmapCache.getIcon("vcsLog"), |
336 EricPixmapCache.getIcon("vcsLog"), |
335 self.tr("Show log browser"), |
337 self.tr("Show log browser"), |
336 self._VCSLogBrowser, |
338 self._VCSLogBrowser, |
337 ) |
339 ) |
338 self.vcsMenuActions.append(act) |
340 self.vcsMenuActions.append(act) |
339 menu.addSeparator() |
341 menu.addSeparator() |
340 act = menu.addAction( |
342 act = menu.addAction( |
341 UI.PixmapCache.getIcon("vcsStatus"), self.tr("Show status"), self._VCSStatus |
343 EricPixmapCache.getIcon("vcsStatus"), |
342 ) |
344 self.tr("Show status"), |
343 self.vcsMenuActions.append(act) |
345 self._VCSStatus, |
344 menu.addSeparator() |
346 ) |
345 act = menu.addAction( |
347 self.vcsMenuActions.append(act) |
346 UI.PixmapCache.getIcon("vcsDiff"), |
348 menu.addSeparator() |
|
349 act = menu.addAction( |
|
350 EricPixmapCache.getIcon("vcsDiff"), |
347 self.tr("Show differences"), |
351 self.tr("Show differences"), |
348 self._VCSDiff, |
352 self._VCSDiff, |
349 ) |
353 ) |
350 self.vcsMenuActions.append(act) |
354 self.vcsMenuActions.append(act) |
351 act = menu.addAction( |
355 act = menu.addAction( |
352 UI.PixmapCache.getIcon("vcsSbsDiff"), |
356 EricPixmapCache.getIcon("vcsSbsDiff"), |
353 self.tr("Show differences side-by-side"), |
357 self.tr("Show differences side-by-side"), |
354 self.__HgSbsDiff, |
358 self.__HgSbsDiff, |
355 ) |
359 ) |
356 self.vcsMenuActions.append(act) |
360 self.vcsMenuActions.append(act) |
357 act = menu.addAction( |
361 act = menu.addAction( |
358 UI.PixmapCache.getIcon("vcsDiff"), |
362 EricPixmapCache.getIcon("vcsDiff"), |
359 self.tr("Show differences (extended)"), |
363 self.tr("Show differences (extended)"), |
360 self.__HgExtendedDiff, |
364 self.__HgExtendedDiff, |
361 ) |
365 ) |
362 self.vcsMenuActions.append(act) |
366 self.vcsMenuActions.append(act) |
363 act = menu.addAction( |
367 act = menu.addAction( |
364 UI.PixmapCache.getIcon("vcsSbsDiff"), |
368 EricPixmapCache.getIcon("vcsSbsDiff"), |
365 self.tr("Show differences side-by-side (extended)"), |
369 self.tr("Show differences side-by-side (extended)"), |
366 self.__HgSbsExtendedDiff, |
370 self.__HgSbsExtendedDiff, |
367 ) |
371 ) |
368 self.vcsMenuActions.append(act) |
372 self.vcsMenuActions.append(act) |
369 self.annotateAct = menu.addAction( |
373 self.annotateAct = menu.addAction( |
370 self.tr("Show annotated file"), self.__HgAnnotate |
374 self.tr("Show annotated file"), self.__HgAnnotate |
371 ) |
375 ) |
372 self.vcsMenuActions.append(self.annotateAct) |
376 self.vcsMenuActions.append(self.annotateAct) |
373 menu.addSeparator() |
377 menu.addSeparator() |
374 act = menu.addAction( |
378 act = menu.addAction( |
375 UI.PixmapCache.getIcon("vcsRevert"), |
379 EricPixmapCache.getIcon("vcsRevert"), |
376 self.tr("Revert changes"), |
380 self.tr("Revert changes"), |
377 self.__HgRevert, |
381 self.__HgRevert, |
378 ) |
382 ) |
379 self.vcsMenuActions.append(act) |
383 self.vcsMenuActions.append(act) |
380 act = menu.addAction(self.tr("Conflicts resolved"), self.__HgResolved) |
384 act = menu.addAction(self.tr("Conflicts resolved"), self.__HgResolved) |
428 font.setBold(True) |
432 font.setBold(True) |
429 act.setFont(font) |
433 act.setFont(font) |
430 menu.addSeparator() |
434 menu.addSeparator() |
431 |
435 |
432 act = menu.addAction( |
436 act = menu.addAction( |
433 UI.PixmapCache.getIcon("vcsCommit"), |
437 EricPixmapCache.getIcon("vcsCommit"), |
434 self.tr("Commit changes to repository..."), |
438 self.tr("Commit changes to repository..."), |
435 self._VCSCommit, |
439 self._VCSCommit, |
436 ) |
440 ) |
437 self.vcsMultiMenuActions.append(act) |
441 self.vcsMultiMenuActions.append(act) |
438 self.__addExtensionsMenu(menu, "multiMenu") |
442 self.__addExtensionsMenu(menu, "multiMenu") |
439 menu.addSeparator() |
443 menu.addSeparator() |
440 act = menu.addAction( |
444 act = menu.addAction( |
441 UI.PixmapCache.getIcon("vcsAdd"), self.tr("Add to repository"), self._VCSAdd |
445 EricPixmapCache.getIcon("vcsAdd"), |
|
446 self.tr("Add to repository"), |
|
447 self._VCSAdd, |
442 ) |
448 ) |
443 self.vcsAddMultiMenuActions.append(act) |
449 self.vcsAddMultiMenuActions.append(act) |
444 act = menu.addAction( |
450 act = menu.addAction( |
445 UI.PixmapCache.getIcon("vcsRemove"), |
451 EricPixmapCache.getIcon("vcsRemove"), |
446 self.tr("Remove from repository (and disk)"), |
452 self.tr("Remove from repository (and disk)"), |
447 self._VCSRemove, |
453 self._VCSRemove, |
448 ) |
454 ) |
449 self.vcsMultiMenuActions.append(act) |
455 self.vcsMultiMenuActions.append(act) |
450 act = menu.addAction( |
456 act = menu.addAction( |
451 UI.PixmapCache.getIcon("vcsRemove"), |
457 EricPixmapCache.getIcon("vcsRemove"), |
452 self.tr("Remove from repository only"), |
458 self.tr("Remove from repository only"), |
453 self.__HgForget, |
459 self.__HgForget, |
454 ) |
460 ) |
455 self.vcsMultiMenuActions.append(act) |
461 self.vcsMultiMenuActions.append(act) |
456 menu.addSeparator() |
462 menu.addSeparator() |
457 act = menu.addAction( |
463 act = menu.addAction( |
458 UI.PixmapCache.getIcon("vcsStatus"), self.tr("Show status"), self._VCSStatus |
464 EricPixmapCache.getIcon("vcsStatus"), |
|
465 self.tr("Show status"), |
|
466 self._VCSStatus, |
459 ) |
467 ) |
460 self.vcsMultiMenuActions.append(act) |
468 self.vcsMultiMenuActions.append(act) |
461 menu.addSeparator() |
469 menu.addSeparator() |
462 act = menu.addAction( |
470 act = menu.addAction( |
463 UI.PixmapCache.getIcon("vcsDiff"), |
471 EricPixmapCache.getIcon("vcsDiff"), |
464 self.tr("Show differences"), |
472 self.tr("Show differences"), |
465 self._VCSDiff, |
473 self._VCSDiff, |
466 ) |
474 ) |
467 self.vcsMultiMenuActions.append(act) |
475 self.vcsMultiMenuActions.append(act) |
468 act = menu.addAction( |
476 act = menu.addAction( |
469 UI.PixmapCache.getIcon("vcsDiff"), |
477 EricPixmapCache.getIcon("vcsDiff"), |
470 self.tr("Show differences (extended)"), |
478 self.tr("Show differences (extended)"), |
471 self.__HgExtendedDiff, |
479 self.__HgExtendedDiff, |
472 ) |
480 ) |
473 self.vcsMultiMenuActions.append(act) |
481 self.vcsMultiMenuActions.append(act) |
474 menu.addSeparator() |
482 menu.addSeparator() |
475 act = menu.addAction( |
483 act = menu.addAction( |
476 UI.PixmapCache.getIcon("vcsRevert"), |
484 EricPixmapCache.getIcon("vcsRevert"), |
477 self.tr("Revert changes"), |
485 self.tr("Revert changes"), |
478 self.__HgRevert, |
486 self.__HgRevert, |
479 ) |
487 ) |
480 self.vcsMultiMenuActions.append(act) |
488 self.vcsMultiMenuActions.append(act) |
481 act = menu.addAction(self.tr("Conflicts resolved"), self.__HgResolved) |
489 act = menu.addAction(self.tr("Conflicts resolved"), self.__HgResolved) |
572 font.setBold(True) |
580 font.setBold(True) |
573 act.setFont(font) |
581 act.setFont(font) |
574 menu.addSeparator() |
582 menu.addSeparator() |
575 |
583 |
576 act = menu.addAction( |
584 act = menu.addAction( |
577 UI.PixmapCache.getIcon("vcsCommit"), |
585 EricPixmapCache.getIcon("vcsCommit"), |
578 self.tr("Commit changes to repository..."), |
586 self.tr("Commit changes to repository..."), |
579 self._VCSCommit, |
587 self._VCSCommit, |
580 ) |
588 ) |
581 self.vcsDirMenuActions.append(act) |
589 self.vcsDirMenuActions.append(act) |
582 self.__addExtensionsMenu(menu, "dirMenu") |
590 self.__addExtensionsMenu(menu, "dirMenu") |
583 menu.addSeparator() |
591 menu.addSeparator() |
584 act = menu.addAction( |
592 act = menu.addAction( |
585 UI.PixmapCache.getIcon("vcsAdd"), self.tr("Add to repository"), self._VCSAdd |
593 EricPixmapCache.getIcon("vcsAdd"), |
|
594 self.tr("Add to repository"), |
|
595 self._VCSAdd, |
586 ) |
596 ) |
587 self.vcsAddDirMenuActions.append(act) |
597 self.vcsAddDirMenuActions.append(act) |
588 act = menu.addAction( |
598 act = menu.addAction( |
589 UI.PixmapCache.getIcon("vcsRemove"), |
599 EricPixmapCache.getIcon("vcsRemove"), |
590 self.tr("Remove from repository (and disk)"), |
600 self.tr("Remove from repository (and disk)"), |
591 self._VCSRemove, |
601 self._VCSRemove, |
592 ) |
602 ) |
593 self.vcsDirMenuActions.append(act) |
603 self.vcsDirMenuActions.append(act) |
594 menu.addSeparator() |
604 menu.addSeparator() |
596 self.vcsDirMenuActions.append(act) |
606 self.vcsDirMenuActions.append(act) |
597 act = menu.addAction(self.tr("Move"), self.__HgMove) |
607 act = menu.addAction(self.tr("Move"), self.__HgMove) |
598 self.vcsDirMenuActions.append(act) |
608 self.vcsDirMenuActions.append(act) |
599 menu.addSeparator() |
609 menu.addSeparator() |
600 act = menu.addAction( |
610 act = menu.addAction( |
601 UI.PixmapCache.getIcon("vcsLog"), |
611 EricPixmapCache.getIcon("vcsLog"), |
602 self.tr("Show log browser"), |
612 self.tr("Show log browser"), |
603 self._VCSLogBrowser, |
613 self._VCSLogBrowser, |
604 ) |
614 ) |
605 self.vcsDirMenuActions.append(act) |
615 self.vcsDirMenuActions.append(act) |
606 menu.addSeparator() |
616 menu.addSeparator() |
607 act = menu.addAction( |
617 act = menu.addAction( |
608 UI.PixmapCache.getIcon("vcsStatus"), self.tr("Show status"), self._VCSStatus |
618 EricPixmapCache.getIcon("vcsStatus"), |
609 ) |
619 self.tr("Show status"), |
610 self.vcsDirMenuActions.append(act) |
620 self._VCSStatus, |
611 menu.addSeparator() |
621 ) |
612 act = menu.addAction( |
622 self.vcsDirMenuActions.append(act) |
613 UI.PixmapCache.getIcon("vcsDiff"), |
623 menu.addSeparator() |
|
624 act = menu.addAction( |
|
625 EricPixmapCache.getIcon("vcsDiff"), |
614 self.tr("Show differences"), |
626 self.tr("Show differences"), |
615 self._VCSDiff, |
627 self._VCSDiff, |
616 ) |
628 ) |
617 self.vcsDirMenuActions.append(act) |
629 self.vcsDirMenuActions.append(act) |
618 act = menu.addAction( |
630 act = menu.addAction( |
619 UI.PixmapCache.getIcon("vcsDiff"), |
631 EricPixmapCache.getIcon("vcsDiff"), |
620 self.tr("Show differences (extended)"), |
632 self.tr("Show differences (extended)"), |
621 self.__HgExtendedDiff, |
633 self.__HgExtendedDiff, |
622 ) |
634 ) |
623 self.vcsDirMenuActions.append(act) |
635 self.vcsDirMenuActions.append(act) |
624 menu.addSeparator() |
636 menu.addSeparator() |
625 act = menu.addAction( |
637 act = menu.addAction( |
626 UI.PixmapCache.getIcon("vcsRevert"), |
638 EricPixmapCache.getIcon("vcsRevert"), |
627 self.tr("Revert changes"), |
639 self.tr("Revert changes"), |
628 self.__HgRevert, |
640 self.__HgRevert, |
629 ) |
641 ) |
630 self.vcsDirMenuActions.append(act) |
642 self.vcsDirMenuActions.append(act) |
631 act = menu.addAction(self.tr("Conflicts resolved"), self.__HgResolved) |
643 act = menu.addAction(self.tr("Conflicts resolved"), self.__HgResolved) |
681 font.setBold(True) |
693 font.setBold(True) |
682 act.setFont(font) |
694 act.setFont(font) |
683 menu.addSeparator() |
695 menu.addSeparator() |
684 |
696 |
685 act = menu.addAction( |
697 act = menu.addAction( |
686 UI.PixmapCache.getIcon("vcsCommit"), |
698 EricPixmapCache.getIcon("vcsCommit"), |
687 self.tr("Commit changes to repository..."), |
699 self.tr("Commit changes to repository..."), |
688 self._VCSCommit, |
700 self._VCSCommit, |
689 ) |
701 ) |
690 self.vcsDirMultiMenuActions.append(act) |
702 self.vcsDirMultiMenuActions.append(act) |
691 self.__addExtensionsMenu(menu, "dirMultiMenu") |
703 self.__addExtensionsMenu(menu, "dirMultiMenu") |
692 menu.addSeparator() |
704 menu.addSeparator() |
693 act = menu.addAction( |
705 act = menu.addAction( |
694 UI.PixmapCache.getIcon("vcsAdd"), self.tr("Add to repository"), self._VCSAdd |
706 EricPixmapCache.getIcon("vcsAdd"), |
|
707 self.tr("Add to repository"), |
|
708 self._VCSAdd, |
695 ) |
709 ) |
696 self.vcsAddDirMultiMenuActions.append(act) |
710 self.vcsAddDirMultiMenuActions.append(act) |
697 act = menu.addAction( |
711 act = menu.addAction( |
698 UI.PixmapCache.getIcon("vcsRemove"), |
712 EricPixmapCache.getIcon("vcsRemove"), |
699 self.tr("Remove from repository (and disk)"), |
713 self.tr("Remove from repository (and disk)"), |
700 self._VCSRemove, |
714 self._VCSRemove, |
701 ) |
715 ) |
702 self.vcsDirMultiMenuActions.append(act) |
716 self.vcsDirMultiMenuActions.append(act) |
703 menu.addSeparator() |
717 menu.addSeparator() |
704 act = menu.addAction( |
718 act = menu.addAction( |
705 UI.PixmapCache.getIcon("vcsStatus"), self.tr("Show status"), self._VCSStatus |
719 EricPixmapCache.getIcon("vcsStatus"), |
|
720 self.tr("Show status"), |
|
721 self._VCSStatus, |
706 ) |
722 ) |
707 self.vcsDirMultiMenuActions.append(act) |
723 self.vcsDirMultiMenuActions.append(act) |
708 menu.addSeparator() |
724 menu.addSeparator() |
709 act = menu.addAction( |
725 act = menu.addAction( |
710 UI.PixmapCache.getIcon("vcsDiff"), |
726 EricPixmapCache.getIcon("vcsDiff"), |
711 self.tr("Show differences"), |
727 self.tr("Show differences"), |
712 self._VCSDiff, |
728 self._VCSDiff, |
713 ) |
729 ) |
714 self.vcsDirMultiMenuActions.append(act) |
730 self.vcsDirMultiMenuActions.append(act) |
715 act = menu.addAction( |
731 act = menu.addAction( |
716 UI.PixmapCache.getIcon("vcsDiff"), |
732 EricPixmapCache.getIcon("vcsDiff"), |
717 self.tr("Show differences (extended)"), |
733 self.tr("Show differences (extended)"), |
718 self.__HgExtendedDiff, |
734 self.__HgExtendedDiff, |
719 ) |
735 ) |
720 self.vcsDirMultiMenuActions.append(act) |
736 self.vcsDirMultiMenuActions.append(act) |
721 menu.addSeparator() |
737 menu.addSeparator() |
722 act = menu.addAction( |
738 act = menu.addAction( |
723 UI.PixmapCache.getIcon("vcsRevert"), |
739 EricPixmapCache.getIcon("vcsRevert"), |
724 self.tr("Revert changes"), |
740 self.tr("Revert changes"), |
725 self.__HgRevert, |
741 self.__HgRevert, |
726 ) |
742 ) |
727 self.vcsDirMultiMenuActions.append(act) |
743 self.vcsDirMultiMenuActions.append(act) |
728 act = menu.addAction(self.tr("Conflicts resolved"), self.__HgResolved) |
744 act = menu.addAction(self.tr("Conflicts resolved"), self.__HgResolved) |