@Override public void onViewCreated(View view, Bundle savedInstanceState) { super.onViewCreated(view, savedInstanceState); helper = new LoadingModelHelper(view, this); listView = (PullToRefreshListView) view.findViewById(R.id.loading_content); listView.setOnItemClickListener( new OnItemClickListener() { @Override public void onItemClick(AdapterView<?> parent, View view, int position, long id) { onListItemClick((ListView) parent, view, position, id); } }); listView.setOnRefreshListener(this); listView.getRefreshableView().setFastScrollEnabled(true); if (Build.VERSION.SDK_INT >= 11) { fastScrollBarAlwaysVisible(); } listView.getRefreshableView().setVerticalScrollBarEnabled(true); shouldConfigureListViewBeforeSetAdapter(listView); listView.setAdapter(createAdapter(items)); if (items.size() > 0) { helper.content(false); } else { helper.loading(); onRefresh(listView); } }
@Override public void onActivityCreated(Bundle savedInstanceState) { super.onActivityCreated(savedInstanceState); }
@Override public void onStop() { super.onStop(); }