AndroidStudio Template之launch

2018-08-28  本文已影响30人  NoValue

快速写入一个Activity的launch代码

  public static void launch(Context context){
        Intent intent = new Intent(context, $class$.class);
        ActivityUtil.switchTo(context, intent);
  }

达到的效果如下:

图片.png
图片.png

需要新建一个Live Template

图片.png

template 代码

  public static void launch(Context context){
        Intent intent = new Intent(context, $class$.class);
        ActivityUtil.switchTo(context, intent);
  }
上一篇 下一篇

猜你喜欢

热点阅读