获取控件
@InjectView(R.id.image_show_password)ImageView image_show_password;
控件事件
@OnClick(R.id.btn_submit) void btn_submit(){
intent=new Intent(context, MobileValidation.class);
startActivity(intent);
}
配置项目
选择项目属性
选择 Java Compiler->选择 anotaion processin 把Enable project specific settings 和Enableprocessing in editor打上对勾
在选择左侧菜单中的Factory Path AddJARs 选择当前项目中Butter Knife JAR文件
http://jakewharton.github.io/butterknife/ide-eclipse.html
如果在Java Compiler里面找不到 anotaion processin 说明没有安装插件
地址:http://download.eclipse.org/releases/juno
选择