24 QLineEdit, |
24 QLineEdit, |
25 QMenu, |
25 QMenu, |
26 QInputDialog, |
26 QInputDialog, |
27 ) |
27 ) |
28 |
28 |
29 from EricWidgets.EricApplication import ericApp |
29 from eric7.EricWidgets.EricApplication import ericApp |
30 from EricWidgets import EricMessageBox, EricFileDialog |
30 from eric7.EricWidgets import EricMessageBox, EricFileDialog |
31 from EricGui.EricOverrideCursor import EricOverrideCursorProcess |
31 from eric7.EricGui.EricOverrideCursor import EricOverrideCursorProcess |
32 |
32 |
33 from Globals import strToQByteArray |
33 from eric7.Globals import strToQByteArray |
34 |
34 |
35 from .Ui_GitLogBrowserDialog import Ui_GitLogBrowserDialog |
35 from .Ui_GitLogBrowserDialog import Ui_GitLogBrowserDialog |
36 |
36 |
37 from .GitDiffHighlighter import GitDiffHighlighter |
37 from .GitDiffHighlighter import GitDiffHighlighter |
38 from .GitDiffGenerator import GitDiffGenerator |
38 from .GitDiffGenerator import GitDiffGenerator |
39 |
39 |
40 import UI.PixmapCache |
40 from eric7.EricGui import EricPixmapCache |
41 import Preferences |
41 from eric7 import Preferences |
42 |
42 |
43 COLORNAMES = [ |
43 COLORNAMES = [ |
44 "red", |
44 "red", |
45 "green", |
45 "green", |
46 "purple", |
46 "purple", |
115 self.buttonBox.button(QDialogButtonBox.StandardButton.Cancel).setDefault(True) |
115 self.buttonBox.button(QDialogButtonBox.StandardButton.Cancel).setDefault(True) |
116 |
116 |
117 self.filesTree.headerItem().setText(self.filesTree.columnCount(), "") |
117 self.filesTree.headerItem().setText(self.filesTree.columnCount(), "") |
118 self.filesTree.header().setSortIndicator(1, Qt.SortOrder.AscendingOrder) |
118 self.filesTree.header().setSortIndicator(1, Qt.SortOrder.AscendingOrder) |
119 |
119 |
120 self.upButton.setIcon(UI.PixmapCache.getIcon("1uparrow")) |
120 self.upButton.setIcon(EricPixmapCache.getIcon("1uparrow")) |
121 self.downButton.setIcon(UI.PixmapCache.getIcon("1downarrow")) |
121 self.downButton.setIcon(EricPixmapCache.getIcon("1downarrow")) |
122 |
122 |
123 self.refreshButton = self.buttonBox.addButton( |
123 self.refreshButton = self.buttonBox.addButton( |
124 self.tr("&Refresh"), QDialogButtonBox.ButtonRole.ActionRole |
124 self.tr("&Refresh"), QDialogButtonBox.ButtonRole.ActionRole |
125 ) |
125 ) |
126 self.refreshButton.setToolTip(self.tr("Press to refresh the list of commits")) |
126 self.refreshButton.setToolTip(self.tr("Press to refresh the list of commits")) |
127 self.refreshButton.setEnabled(False) |
127 self.refreshButton.setEnabled(False) |
128 |
128 |
129 self.findPrevButton.setIcon(UI.PixmapCache.getIcon("1leftarrow")) |
129 self.findPrevButton.setIcon(EricPixmapCache.getIcon("1leftarrow")) |
130 self.findNextButton.setIcon(UI.PixmapCache.getIcon("1rightarrow")) |
130 self.findNextButton.setIcon(EricPixmapCache.getIcon("1rightarrow")) |
131 self.__findBackwards = False |
131 self.__findBackwards = False |
132 |
132 |
133 self.modeComboBox.addItem(self.tr("Find"), "find") |
133 self.modeComboBox.addItem(self.tr("Find"), "find") |
134 self.modeComboBox.addItem(self.tr("Filter"), "filter") |
134 self.modeComboBox.addItem(self.tr("Filter"), "filter") |
135 |
135 |
372 ) |
372 ) |
373 self.__describeAct.setToolTip( |
373 self.__describeAct.setToolTip( |
374 self.tr("Show the most recent tag reachable from a commit") |
374 self.tr("Show the most recent tag reachable from a commit") |
375 ) |
375 ) |
376 |
376 |
377 self.actionsButton.setIcon(UI.PixmapCache.getIcon("actionsToolButton")) |
377 self.actionsButton.setIcon(EricPixmapCache.getIcon("actionsToolButton")) |
378 self.actionsButton.setMenu(self.__actionsMenu) |
378 self.actionsButton.setMenu(self.__actionsMenu) |
379 |
379 |
380 def __initData(self): |
380 def __initData(self): |
381 """ |
381 """ |
382 Private method to (re-)initialize some data. |
382 Private method to (re-)initialize some data. |