UI/BrowserSortFilterProxyModel.py

changeset 3591
2f2a4a76dd22
parent 3178
f25fc1364c88
child 3656
441956d8fce5
equal deleted inserted replaced
3590:5280e37405b8 3591:2f2a4a76dd22
39 self.__sortOrder = order 39 self.__sortOrder = order
40 super(BrowserSortFilterProxyModel, self).sort(column, order) 40 super(BrowserSortFilterProxyModel, self).sort(column, order)
41 41
42 def lessThan(self, left, right): 42 def lessThan(self, left, right):
43 """ 43 """
44 Protected method used to sort the displayed items. 44 Public method used to sort the displayed items.
45 45
46 It implements a special sorting function that takes into account, 46 It implements a special sorting function that takes into account,
47 if folders should be shown first, and that __init__ is always the first 47 if folders should be shown first, and that __init__ is always the first
48 method of a class. 48 method of a class.
49 49
85 sindex = self.mapToSource(parent) 85 sindex = self.mapToSource(parent)
86 return self.sourceModel().hasChildren(sindex) 86 return self.sourceModel().hasChildren(sindex)
87 87
88 def filterAcceptsRow(self, source_row, source_parent): 88 def filterAcceptsRow(self, source_row, source_parent):
89 """ 89 """
90 Protected method to filter rows. 90 Public method to filter rows.
91 91
92 It implements a filter to suppress the display of non public 92 It implements a filter to suppress the display of non public
93 classes, methods and attributes. 93 classes, methods and attributes.
94 94
95 @param source_row row number (in the source model) of item (integer) 95 @param source_row row number (in the source model) of item (integer)

eric ide

mercurial