java - Showing toast before an intesive work of processor -
i need show toast message before method using intense processor work. problem toast shows after method, calling method in thread.
how can show toast before ?
edit: code long showing here ... resume ...
...
toast.maketext(getbasecontext(),"text", toast.length_short).show(); proccess.setrun(); //in proccess class implements runnable ...
public void setrun(){     thread= new thread(this);     thread.setpriority(thread.norm_priority);     thread.start();     running=true; } public void run() {         bytes=bytegroovemaker();         prepare(grbytes); } //bytegroovemaker() method in proccess class requires lot of processor work.
just use async task. on onpreexecute show toast, , in doinbackground method execute heavy process :)
Comments
Post a Comment