Blue line on top of transparent AlertDialog with 0,0,0,0 show parameters

28 views
Skip to first unread message

P5music

unread,
Mar 13, 2021, 5:41:10 AM3/13/21
to CodenameOne Discussions
My CodenameApp features a subclassed AlertDialog that has another transparent AlertDialog as background.

When such a Dialog is displayed I see a blu line on the top of the user interface, like it is a top border. (see attached image)
I think it is from the background AlertDialog, that is shown with this instruction:

 backgroundInteractionDialog.show(0,0,0,0);

It appears on the simulator with Android skin and on the Android device or the emulator.
According to the which controls are displayed, the line can also cut the controls on the top. (see attache image, you have to magnify it to see).

The line seems to be white on a iOS skin of the simulator, so it is hard to see, it depends on what it is above.

How can I get rid of it?
Thanks in advance

bluline_ontop_screenshot_android.jpg
CodenameOne Screenshot 1.png

Shai Almog

unread,
Mar 13, 2021, 10:08:15 PM3/13/21
to CodenameOne Discussions
It's probably related to the title UIID of the dialog. This is what the Component Inspector is for. Start changing styles in the hierarchy until you find the style that triggers that.

P5music

unread,
Mar 15, 2021, 5:58:26 PM3/15/21
to CodenameOne Discussions
I forgot mentioning that in fact the background alertdialog has a big (also transparent) button on all its surface to handle mouse events.
I checked the styles and only the DialogButton has the blue color in it, so it is possible that I have to change that.
If I understand I have to create a new style with a different color or without text and then assign to that button?
Thanks

Reply all
Reply to author
Forward
0 new messages