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

extension: Log used renderer; Warn if not preferred. #10903

Conversation

iwannabethedev
Copy link
Contributor

Log which renderer-backend was actually used in the browser console.

Add an option for toggling whether to warn or not
if the actually used renderer is not the same as
the preferred renderer, warning both in the console and also with a window.alert() popup. This option is meant first and foremost for Ruffle-developers.

@n0samu @relrelb

Log which renderer-backend was actually used in the
browser console.

Add an option for toggling whether to warn or not
if the actually used renderer is not the same as
the preferred renderer, warning both in the console
and also with a `window.alert()` popup. This option
is meant first and foremost for Ruffle-developers.
@iwannabethedev
Copy link
Contributor Author

This is related to #10835 , #10831 , #10900 .

This PR will probably be fully or mostly superseded by #10900 , though that PR might take changes from this PR. #10831 should probably be closed at this point, though I will wait until merges have been done.

@iwannabethedev
Copy link
Contributor Author

iwannabethedev commented May 1, 2023

warning log
warning popup

@iwannabethedev
Copy link
Contributor Author

The popup dialog is rather ugly, but it is not really meant to be used by non-Ruffle-developers.

As has been discussed elsewhere, one advantage of this approach is that there is no panic if the preferred renderer is not actually used, while at the same time making it very easy for Ruffle-developers to determine if the preferred renderer was not used.

@iwannabethedev iwannabethedev marked this pull request as ready for review May 1, 2023 15:05
@relrelb
Copy link
Contributor

relrelb commented May 2, 2023

Honestly I'm quite disgusted by using window.alert(). Since it's meant to be used by Ruffle developers only, I don't see it much better than panicking. My preference here is simplicity over user experience, since there aren't really any "users".

@iwannabethedev
Copy link
Contributor Author

iwannabethedev commented May 2, 2023

Honestly I'm quite disgusted by using window.alert(). Since it's meant to be used by Ruffle developers only, I don't see it much better than panicking. My preference here is simplicity over user experience, since there aren't really any "users".

Good point, though if a user accidentally or foolishly select that option, is it not better to show window.alert than panicking? Like, if a user opens a pull request with a bot commit in order to report an issue ... 😃 .

@n0samu
Copy link
Member

n0samu commented May 2, 2023

I think we arrived at an optimal solution with #10909, so let's forget about the other stuff (panicking, window.alert, etc)

@iwannabethedev iwannabethedev deleted the extension_log_chosen_renderer_backend branch May 6, 2023 12:32
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 this pull request may close these issues.

3 participants