-
-
Notifications
You must be signed in to change notification settings - Fork 52
MainWindow: replace ListBox with ListView #796
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
Conversation
b964052 to
866f2e7
Compare
|
Sorry there is one more thing that I hadn't noticed before, but this leaks memory. |
|
@Oowoosh0 good catch! I'm still learning ListView but that makes a lot of sense. I think it's working as expected now. If not, let me know how you're testing and I'll keep poking at it :) |
Don't subclass Gtk.ListBoxRow unbind properly
ec2bb03 to
6c57279
Compare
|
For testing I used the very professional method of opening a system monitor, opening over 700 music files in the app and then crazily scrolling up and down. Which makes the memory usage slowly creep up over time. It does not do so in the version still using ListBox. Although TrackRows seems to be destroyed correctly actually. |
|
I think it is the Bindings. New Bindings are being created whenever a different AudioObject is set in a TrackRow but they never get destroyed. I thought unbind() would take care of that but for some reason it does not seem to do so :/ |
|
@danirabbit connecting and disconnecting to the notify signal manually and not using bind_property actually gets rid of the leak. Calling unbind() for some reason does not free the memory used by a Binding and bind_property creates new Bindings every time a new AudioObject is set to a TrackRow. If you haven't done any more work on this branch then I can push that change. |
|
@Oowoosh0 sure go ahead :) Thanks! |
Can be rebase merged