multithreading - Android Thread makes the UI blank screen -
i have written thread in application. when thread starts running, ui screen becomes blank. how can avoid this?
public class settickertext extends thread { @override public void run() { while(true) { systemclock.sleep(25000); log.i("map", "after wait"); } }
it's going (don't have compiler near me):
new settickertext().start() essentially, when tell thread object start, spins new thread, invokes run you. you're doing calling run ui thread, other function, it's blocking ui thread returning
Comments
Post a Comment