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

Task API #2463

Merged
merged 11 commits into from
Jun 16, 2024
Merged

Task API #2463

merged 11 commits into from
Jun 16, 2024

Conversation

hecrj
Copy link
Member

@hecrj hecrj commented Jun 14, 2024

This PR replaces Command with a new Task API that allows chaining thanks to Task::then and Task::chain.

Effectively, this allows combining Task results without an intermediate Message and update call. For instance, we can now toggle the maximize mode of a window without any Message nor tracked state:

window::fetch_maximized(window_id).then(move |maximized| window::maximize(window_id, !maximized))

@hecrj hecrj added feature New feature or request shell change labels Jun 14, 2024
@hecrj hecrj added this to the 0.13 milestone Jun 14, 2024
@hecrj hecrj enabled auto-merge June 16, 2024 18:16
@hecrj hecrj merged commit 95d4adb into master Jun 16, 2024
24 checks passed
@hecrj hecrj deleted the task-api branch June 16, 2024 18:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
change feature New feature or request shell
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant