Fragment Issue with Data Binding
See original GitHub issueI saw #29 Fragment Issue for loading fonts. May Its working fine with LayoutInflater
like
LayoutInflater mInflater = getActivity().getLayoutInflater();
But I have used Data Binding Library with Fragment so I am inflating view like:
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
orderListBinding = DataBindingUtil.inflate(inflater, R.layout.fragment_order_list, container, false);
// Inflate the layout for this fragment
return orderListBinding.getRoot();
}
How can I solve it for Data Binding? Any Help please.
Issue Analytics
- State:
- Created 7 years ago
- Reactions:1
- Comments:18 (6 by maintainers)
Top Results From Across the Web
How to use data-binding with Fragment - Stack Overflow
The data binding implementation must be in the onCreateView method of the fragment, delete any data Binding that exist in your OnCreate method, ......
Read more >View Binding - Android Developers
Data binding library ... Overview · Create a fragment · Fragment manager · Fragment transactions ... Support. Known issues · StackOverflow.
Read more >View Binding with Fragments in Android Jetpack
View Binding with Fragments in Android Jetpack · Step 1: Create a new empty activity project · Step 2: Enable the ViewBinding feature...
Read more >The ViewDataBinding.OnStartListener lifecycle observer leaks ...
We might actually have 2 issues here. Data Binding assumes it owns the view and the given lifecycle, which is not a correct...
Read more >Simple one-liner ViewBinding in Fragments and Activities with ...
There's a new feature in Android Studio 3.6 called “view binding”. It's just like databinding, except all it does is take your existing...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi, i am using databinding too. I dont get this issue. Did you init the lib the right way in the parent activity?
This is only applied to the Activity. Fragments extend from the Activity. No need to do anything else.
On Sat, 8 Apr 2017 at 19:21 Deshar Sunil notifications@github.com wrote: