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

branch
eric7
changeset 9482
a2bc06a54d9d
parent 9473
3f23dbf37dbe
child 9576
be9f8e7e42e0
equal deleted inserted replaced
9481:0b936ff1bbb9 9482:a2bc06a54d9d
1880 @pyqtSlot() 1880 @pyqtSlot()
1881 def __branchActTriggered(self): 1881 def __branchActTriggered(self):
1882 """ 1882 """
1883 Private slot to create a new branch starting at the selected commit. 1883 Private slot to create a new branch starting at the selected commit.
1884 """ 1884 """
1885 from .GitBranchDialog import GitBranchDialog
1886
1885 if len(self.logTree.selectedItems()) == 1: 1887 if len(self.logTree.selectedItems()) == 1:
1886 from .GitBranchDialog import GitBranchDialog
1887
1888 itm = self.logTree.selectedItems()[0] 1888 itm = self.logTree.selectedItems()[0]
1889 commit = itm.text(self.CommitIdColumn) 1889 commit = itm.text(self.CommitIdColumn)
1890 branches = [ 1890 branches = [
1891 b for b in itm.text(self.BranchColumn).split(", ") if "/" not in b 1891 b for b in itm.text(self.BranchColumn).split(", ") if "/" not in b
1892 ] 1892 ]
1918 def __branchSwitchActTriggered(self): 1918 def __branchSwitchActTriggered(self):
1919 """ 1919 """
1920 Private slot to create a new branch starting at the selected commit 1920 Private slot to create a new branch starting at the selected commit
1921 and switch the work tree to it. 1921 and switch the work tree to it.
1922 """ 1922 """
1923 from .GitBranchDialog import GitBranchDialog
1924
1923 if len(self.logTree.selectedItems()) == 1: 1925 if len(self.logTree.selectedItems()) == 1:
1924 from .GitBranchDialog import GitBranchDialog
1925
1926 itm = self.logTree.selectedItems()[0] 1926 itm = self.logTree.selectedItems()[0]
1927 commit = itm.text(self.CommitIdColumn) 1927 commit = itm.text(self.CommitIdColumn)
1928 branches = [ 1928 branches = [
1929 b for b in itm.text(self.BranchColumn).split(", ") if "/" not in b 1929 b for b in itm.text(self.BranchColumn).split(", ") if "/" not in b
1930 ] 1930 ]

eric ide

mercurial