ButterKnife沒有Generate ButterKnife Injections問題


Butterknife 一鍵自動生成findviewbyid和onclick的代碼。

步驟如下:

一:

二:

三:

完成!

如果沒有Generate ButterKnife Injections選擇項,需要如下配置

File -> settings -> Plugins  -> Browse repositories -> ButterKnife 安裝 提示重啟 重啟之后 -> compile 'com.jakewharton:butterknife:7.0.1' -> ButterKnife.bind(this) -> 右鍵R.layout.xxxxxx -> 就能看見Generate ButterKnife Injections選項,上圖

搞定!

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM