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

Consider removing channels from glib #1213

Closed
Hofer-Julian opened this issue Oct 27, 2023 · 5 comments · Fixed by #1216
Closed

Consider removing channels from glib #1213

Hofer-Julian opened this issue Oct 27, 2023 · 5 comments · Fixed by #1216

Comments

@Hofer-Julian
Copy link
Contributor

As mentioned by @sdroege in gtk-rs/gtk4-rs#1521 (comment):

Should we maybe remove the GLib channel? It mostly exists from the times before async was mature and because people instead used timeout callbacks to periodically check if a non-async channel contains something.

sdroege added a commit to sdroege/gtk-rs-core that referenced this issue Oct 30, 2023
Async code generally allows for more flexible message handling than the
callback based MainContext channel.

Fixes gtk-rs#1213
sdroege added a commit to sdroege/gtk-rs-core that referenced this issue Oct 30, 2023
Async code generally allows for more flexible message handling than the
callback based MainContext channel.

Fixes gtk-rs#1213
@sdroege
Copy link
Member

sdroege commented Oct 30, 2023

See #1216

bilelmoussaoui pushed a commit that referenced this issue Oct 30, 2023
Async code generally allows for more flexible message handling than the
callback based MainContext channel.

Fixes #1213
@p-kraszewski
Copy link

Splendid move! Could you consider using Rust's deprecated attribute next time, let's say, for 2 releases?

@bilelmoussaoui
Copy link
Member

It was deprecated during the release cycle of 0.18.x.

@p-kraszewski
Copy link

Ok. My bad.

  • First note on deprecation (merged into 0.18.4): 2023.11.25 93f6a02
  • Feature reaped (merged into 0.19 line): 2023.11.31 2cb10ec

@sdroege
Copy link
Member

sdroege commented Feb 8, 2024

First release without the API was on Sunday, so that gives a bit more than 2 months.

robmoss added a commit to robmoss/rusty_train that referenced this issue Feb 19, 2024
Channels were removed from glib 0.19, and so we use the async-channel
crate instead (see gtk-rs/gtk-rs-core#1213).

It took some experimentation on my part to implement this transition;
see https://gtk-rs.org/gtk4-rs/stable/latest/book/main_event_loop.html
for examples that helped steer me in the right direction.
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

Successfully merging a pull request may close this issue.

4 participants