comparison src/com/five_ten_sg/connectbot/HostEditorActivity.java @ 131:adf9ca45675b

host editor database values override summary text only if non-empty
author Carl Byington <carl@five-ten-sg.com>
date Thu, 19 Jun 2014 09:57:31 -0700
parents 2a0b10fd128d
children 37665a94fc39
comparison
equal deleted inserted replaced
130:2a0b10fd128d 131:adf9ca45675b
355 // Fall through. 355 // Fall through.
356 } 356 }
357 } 357 }
358 else if (pref instanceof ListPreference) { 358 else if (pref instanceof ListPreference) {
359 ListPreference listPref = (ListPreference) pref; 359 ListPreference listPref = (ListPreference) pref;
360 int entryIndex = listPref.findIndexOfValue(value); 360 int entryIndex = listPref.findIndexOfValue(value.toString());
361 if (entryIndex >= 0) value = listPref.getEntries()[entryIndex]; 361 if (entryIndex >= 0) value = listPref.getEntries()[entryIndex];
362 } 362 }
363 363
364 if ((value == null) || (value.length() == 0)) value = summaries.get(key); 364 if ((value == null) || (value.length() == 0)) value = summaries.get(key);
365 pref.setSummary(value); 365 pref.setSummary(value);