Search in sources :

Example 1 with HomePresenter

use of com.seven.seven.home.presenter.HomePresenter in project seven_develop by seven123456.

the class HomeFragment method initView.

@Override
protected void initView() {
    homePresenter = new HomePresenter(this, (MainActivity) getActivity());
    EventBus.getDefault().register(this);
    linearLayoutManager = new LinearLayoutManager(getContext());
    // appBarLayout = rootView.findViewById(R.id.appbar);
    // RelativeLayout.LayoutParams layoutParams = (RelativeLayout.LayoutParams) appBarLayout.getLayoutParams();
    // layoutParams.height = layoutParams.height + StatusBarUtil.getStatusBarHeight(getActivity());
    // appBarLayout.setTitle("首页新闻");
    homeTitleBar = rootView.findViewById(R.id.in_home_title);
    swipeRefreshLayout = rootView.findViewById(R.id.swf_layout);
    recyclerView = rootView.findViewById(R.id.recycler);
    errorLayoutView = rootView.findViewById(R.id.error);
    errorLayoutView.setVisibility(View.VISIBLE);
    errorLayoutView.playAnimation();
    initRecyclerView();
}
Also used : HomePresenter(com.seven.seven.home.presenter.HomePresenter) MainActivity(com.seven.seven.ui.MainActivity) LinearLayoutManager(android.support.v7.widget.LinearLayoutManager)

Aggregations

LinearLayoutManager (android.support.v7.widget.LinearLayoutManager)1 HomePresenter (com.seven.seven.home.presenter.HomePresenter)1 MainActivity (com.seven.seven.ui.MainActivity)1