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

BTReal: Improve error handling for device opening #8671

Merged
merged 1 commit into from
Mar 18, 2020

Conversation

leoetlino
Copy link
Member

This commit attempts to improve error handling for device opening by
reducing panic alert spam when opening one or several devices fails.
Currently, Dolphin shows a panic alert for every device that we fail
to open, and another panic alert at the end if no usable device was
found. That is certainly a bit excessive -- we should only keep the
very last panic alert (the one that is shown if everything fails)
and we can just put the error for the last device open operation there.

This also changes the PanicAlert to a CriticalAlert to ensure the
message is visible even if the user has disabled regular panic alerts.

The message has also been reworded and should hopefully be clearer.

@leoetlino leoetlino force-pushed the bt-passthrough-error branch from c46e6e5 to d6a8802 Compare March 15, 2020 13:08
@leoetlino leoetlino force-pushed the bt-passthrough-error branch from d6a8802 to aca48d2 Compare March 15, 2020 19:58
Copy link
Contributor

@iwubcode iwubcode left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Untested but code wise this looks good and seems to be an improvement over what was there previously!

@leoetlino leoetlino force-pushed the bt-passthrough-error branch from aca48d2 to dd47e5a Compare March 15, 2020 20:20
This commit attempts to improve error handling for device opening by
reducing panic alert spam when opening one or several devices fails.
Currently, Dolphin shows a panic alert for every device that we fail
to open, and another panic alert at the end if no usable device was
found. That is certainly a bit excessive -- we should only keep the
very last panic alert (the one that is shown if everything fails)
and we can just put the error for the last device open operation there.

This also changes the PanicAlert to a CriticalAlert to ensure the
message is visible even if the user has disabled regular panic alerts.

The message has also been reworded and should hopefully be clearer.
@leoetlino leoetlino force-pushed the bt-passthrough-error branch from dd47e5a to 73e7f2a Compare March 15, 2020 21:10
@leoetlino leoetlino merged commit d1e8e3e into dolphin-emu:master Mar 18, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants