Ejemplo n.º 1
0
 public synchronized void execute(final Runnable r) {
   mTasks.offer(
       new Runnable() {
         public void run() {
           try {
             r.run();
           } finally {
             scheduleNext();
           }
         }
       });
   if (mActive == null) {
     scheduleNext();
   }
 }