Debugger/VariablesViewer.py

changeset 5736
000ea446ff4b
parent 5624
cdd346d8858b
child 5964
066e6c78a367
equal deleted inserted replaced
5735:f606dbe20be6 5736:000ea446ff4b
11 try: 11 try:
12 str = unicode 12 str = unicode
13 except NameError: 13 except NameError:
14 pass 14 pass
15 15
16 from PyQt5.QtCore import Qt, QRegExp, qVersion, QCoreApplication 16 from PyQt5.QtCore import Qt, QRegExp, QCoreApplication
17 from PyQt5.QtWidgets import QTreeWidget, QTreeWidgetItem, QAbstractItemView, \ 17 from PyQt5.QtWidgets import QTreeWidget, QTreeWidgetItem, QAbstractItemView, \
18 QMenu 18 QMenu
19 19
20 from E5Gui.E5Application import e5App 20 from E5Gui.E5Application import e5App
21 21
22 from .Config import ConfigVarTypeDispStrings 22 from .Config import ConfigVarTypeDispStrings
23 23
24 import Preferences 24 import Preferences
25 import Utilities 25 import Utilities
26 from Globals import qVersionTuple
26 27
27 28
28 class VariableItem(QTreeWidgetItem): 29 class VariableItem(QTreeWidgetItem):
29 """ 30 """
30 Class implementing the data structure for variable items. 31 Class implementing the data structure for variable items.
376 )) 377 ))
377 378
378 header = self.header() 379 header = self.header()
379 header.setSortIndicator(0, Qt.AscendingOrder) 380 header.setSortIndicator(0, Qt.AscendingOrder)
380 header.setSortIndicatorShown(True) 381 header.setSortIndicatorShown(True)
381 if qVersion() >= "5.0.0": 382 if qVersionTuple() >= (5, 0, 0):
382 header.setSectionsClickable(True) 383 header.setSectionsClickable(True)
383 else: 384 else:
384 header.setClickable(True) 385 header.setClickable(True)
385 header.sectionClicked.connect(self.__sectionClicked) 386 header.sectionClicked.connect(self.__sectionClicked)
386 header.resizeSection(0, 120) # variable column 387 header.resizeSection(0, 120) # variable column

eric ide

mercurial