Commit b0904169f1aa9ca10c9db10ef46d92eb66a08fc7
1 parent
216213cb
Exists in
master
and in
68 other branches
FIX: Multiple mask creation and interaction - had broken on last commit
Showing
1 changed file
with
3 additions
and
3 deletions
Show diff stats
invesalius/data/slice_.py
... | ... | @@ -59,7 +59,7 @@ class Slice(object): |
59 | 59 | def __add_mask(self, pubsub_evt): |
60 | 60 | mask_name = pubsub_evt.data |
61 | 61 | self.CreateMask(name=mask_name) |
62 | - self.ChangeCurrentMaskColour(self.current_mask.colour) | |
62 | + self.SetMaskColour(self.current_mask.index, self.current_mask.colour) | |
63 | 63 | |
64 | 64 | def __select_current_mask(self, pubsub_evt): |
65 | 65 | mask_index = pubsub_evt.data |
... | ... | @@ -175,7 +175,7 @@ class Slice(object): |
175 | 175 | "Show a mask given its index and 'show' value (0: hide, other: show)" |
176 | 176 | proj = Project() |
177 | 177 | proj.mask_dict[index].is_shown = value |
178 | - if (mask_index == self.current_mask.index): | |
178 | + if (index == self.current_mask.index): | |
179 | 179 | if value: |
180 | 180 | self.blend_filter.SetOpacity(1, self.current_mask.opacity) |
181 | 181 | else: |
... | ... | @@ -241,7 +241,7 @@ class Slice(object): |
241 | 241 | self.current_mask.threshold_range)) |
242 | 242 | ps.Publisher().sendMessage('Set threshold values in gradient', |
243 | 243 | self.current_mask.threshold_range) |
244 | - ps.Publisher().sendMessage('Select mask name in combo', mask_index) | |
244 | + ps.Publisher().sendMessage('Select mask name in combo', index) | |
245 | 245 | ps.Publisher().sendMessage('Update slice viewer') |
246 | 246 | #--------------------------------------------------------------------------- |
247 | 247 | ... | ... |