ivoflipse / Pawlabeling

Tool for processing and analyzing pressure measurements
Other
18 stars 1 forks source link

Make sure all the cached values are cleared when switching between things #20

Closed ivoflipse closed 11 years ago

ivoflipse commented 11 years ago

image

Here's a nice example where I switch between 'dogs' in the Analysis window and suddenly I get two dog paws, which were left over from the previous dog.

ivoflipse commented 11 years ago

The problem was that while I was clearing the image, a later function would call change_frame and force it to draw cached values, which weren't cleared yet.

I've fixed the initial problems, but should guard change_frame from drawing if there's no real data.

ivoflipse commented 11 years ago

I've added a check to make sure I don't try to draw when there's no real data, but perhaps there's a 'better' solution. If someone comes up with it, let me know.