public static void setCursor(Fragment fragment, Cursor cursor) { ListView listView = (ListView) FragmentUtils.findViewById(fragment, R.id.l_list_album); CursorAdapter adapter = (CursorAdapter) listView.getAdapter(); adapter.swapCursor(cursor); }
public static void setCheckedState(Fragment fragment, int position) { ListView listView = (ListView) FragmentUtils.findViewById(fragment, R.id.l_list_album); listView.setItemChecked(position, true); }
public static void setUpListView( Fragment fragment, AdapterView.OnItemClickListener listener, AlbumViewResources resources) { ListView listView = (ListView) FragmentUtils.findViewById(fragment, R.id.l_list_album); listView.setOnItemClickListener(listener); listView.setAdapter(new DevicePhotoAlbumAdapter(fragment.getActivity(), null, resources)); }