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

rewrite uiElementIsVisible #10534

Merged
merged 2 commits into from
May 19, 2023
Merged

Conversation

thot-experiment
Copy link
Contributor

rewrite visibility checking to be more generic/cleaner as well as add functionality to check if the element is scrolled on screen for more intuitive paste-target selection, fixes #10488

the improvement is that now we check the scroll location of viable elements when pasting an image and paste the image into the topmost element that's visible on screen, making pasted image inputs more intuitive

previously if using controlnets/segmentation etc in i2i, the pasted image would always land in the i2i input image window, now if you scroll down to controlnet such that the i2i window is no longer visible, the pasted image will end up in the controlnet input rather than the i2i input, this simplifies the use of addons that accept image input in conjunction with i2i or when using multiple addons that accept image input in t2i

i've done a bit of testing with different addons and have not found any regressions vs the previous 1.1 functionality, and this fixes an issue in 1.2 where in some circumstances pasted images would end up in a hidden pane as per #10488

Environment this was tested in

  • OS: Windows 10
  • Browser: firefox, chrome
  • Graphics card: NVIDIA GV100

Screenshots or videos of your changes

This is not strictly a UI change as the UI still appears the exact same? I'm not sure exactly what I should provide a screenshot/video of here.

rewrite visibility checking to be more generic/cleaner as well as add functionality to check if the element is scrolled on screen for more intuitive paste-target selection
@AUTOMATIC1111
Copy link
Owner

Will paste stop working when you have a valid visible image input but it's scrolled out of vision?

@Sakura-Luna Sakura-Luna linked an issue May 19, 2023 that may be closed by this pull request
1 task
split out the visibility method for pasting and use a sort inside the paste handler to prioritize on-screen fields rather than targeting ONLY on screen fields
@thot-experiment
Copy link
Contributor Author

Will paste stop working when you have a valid visible image input but it's scrolled out of vision?

Not anymore! :3 (as of 7b61acb)

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.

[Bug]: paste broken on t2i controlnet as of latest build
2 participants