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

The parameter 'bias' for the InteractionDialog.showPopupDialog does not work #3825

Open
ThomasH99 opened this issue Aug 6, 2024 · 0 comments
Assignees

Comments

@ThomasH99
Copy link
Contributor

Describe the bug
The JavaDoc of the ‘bias’ parameter in InteractionDialog.showPopupDialog(Rectangle rect, boolean bias) is not very clear, but if I understand it correctly it doesn’t actually to determine if the ID is shown above or below the component it points to. Shai confirmed this is a bug.

I would also recommend to rename 'bias' to something clear (I guess the unclear name may be a reason for the originally intended behavior getting lost along the way). E.g. prioritizeTopOrRightPosition (assuming this was the original intended meaning).

An alternative could be to change bias to ‘prioritizedPosition’ taking as value Component.TOP/BOTTOM/LEFT/RIGHT and placing the ID there when there’s space enough.

To Reproduce
Create a centered component like a label and show it centered vertically in portrait mode. Then create an InteractionDialog and call showPopupDialog with the component and bias as true or false. The ID is shown in the same place no matter the value of bias.

Expected behavior
See the description.

@shai-almog shai-almog self-assigned this Aug 8, 2024
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

No branches or pull requests

2 participants