对青客项目的完全重构,理清思路,总结经验。
- minSdkVersion 14,最低支持 Android 4.0。
- 添加 http://jakewharton.github.io/butterknife,简化代码。
- 添加 https://github.com/eluleci/FlatUI,确定应用颜色。
- 添加 appcompat-v7:22.1.1,兼容低版本。
- Toolbar 的背景色不受主题的影响,需要另外设置。
- 为 Toolbar 添加菜单:setSupportActionBar(toolbar)。
- 改变 Toolbar 菜单样式:app:popupTheme="@style/Theme.AppCompat.Light"。
- 为 Toolbar 添加阴影,使界面更有层次感。
- 添加 https://github.com/mcxiaoke/android-volley,记得添加访问网络的权限。
- 添加 https://github.com/navasmdc/MaterialDesignLibrary。
- 添加 https://github.com/afollestad/material-dialogs, 因为上一个库的 Dialog 不够棒。
- 用 AppCompatActivity 替换掉已过时的 ActionBarActivity。
- 添加 https://github.com/traex/RippleEffect。
- 添加 https://github.com/Lesilva/BetterSpinner。
- 添加 RecycleView,CardView 以及 https://github.com/castorflex/SmoothProgressBar。
- 添加 https://github.com/loopj/android-async-http,因为 volley 上传我还不会。
- 添加 https://github.com/journeyapps/zxing-android-embedded。
- 添加 https://github.com/linger1216/labelview。
- 添加 https://github.com/Clans/FloatingActionButton。
- 添加 https://github.com/neokree/MaterialTabs。