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
book: Migrate to glib-build-tools
#1024
Conversation
I'm not sure what's causing the CI failures |
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks!
But I guess this crate will be added to crates.io?
I'd rather wait for that.
That's fine with me |
Then let's wait for its release, update Cargo.toml and merge then :) |
d3b4130
to
749a282
Compare
Alright, should be rebased on master now, and I fixed a broken link that snuck in. CI failed on my first push but that didn't seem to be related to my changes? |
Thanks, could you please also update the relevant section in the book where we add the gtk build dependency? |
749a282
to
d8e3f2a
Compare
That's done now |
Thanks, I will later fix the build failures on your branch and merge it. |
obj.setup_settings(); | ||
obj.setup_actions(); | ||
obj.bind_settings(); | ||
self.instance().setup_settings(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would suggest calling self.instance() only once and store it in an obj / window variable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why though? Is there a performance penalty?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think there should be any, cc @sdroege for confirming that. But it doesn't make much sense to repeat the same call if you can store the obj once and re-use it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure
let incremented_number = self.number.get() + 1; | ||
// If `number` reached `MAX_NUMBER`, | ||
// emit "max-number-reached" signal and set `number` back to 0 | ||
if incremented_number == MAX_NUMBER { | ||
button.emit_by_name::<()>("max-number-reached", &[&incremented_number]); | ||
button.set_property("number", &0); | ||
self.instance() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same as elsewhere
3d13c75
to
7dbe7a8
Compare
No description provided.