mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-23 22:52:11 +02:00
Bug 258407 - [scalability] Disable the reconciler in scalability mode by default
This commit is contained in:
parent
80272df9d7
commit
efdb235322
4 changed files with 20 additions and 7 deletions
|
@ -15,11 +15,14 @@ package org.eclipse.cdt.internal.ui.editor;
|
||||||
|
|
||||||
import org.eclipse.swt.SWT;
|
import org.eclipse.swt.SWT;
|
||||||
import org.eclipse.swt.custom.StackLayout;
|
import org.eclipse.swt.custom.StackLayout;
|
||||||
|
import org.eclipse.swt.events.SelectionAdapter;
|
||||||
|
import org.eclipse.swt.events.SelectionEvent;
|
||||||
import org.eclipse.swt.layout.FillLayout;
|
import org.eclipse.swt.layout.FillLayout;
|
||||||
import org.eclipse.swt.widgets.Composite;
|
import org.eclipse.swt.widgets.Composite;
|
||||||
import org.eclipse.swt.widgets.Control;
|
import org.eclipse.swt.widgets.Control;
|
||||||
import org.eclipse.swt.widgets.Label;
|
import org.eclipse.swt.widgets.Link;
|
||||||
import org.eclipse.ui.actions.ActionGroup;
|
import org.eclipse.ui.actions.ActionGroup;
|
||||||
|
import org.eclipse.ui.dialogs.PreferencesUtil;
|
||||||
|
|
||||||
import org.eclipse.cdt.core.model.ITranslationUnit;
|
import org.eclipse.cdt.core.model.ITranslationUnit;
|
||||||
import org.eclipse.cdt.ui.PreferenceConstants;
|
import org.eclipse.cdt.ui.PreferenceConstants;
|
||||||
|
@ -72,9 +75,16 @@ public class CContentOutlinePage extends AbstractCModelOutlinePage {
|
||||||
}
|
}
|
||||||
|
|
||||||
private Control createStatusPage(Composite parent) {
|
private Control createStatusPage(Composite parent) {
|
||||||
Label label = new Label(parent, SWT.NONE);
|
final Link link= new Link(parent, SWT.NONE);
|
||||||
label.setText(CEditorMessages.Scalability_outlineDisabled);
|
link.setText(CEditorMessages.Scalability_outlineDisabled);
|
||||||
return label;
|
link.setToolTipText(CEditorMessages.Scalability_linkToolTip);
|
||||||
|
link.addSelectionListener(new SelectionAdapter() {
|
||||||
|
@Override
|
||||||
|
public void widgetSelected(SelectionEvent e) {
|
||||||
|
PreferencesUtil.createPreferenceDialogOn(link.getShell(), "org.eclipse.cdt.ui.preferences.CScalabilityPreferences", null, null).open(); //$NON-NLS-1$
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return link;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -48,6 +48,7 @@ public final class CEditorMessages extends NLS {
|
||||||
public static String GotoMatchingBracket_error_bracketOutsideSelectedElement;
|
public static String GotoMatchingBracket_error_bracketOutsideSelectedElement;
|
||||||
public static String Scalability_message;
|
public static String Scalability_message;
|
||||||
public static String Scalability_info;
|
public static String Scalability_info;
|
||||||
|
public static String Scalability_linkToolTip;
|
||||||
public static String Scalability_reappear;
|
public static String Scalability_reappear;
|
||||||
public static String Scalability_outlineDisabled;
|
public static String Scalability_outlineDisabled;
|
||||||
public static String ToggleComment_error_title;
|
public static String ToggleComment_error_title;
|
||||||
|
|
|
@ -45,10 +45,12 @@ GotoMatchingBracket_error_invalidSelection=No bracket selected
|
||||||
GotoMatchingBracket_error_noMatchingBracket=No matching bracket found
|
GotoMatchingBracket_error_noMatchingBracket=No matching bracket found
|
||||||
GotoMatchingBracket_error_bracketOutsideSelectedElement=Bracket is outside selected element
|
GotoMatchingBracket_error_bracketOutsideSelectedElement=Bracket is outside selected element
|
||||||
|
|
||||||
Scalability_message=You are opening a large file. Turning on scalability mode might help improve editor's performance. Please see the Scalability preference page under Preferences > C/C++ > Editor.
|
Scalability_message=You are opening a large file. Scalability mode has been turned on for this editor to help improve performance. Please see the Scalability preference page under Preferences > C/C++ > Editor.
|
||||||
Scalability_info=Editor Scalability
|
Scalability_info=Editor Scalability
|
||||||
|
Scalability_linkToolTip=Open the Scalability preference page
|
||||||
Scalability_reappear=Do not show this message again.
|
Scalability_reappear=Do not show this message again.
|
||||||
Scalability_outlineDisabled=Outline is disabled due to scalability mode.
|
# do not translate the href argument (org.eclipse.cdt.ui.preferences.CScalabilityPreferences)
|
||||||
|
Scalability_outlineDisabled=Outline is disabled due to scalability mode (<a href="org.eclipse.cdt.ui.preferences.CScalabilityPreferences">options</a>).
|
||||||
|
|
||||||
ToggleComment_error_title=Comment/Uncomment
|
ToggleComment_error_title=Comment/Uncomment
|
||||||
ToggleComment_error_message=An error occurred while commenting/uncommenting.
|
ToggleComment_error_message=An error occurred while commenting/uncommenting.
|
||||||
|
|
|
@ -1597,7 +1597,7 @@ public class PreferenceConstants {
|
||||||
store.setDefault(PreferenceConstants.SCALABILITY_ALERT, true);
|
store.setDefault(PreferenceConstants.SCALABILITY_ALERT, true);
|
||||||
store.setDefault(PreferenceConstants.SCALABILITY_NUMBER_OF_LINES, 5000);
|
store.setDefault(PreferenceConstants.SCALABILITY_NUMBER_OF_LINES, 5000);
|
||||||
store.setDefault(PreferenceConstants.SCALABILITY_ENABLE_ALL, false);
|
store.setDefault(PreferenceConstants.SCALABILITY_ENABLE_ALL, false);
|
||||||
store.setDefault(PreferenceConstants.SCALABILITY_RECONCILER, false);
|
store.setDefault(PreferenceConstants.SCALABILITY_RECONCILER, true);
|
||||||
store.setDefault(PreferenceConstants.SCALABILITY_SYNTAX_COLOR, false);
|
store.setDefault(PreferenceConstants.SCALABILITY_SYNTAX_COLOR, false);
|
||||||
store.setDefault(PreferenceConstants.SCALABILITY_SEMANTIC_HIGHLIGHT, false);
|
store.setDefault(PreferenceConstants.SCALABILITY_SEMANTIC_HIGHLIGHT, false);
|
||||||
store.setDefault(PreferenceConstants.SCALABILITY_PARSER_BASED_CONTENT_ASSIST, false);
|
store.setDefault(PreferenceConstants.SCALABILITY_PARSER_BASED_CONTENT_ASSIST, false);
|
||||||
|
|
Loading…
Add table
Reference in a new issue