Screen blinking on two cases

41 views
Skip to first unread message

Mario Barón

unread,
Oct 29, 2014, 9:55:33 AM10/29/14
to codenameone...@googlegroups.com
Hey guys,


I have a problem with my app in which the screen starts to blink horribly. This occurs in the following two cases:

1) a Dialog is shown while a WS is being called. I do this byt showing a modeless dialog before calling the WS and after calling it doing a dispose on the previously mentioned dialog.  I attach the following video so you can see the problem clearly: Click here

2) The app transfers from one form to another by using showForm("name", null), on the new form that is being shown, what you can see is parts of the previous form appearing on the new one and it looks as if the screen was blinking. You can see this case in the following video: Click here

The first case happened on a Huawei Ascend Y530 running Android 4.3 and the second one happened on a Sony Xperia M also running Android 4.3 but these cases haven't happened on my Galaxy Tab 2


What could be the cause of this? I really appreciate your help.

Shai Almog

unread,
Oct 29, 2014, 9:26:57 PM10/29/14
to codenameone...@googlegroups.com
Hi,
did you use any build arguments in this application?
Are you sure there are no EDT violations in that area of the code?

Mario Barón

unread,
Oct 30, 2014, 7:03:29 PM10/30/14
to codenameone...@googlegroups.com
Hey Shai,

thanks for your response. I turned the on the EDT Debug Monitor set to full and ddn't see any violations occuring, I do however have the android.asyncPaint build hint set to false, I don't seem to remember why at the moment I think it was related to something similar but it had to do with the native map component. By turning it on at the moment seemed to give me better performance. The rest of the build hints are for other simple permissions like network state and such.

What do you think may be hapening here? or what do you suggest may help fix the problem?


Thanks for your help.

Shai Almog

unread,
Oct 30, 2014, 9:23:50 PM10/30/14
to codenameone...@googlegroups.com
Hi,
it looks like you are revalidating/repainting the UI over and over again.
On the simulator this might not show since its so fast but on the device this obviously would have that effect.
How do you show the progress dialog and what sort of code do you have there?
Reply all
Reply to author
Forward
0 new messages