634 parentItem, |
634 parentItem, |
635 QCoreApplication.translate("BrowserModel", "Coding: {0}") |
635 QCoreApplication.translate("BrowserModel", "Coding: {0}") |
636 .format(dict["@@Coding@@"].coding)) |
636 .format(dict["@@Coding@@"].coding)) |
637 self._addItem(node, parentItem) |
637 self._addItem(node, parentItem) |
638 if "@@Globals@@" in keys: |
638 if "@@Globals@@" in keys: |
639 node = BrowserClassAttributesItem( |
639 node = BrowserGlobalsItem( |
640 parentItem, |
640 parentItem, |
641 dict["@@Globals@@"].globals, |
641 dict["@@Globals@@"].globals, |
642 QCoreApplication.translate("BrowserModel", "Globals")) |
642 QCoreApplication.translate("BrowserModel", "Globals")) |
643 self._addItem(node, parentItem) |
643 self._addItem(node, parentItem) |
644 if "@@Import@@" in keys or "@@ImportFrom@@" in keys: |
644 if "@@Import@@" in keys or "@@ImportFrom@@" in keys: |
1738 return self.lineno() > other.lineno() |
1738 return self.lineno() > other.lineno() |
1739 |
1739 |
1740 return BrowserItem.lessThan(self, other, column, order) |
1740 return BrowserItem.lessThan(self, other, column, order) |
1741 |
1741 |
1742 |
1742 |
|
1743 class BrowserGlobalsItem(BrowserClassAttributesItem): |
|
1744 """ |
|
1745 Class implementing the data structure for browser globals items. |
|
1746 """ |
|
1747 def __init__(self, parent, attributes, text, isClass=False): |
|
1748 """ |
|
1749 Constructor |
|
1750 |
|
1751 @param parent parent item |
|
1752 @param attributes list of attributes |
|
1753 @param text text to be shown by this item (string) |
|
1754 @param isClass flag indicating class attributes (boolean) |
|
1755 """ |
|
1756 BrowserClassAttributesItem.__init__(self, parent, attributes, text) |
|
1757 |
|
1758 |
1743 class BrowserCodingItem(BrowserItem): |
1759 class BrowserCodingItem(BrowserItem): |
1744 """ |
1760 """ |
1745 Class implementing the data structure for browser coding items. |
1761 Class implementing the data structure for browser coding items. |
1746 """ |
1762 """ |
1747 def __init__(self, parent, text): |
1763 def __init__(self, parent, text): |