src/eric7/Plugins/VcsPlugins/vcsGit/GitLogBrowserDialog.py

branch
eric7
changeset 10069
435cc5875135
parent 9653
e67609152c5e
child 10373
093dcebe5ecb
equal deleted inserted replaced
10068:7febcdccb2a1 10069:435cc5875135
560 ) 560 )
561 561
562 self.__commitIds = nextCommitIds 562 self.__commitIds = nextCommitIds
563 return col, color, edges 563 return col, color, edges
564 564
565 def __generateIcon( 565 def __generateIcon(self, column, bottomedges, topedges, dotColor, currentCommit):
566 self, column, color, bottomedges, topedges, dotColor, currentCommit
567 ):
568 """ 566 """
569 Private method to generate an icon containing the revision tree for the 567 Private method to generate an icon containing the revision tree for the
570 given data. 568 given data.
571 569
572 @param column column index of the revision (integer) 570 @param column column index of the revision (integer)
573 @param color color of the node (integer)
574 @param bottomedges list of edges for the bottom of the node 571 @param bottomedges list of edges for the bottom of the node
575 (list of tuples of three integers) 572 (list of tuples of three integers)
576 @param topedges list of edges for the top of the node 573 @param topedges list of edges for the top of the node
577 (list of tuples of three integers) 574 (list of tuples of three integers)
578 @param dotColor color to be used for the dot (QColor) 575 @param dotColor color to be used for the dot (QColor)
773 else None 770 else None
774 ) 771 )
775 772
776 icon = self.__generateIcon( 773 icon = self.__generateIcon(
777 column, 774 column,
778 color,
779 edges, 775 edges,
780 topedges, 776 topedges,
781 QColor("blue"), 777 QColor("blue"),
782 commitId == self.__projectRevision, 778 commitId == self.__projectRevision,
783 ) 779 )
911 self.logTree.clear() 907 self.logTree.clear()
912 self.__started = True 908 self.__started = True
913 self.__identifyProject() 909 self.__identifyProject()
914 self.__getLogEntries(noEntries=noEntries) 910 self.__getLogEntries(noEntries=noEntries)
915 911
912 @pyqtSlot(int, QProcess.ExitStatus)
916 def __procFinished(self, exitCode, exitStatus): 913 def __procFinished(self, exitCode, exitStatus):
917 """ 914 """
918 Private slot connected to the finished signal. 915 Private slot connected to the finished signal.
919 916
920 @param exitCode exit code of the process (integer) 917 @param exitCode exit code of the process (integer)
1389 self.__diffUpdatesFiles = False 1386 self.__diffUpdatesFiles = False
1390 1387
1391 selectedItems = self.logTree.selectedItems() 1388 selectedItems = self.logTree.selectedItems()
1392 if len(selectedItems) == 1: 1389 if len(selectedItems) == 1:
1393 self.detailsEdit.setHtml(self.__generateDetailsTableText(selectedItems[0])) 1390 self.detailsEdit.setHtml(self.__generateDetailsTableText(selectedItems[0]))
1394 self.__updateFilesTree(self.filesTree, selectedItems[0]) 1391 self.__updateFilesTree(selectedItems[0])
1395 self.__resizeColumnsFiles() 1392 self.__resizeColumnsFiles()
1396 self.__resortFiles() 1393 self.__resortFiles()
1397 if self.filesTree.topLevelItemCount() == 0: 1394 if self.filesTree.topLevelItemCount() == 0:
1398 self.__diffUpdatesFiles = True 1395 self.__diffUpdatesFiles = True
1399 # give diff a chance to update the files list 1396 # give diff a chance to update the files list
1487 else: 1484 else:
1488 html = "" 1485 html = ""
1489 1486
1490 return html 1487 return html
1491 1488
1492 def __updateFilesTree(self, parent, itm): 1489 def __updateFilesTree(self, itm):
1493 """ 1490 """
1494 Private method to update the files tree with changes of the given item. 1491 Private method to update the files tree with changes of the given item.
1495 1492
1496 @param parent parent for the items to be added
1497 @type QTreeWidget or QTreeWidgetItem
1498 @param itm reference to the item the update should be based on 1493 @param itm reference to the item the update should be based on
1499 @type QTreeWidgetItem 1494 @type QTreeWidgetItem
1500 """ 1495 """
1501 if itm is not None: 1496 if itm is not None:
1502 changes = itm.data(0, self.__changesRole) 1497 changes = itm.data(0, self.__changesRole)

eric ide

mercurial