Fix bug with default selection navigation settings

This commit is contained in:
vshcherb 2014-02-24 01:09:19 +01:00
parent 61dbb483ed
commit 66577cb82e
2 changed files with 4 additions and 1 deletions

View file

@ -311,6 +311,7 @@ public abstract class SettingsBaseActivity extends SherlockPreferenceActivity im
@Override
public void onClick(View v) {
if(selected.size() > 0) {
// test
setSelectedAppMode(selected.iterator().next());
}
if(profileDialog != null && profileDialog.isShowing()) {

View file

@ -373,7 +373,9 @@ public class NavigateAction {
if(!showDefault) {
values.remove(ApplicationMode.DEFAULT);
}
selected.add(settings.getApplicationMode());
if (showDefault || settings.getApplicationMode() != ApplicationMode.DEFAULT) {
selected.add(settings.getApplicationMode());
}
return prepareAppModeView(a, values, selected, parent, singleSelection, onClickListener);
}