This little piece of code aims to show you how to use 'ButterKnife' inside both base activity and it's fragments. The challenge was to use binding annotations of ButterKnife inside the base activity which has an empty layout at first sight. We inflated a template layout to the base activity inside the onCreate method . The second mission was to reuse @BindView annotation for inflated instance of a fragment inside the base activity. This solution provides less java codes inside activities. The activity now only takes care of filling the content with some fragment instances. No license needed. The code can be used and distributed freely.
-
Notifications
You must be signed in to change notification settings - Fork 0
This little piece of code aims to show you how to use 'ButterKnife' inside both base activity and it's fragments. The challenge was to use binding annotations of ButterKnife inside the base activity which has an empty layout at first sight. We inflated a template layout to the base activity inside the onCreate method . The second mission was to …
elessarsst/BaseActivityAndFragmentWithButterKnife
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
This little piece of code aims to show you how to use 'ButterKnife' inside both base activity and it's fragments. The challenge was to use binding annotations of ButterKnife inside the base activity which has an empty layout at first sight. We inflated a template layout to the base activity inside the onCreate method . The second mission was to …
Topics
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published