Code example for ListView

Methods: setAdapter, setOnItemClickListener

0
     
    private void initAssignListenersAndAdapter() { 
    	mEtFilter.setText(mFilterText);
	    mEtFilter.setOnEditorActionListener(mSearchActionListener);
	    mEtFilter.setOnKeyListener(mSearchBoxKeyListener);
	    mListView.setAdapter(mListAdapter);
	    mListView.setOnItemClickListener(mListItemClickAdapter);
	    mBtnSearch.setOnClickListener(mSearchBtnListenerListner);
	    mBtnClear.setOnClickListener(mClearBtnListenerListner);
    } 
 
     
    private Runnable mLoadAppLoadAndSortAppList = new Runnable() {
 
		@Override 
		public void run() { 
	        mAppList = new ArrayList<AppInfoCache>(); 
	        AppInfoCache tmpCache; 
	        List<ApplicationInfo> installedApps = pm.getInstalledApplications(0); 
	        for (ApplicationInfo appInfo : installedApps) { 
       			tmpCache = new AppInfoCache(appInfo.loadLabel(pm).toString(), appInfo.packageName, appInfo.className);