-
Notifications
You must be signed in to change notification settings - Fork 312
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 progress indicator on dock icon #85
Conversation
@@ -17,7 +17,7 @@ struct InstallationStepView: View { | |||
controlSize: .small, | |||
style: .spinning | |||
) | |||
.help("Dowloading: \(Int((progress.fractionCompleted * 100)))% complete") | |||
.help("Downloading: \(Int((progress.fractionCompleted * 100)))% complete") |
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.
🙇
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.
This worked for me. Tried cancelling and restarting while it was downloading. All reset itself.
I'll leave Brandon for final but looks good
Nice! Thanks Sam. One thing I'm not sure about is if and how this should represent indeterminate InstallationSteps (all of the ones other than downloading, for example unarchiving can take longer than downloading to complete but we don't currently show determinate progress for it) and multiple simultaneous installations. Perhaps we could represent both of these with a "richer" use of Progress, like an instance per installation step, with a parent Progress for the entire installation, and a parent Progress of that to track aggregate installation progress. There might be other options too. What are your thoughts on this? |
My 2 cents: Create another enhancement ticket and get this out (MVP). Feel like there's better UX we could do for that unxip step that we should think about better. |
I think it would be good to investigate getting the dock progress to also represent those other steps, but I agree with Matt as implementing that seems to be a hurdle. The UX would indeed be improved because at the moment, when the progress indicator completes, a user would go back to the app and feel slight disappointment as those remaining steps can take a while to complete. However, in its present form, it still makes the experience better than it was without it because the only way to tell how progress was going is to keep the app in front. If you're alright with that course of action, I'll create a follow up enhancement to this so that the dock progress can report from the start of the Xcode download to when it's fully ready to use. |
Thanks guys. Agreed that the tree-of-Progress approach would be a fair bit more work, and might not be needed for a minimal version of this feature, so I'll take a step back from that particular approach. I'll also note that the issue I created was worded "aggregate download progress" but probably should have been "aggregate installation progress," so I apologize for that. What's proposed here is to have the dock show "nothing" or "some progress", which I think most people will interpret as "installing something" or "not installing anything." This will be misleading though, because the dock icon showing nothing is actually representing either "not installing anything" or "installing something, but not the downloading part." Users will still need to rely on keeping the app in front to know when installation is complete. I think a minimum version of this feature could be something like "represent a Bool in the dock icon", where the Bool is "one or more versions have an installation state of
Agreed, and I think that (specifically, getting percent complete via private API) could be a valuable change, but I think representing that this step is happening is valuable even without knowing the percent complete because it takes so long. |
I'd prefer to draw an overlay on the icon tile (like how DockProgress is implemented) only because it frees up the badge for other things that are more appropriate, like count of completed installations. I'd like to explore the other options, and if animated badge content is the easiest thing to do for now then that's okay. How are you driving the character animations, and could that be used to draw those in an overlay on the dock tile instead of in the badge? |
that is just ascii animations, so just a Timer + looping through an array of text |
Closing in favour of #423 |
Closes #17
Uses suggested DockProgress to display a progress bar overlay on top of the dock icon as an Xcode is downloading.