Skip to content

Commit

Permalink
Merge pull request #918 from janezd/fix-colorer
Browse files Browse the repository at this point in the history
Color: Fix model reset
  • Loading branch information
janezd committed Dec 11, 2015
2 parents 0a59977 + abaf472 commit 18e5029
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Orange/widgets/data/owcolor.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ def flags(self, _):
return Qt.ItemIsEditable | Qt.ItemIsEnabled | Qt.ItemIsSelectable

def set_data(self, variables):
self.emit(SIGNAL("modelAboutToBeReset()"))
self.variables = variables
self.emit(SIGNAL("dataChanged(QModelIndex, QModelIndex)"),
self.index(0, 0), self.index(self.n_columns(), self.n_rows()))
self.emit(SIGNAL("modelReset()"))

def rowCount(self, parent):
return 0 if parent.isValid() else self.n_rows()
Expand Down Expand Up @@ -264,7 +264,7 @@ def set_data(self, data):
self.disc_colors = []
self.cont_colors = []
if data is None:
self.data = None
self.data = self.domain = None
else:
def create_part(variables):
vars = []
Expand Down

0 comments on commit 18e5029

Please sign in to comment.