mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-23 17:05:26 +02:00
Add Save Actions preference page to context menu preferences, related to bug 249359
This commit is contained in:
parent
ba1c469a99
commit
7784c9c727
1 changed files with 3 additions and 4 deletions
|
@ -133,7 +133,6 @@ import org.eclipse.ui.editors.text.EditorsUI;
|
|||
import org.eclipse.ui.editors.text.TextEditor;
|
||||
import org.eclipse.ui.ide.IGotoMarker;
|
||||
import org.eclipse.ui.navigator.ICommonMenuConstants;
|
||||
import org.eclipse.ui.navigator.resources.ProjectExplorer;
|
||||
import org.eclipse.ui.part.EditorActionBarContributor;
|
||||
import org.eclipse.ui.part.IShowInSource;
|
||||
import org.eclipse.ui.part.IShowInTargetList;
|
||||
|
@ -1473,9 +1472,8 @@ public class CEditor extends TextEditor implements ISelectionChangedListener, IC
|
|||
else if (required == IShowInTargetList.class) {
|
||||
return new IShowInTargetList() {
|
||||
public String[] getShowInTargetIds() {
|
||||
return new String[] { ProjectExplorer.VIEW_ID, IPageLayout.ID_OUTLINE, IPageLayout.ID_RES_NAV };
|
||||
return new String[] { IPageLayout.ID_PROJECT_EXPLORER, IPageLayout.ID_OUTLINE, IPageLayout.ID_RES_NAV };
|
||||
}
|
||||
|
||||
};
|
||||
}
|
||||
else if (required == IShowInSource.class) {
|
||||
|
@ -2846,7 +2844,7 @@ public class CEditor extends TextEditor implements ISelectionChangedListener, IC
|
|||
protected String[] collectContextMenuPreferencePages() {
|
||||
// Add C/C++ Editor relevant pages
|
||||
String[] parentPrefPageIds = super.collectContextMenuPreferencePages();
|
||||
String[] prefPageIds = new String[parentPrefPageIds.length + 11];
|
||||
String[] prefPageIds = new String[parentPrefPageIds.length + 12];
|
||||
int nIds = 0;
|
||||
prefPageIds[nIds++] = "org.eclipse.cdt.ui.preferences.CEditorPreferencePage"; //$NON-NLS-1$
|
||||
prefPageIds[nIds++] = "org.eclipse.cdt.ui.preferences.CodeAssistPreferencePage"; //$NON-NLS-1$
|
||||
|
@ -2859,6 +2857,7 @@ public class CEditor extends TextEditor implements ISelectionChangedListener, IC
|
|||
prefPageIds[nIds++] = "org.eclipse.cdt.ui.preferences.SmartTypingPreferencePage"; //$NON-NLS-1$
|
||||
prefPageIds[nIds++] = "org.eclipse.cdt.ui.preferences.CodeFormatterPreferencePage"; //$NON-NLS-1$
|
||||
prefPageIds[nIds++] = "org.eclipse.cdt.ui.preferences.CScalabilityPreferences"; //$NON-NLS-1$
|
||||
prefPageIds[nIds++] = "org.eclipse.cdt.ui.preferences.SaveActionsPreferencePage"; //$NON-NLS-1$
|
||||
System.arraycopy(parentPrefPageIds, 0, prefPageIds, nIds, parentPrefPageIds.length);
|
||||
return prefPageIds;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue