What to do on TransactionTooLargeException

前端 未结 30 3373
盖世英雄少女心
盖世英雄少女心 2020-11-22 03:08

I got a TransactionTooLargeException. Not reproducible. In the docs it says

The Binder transaction failed because it was too large.

D

30条回答
  •  长发绾君心
    2020-11-22 03:48

    There isn't one specific cause of this problem.For me, in my Fragment class I was doing this:

    public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
        super.onCreateView(inflater, container, savedInstanceState);
        View rootView = inflater.inflate(R.layout.snacks_layout, container); //<-- notice the absence of the false argument
        return rootView;
    }
    

    instead of this:

    View rootView = inflater.inflate(R.layout.softs_layout, container, false);
    

提交回复
热议问题