Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Glamour Morphic does not release the lock on objects #314

Closed
seandenigris opened this issue Aug 3, 2015 · 6 comments
Closed

Glamour Morphic does not release the lock on objects #314

seandenigris opened this issue Aug 3, 2015 · 6 comments

Comments

@seandenigris
Copy link
Contributor

Originally reported on Google Code with ID 314

It looks like the image is just increasing in size. I do not know why though. I suspect
it has to do 
with Announcements.

Reported by tudor.girba on 2010-01-28 23:19:33

@seandenigris
Copy link
Contributor Author

Yeah possible, from with my little experience with announcements on windows, if you
forget to unsubscribe, you 
quickly run into problems because windows keep announcing to dead objects.

Reported by simon.denier on 2010-01-29 09:29:07

@seandenigris
Copy link
Contributor Author

The problem looks like this.

Because MoosePanel registers for the announcements from MooseModel root, even if you
close it, this 
instance of MoosePanel will still be referenced by the MooseModel root announcer. So,
it does not get 
garbage collected. And if you opened already a model with this MoosePanel, this model
will still be referenced 
by the Panel, and so it won't get collected.

The validation of this hypothesis is that executing the following code brings everything
back to normal:
GLMListPresentation allInstances do: [:each | MooseModel root announcer unsubscribe:
each ] 

Reported by tudor.girba on 2010-01-30 20:35:09

@seandenigris
Copy link
Contributor Author

A solution is to create a GLMPresentation>>unregisterAnnouncements and then call this
method every time the 
morph tries to go away or every time the presentation is replaced in a pane.

Reported by tudor.girba on 2010-01-30 20:36:16

  • Status changed: Accepted

@seandenigris
Copy link
Contributor Author

Reported by tudor.girba on 2010-01-30 20:36:27

  • Labels added: Milestone-4.0

@seandenigris
Copy link
Contributor Author

A fix is now provided in the latest Glamour (Core and Morphic). The idea is that now
GLMPresentation 
remembers the objects to which it registers for announcements. Afterwards, can unregisterAnnouncements.
This 
method is now called when the GLMSystemWindow is deleted.

At least in the case of the MoosePanel, this work.

Reported by tudor.girba on 2010-01-30 23:14:23

  • Status changed: Started

@seandenigris
Copy link
Contributor Author

Reported by tudor.girba on 2010-02-01 23:32:12

  • Status changed: Fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant