Community
Participate
Working Groups
Build Identifier: I20100312-1448 Attempting to open a preference dialog with a dsiplayed id filter fails when there is only one preference page in the application Reproducible: Always Steps to Reproduce: I have tried creating a preference dialog using both of these patterns: PreferencesUtil.createPreferenceDialogOn(getSite().getShell(), "PreferencePage", new String[] {"PreferencePage"}); and PreferencesUtil.createPreferenceDialogOn(getSite().getShell(), "PreferencePage", new String[] {}); It only works if i pass in null to the displayedIds field (which i don't want) I think there needs to be a "if (hasAtMostOnePage()) {" guard in showOnly see the below stacktrace for details: java.lang.NullPointerException at org.eclipse.ui.internal.dialogs.FilteredPreferenceDialog.showOnly(FilteredPreferenceDialog.java:356) at org.eclipse.ui.dialogs.PreferencesUtil.applyOptions(PreferencesUtil.java:75) at org.eclipse.ui.dialogs.PreferencesUtil.createPreferenceDialogOn(PreferencesUtil.java:194) at org.eclipse.ui.dialogs.PreferencesUtil.createPreferenceDialogOn(PreferencesUtil.java:116)
*** This bug has been marked as a duplicate of bug 298451 ***