cymcsg / UltimateRecyclerView

A RecyclerView(advanced and flexible version of ListView in Android) with refreshing,loading more,animation and many other features.
Apache License 2.0
7.22k stars 1.43k forks source link

after setHeader(view) the header did not appear #231

Closed ForgetV closed 8 years ago

ForgetV commented 8 years ago

questionLv = (UltimateRecyclerView) viewRoot.findViewById(R.id.rv); questionLv.setOnLoadMoreListener(new UltimateRecyclerView.OnLoadMoreListener() { @Override public void loadMore(int itemsCount, int maxLastVisiblePosition) { } }); questionLv.setDefaultOnRefreshListener(new SwipeRefreshLayout.OnRefreshListener() { @Override public void onRefresh() { } }); questionLv.setLayoutManager(new LinearLayoutManager(mActivity)); questionLv.enableLoadmore(); LayoutInflater inflater = LayoutInflater.from(mActivity); View convertView = inflater.inflate(R.layout.header, null); questionLv.setNormalHeader(convertView);

GuyAvraham commented 8 years ago

+1 same problem. Im in a fragment: ultimateRecyclerView.setParallaxHeader(inflater.inflate(R.layout.parallax_recyclerview_header, ultimateRecyclerView.mRecyclerView, false));

but the header is not shown