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

Add ListBox::bind_model() and other functions taking closures #672

Merged
merged 1 commit into from Jul 2, 2018

Conversation

Projects
None yet
3 participants
@sdroege
Copy link
Member

sdroege commented Jul 2, 2018

This is currently WIP, I'd like to add the other commented out functions too but it's becoming repetitous. Should probably do gtk-rs/gir#618 first.

Any comments so far?

@GuillaumeGomez

This comment has been minimized.

Copy link
Member

GuillaumeGomez commented Jul 2, 2018

Nope, seems good to me. Or at least didn't see any outstanding issue.

@EPashkin

This comment has been minimized.

Copy link
Member

EPashkin commented Jul 2, 2018

Looks good, I little worried about the lack of boxing, but I trust you

@sdroege

This comment has been minimized.

Copy link
Member Author

sdroege commented Jul 2, 2018

Looks good, I little worried about the lack of boxing, but I trust you

It's the same as boxing twice, just that we store it on the stack instead. The first reference taken creates a trait object (two pointers, the struct pointer and the vtable), the second reference is a single pointer to that trait object (and if it was more than a single pointer, the cast to gpointer would fail to compile).

@sdroege

This comment has been minimized.

Copy link
Member Author

sdroege commented Jul 2, 2018

Should we get this in for now until the gir changes are done (probably going to take a few weeks :) )?

@GuillaumeGomez

This comment has been minimized.

Copy link
Member

GuillaumeGomez commented Jul 2, 2018

Sounds fine to me. Thanks! :)

@GuillaumeGomez GuillaumeGomez merged commit 88de030 into gtk-rs:master Jul 2, 2018

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

vhdirk pushed a commit to vhdirk/gtk-rs that referenced this pull request Jan 16, 2019

Merge pull request gtk-rs#672 from sdroege/listbox
Add ListBox::bind_model() and other functions taking closures
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.