I have the following piece of code in my android application. Whenever these lines of code run in my application, the mobile screen goes blank for 10 seconds. This 'problem' is most probably caused by 'System.currentTimeMillis()'
for (i=0;i<10;i++)
{
time0 = System.currentTimeMillis();
do
{
time1 = System.currentTimeMillis();
}
while ((time1 - time0) < 1000);
}
Is there any way that the blank screen can be avoided?
Thanks