chosen example can be unchosen via ctrl also
This commit is contained in:
parent
571ad0c5a0
commit
ed16384063
|
@ -49,7 +49,11 @@ class ShowExampleEdit(CtrlClickMessage):
|
||||||
|
|
||||||
def update_model_ctrl(self, model):
|
def update_model_ctrl(self, model):
|
||||||
example = self.get_arg(0, Example)
|
example = self.get_arg(0, Example)
|
||||||
model.chosen_examples.append(example)
|
|
||||||
|
if example in model.chosen_examples:
|
||||||
|
model.chosen_examples.remove(example)
|
||||||
|
else:
|
||||||
|
model.chosen_examples.append(example)
|
||||||
|
|
||||||
def reset(self):
|
def reset(self):
|
||||||
# special case, when choosing messages dont reset
|
# special case, when choosing messages dont reset
|
||||||
|
|
Loading…
Reference in New Issue
Block a user