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

Adding getter for RawImage and disabling user controls. #95

Merged
merged 5 commits into from
Jul 21, 2022

Conversation

Konijima
Copy link
Contributor

So here some small edits used for my project, I though I'd share it as this could be useful for someone else too.

I needed to:

  1. be able to disable the user controls (mouse, keyboard or both) on the web browser instance.
  2. access the web browser RawImage to handle the color and more.

Let me know if you see possible improvements to this.

Copy link
Member

@Voltstro Voltstro left a comment

Choose a reason for hiding this comment

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

Yup, I think having the ablity to disable inputs make sense, as well as exposing the handler to the image.

Happy to merge once the changes requested are done.

@Voltstro Voltstro added the enhancement New feature or request label Jul 20, 2022
@Konijima
Copy link
Contributor Author

Perfect thanks for the reply, I'll clean that up.

@Konijima
Copy link
Contributor Author

@Voltstro should be good to review.

Copy link
Member

@Voltstro Voltstro left a comment

Choose a reason for hiding this comment

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

Just one little thing, and thats it.

float scroll = inputHandler.GetScroll();
scroll *= browserClient.BrowserTexture.height;

if (!disableMouseInputs && scroll != 0)
Copy link
Member

Choose a reason for hiding this comment

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

Don't need this extra !disableMouseInputs check.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done!

Copy link
Member

@Voltstro Voltstro left a comment

Choose a reason for hiding this comment

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

Awesome, thanks!

@Voltstro Voltstro merged commit 9babdf4 into Voltstro-Studios:master Jul 21, 2022
@Konijima Konijima deleted the konijima-edits branch July 21, 2022 14:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants