注入res文件夹的资源:

@StringRes

@EActivity
public class MyActivity extends Activity {
  @StringRes(R.string.hello)
  String myHelloString;
  @StringRes
  String hello;
}


@ColorRes

@EActivity
public class MyActivity extends Activity {
  @ColorRes(R.color.backgroundColor)
  int someColor;
  @ColorRes
  int backgroundColor;
}


@AnimationRes

@EActivity
public class MyActivity extends Activity {
  @AnimationRes
  Animation fadein;
}


More @xxxRes ,please search https://github.com/excilys/androidannotations/wiki/Resources#stringres




相关文章:

  • 2021-11-17
  • 2022-12-23
  • 2021-06-09
  • 2021-04-05
  • 2021-05-09
  • 2021-11-06
  • 2022-12-23
  • 2021-08-28
猜你喜欢
  • 2021-09-03
  • 2021-12-20
  • 2021-07-26
  • 2022-02-04
  • 2021-10-03
  • 2021-12-31
  • 2021-11-20
相关资源
相似解决方案