android - Runnable not run -


i using handler , runnable display time of media player. runnable don't run. code is:

handler timerhandler;  public contstructor() {         timerhandler = new handler();     } 

i'm using:

runnable sourcetimer = new runnable() {         @override         public void run() {              long totalduration = source.getduration();             long currentduration = source.getcurrentposition();              string remaindurationlabel = millisecondstotimer(totalduration - currentduration);             log.e(tag, "source remain time " + remaindurationlabel);              timerhandler.postdelayed(this, 100);         }     }; 

start timer:

void sourceplay() {         source.start();         timerhandler.postdelayed(sourcetimer, 0);     } 

i don't receive error not logging "source remain time " in logcat.

what's problem?


Comments

Popular posts from this blog

php - How to display all orders for a single product showing the most recent first? Woocommerce -

asp.net - How to correctly use QUERY_STRING in ISAPI rewrite? -

angularjs - How restrict admin panel using in backend laravel and admin panel on angular? -