167 menu.addSeparator() |
167 menu.addSeparator() |
168 act = menu.addAction(self.tr("Remove Rule"), self.removeRule) |
168 act = menu.addAction(self.tr("Remove Rule"), self.removeRule) |
169 if item.parent() is None: |
169 if item.parent() is None: |
170 act.setDisabled(True) |
170 act.setDisabled(True) |
171 |
171 |
172 menu.exec_(self.viewport().mapToGlobal(pos)) |
172 menu.exec(self.viewport().mapToGlobal(pos)) |
173 |
173 |
174 def __itemChanged(self, itm): |
174 def __itemChanged(self, itm): |
175 """ |
175 """ |
176 Private slot to handle the change of an item. |
176 Private slot to handle the change of an item. |
177 |
177 |