Code example for PreferenceGroup

Methods: findPreference, removePreference

0
	private void deleteWord(final String word) {
		if (null != word && word.length() > 0) {  
			mListDeleteDictWord.add(word);
			mListDictWord.remove(word);
			mListAddDictWord.remove(word);
			Preference pf = mPrefDictionary.findPreference(word);
			if (null != pf) {
				mPrefDictionary.removePreference(pf);
				mListPref.remove(mSelectString);
			} 
		} 
	} 
 
	OnPreferenceClickListener mListener = new OnPreferenceClickListener() {
		public boolean onPreferenceClick(Preference preference) {  
			mSelectString = preference.getKey(); 
			showDialog(DIALOG_EDIT_OR_DEL); 
			return true; 
		} 
	};