white knight

导航

 

参考 https://blog.csdn.net/djx123456/article/details/6325983

 

public class MainActivity extends AppComatActiviey {

  private final Handler handler = new Handler();

 

  protected void onCreate(Bundle bundle) {

    ...

    otherMethod();

    ...

  }

 

       private void otherMethod() {

    xxx(new Callback() {

      ...

      public void onResponse(...) {

        handler.post(new Runnable() {

          public void run() {

            ...

          }

        });

      }

      ...

    });

  }

}

posted on 2018-10-11 13:57  white knight  阅读(91)  评论(0编辑  收藏  举报