[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
[cdt-patch] FIX PR 27937 C Editor Preferences NPE
|
Index: ChangeLog
===================================================================
RCS file: /home/tools/org.eclipse.cdt.ui/ChangeLog,v
retrieving revision 1.42
diff -u -r1.42 ChangeLog
--- ChangeLog 6 Dec 2002 19:59:26 -0000 1.42
+++ ChangeLog 11 Dec 2002 15:20:11 -0000
@@ -1,3 +1,11 @@
+2002-12-11 Alain Magloire
+
+ Fix PR 27937. NPE in the C Editor preference page.
+
+ * src/org/eclipse/cdt/internal/ui/preferences/CEditorPreferencePage.java (createBehaviourPage):
+ Remove listeners and variables for Margins, this will be enable by
+ only saving the changes in the store values.
+
2002-12-06 Alain Magloire
The hovering uses to the indexer to gather some information, but
Index: src/org/eclipse/cdt/internal/ui/preferences/CEditorPreferencePage.java
===================================================================
RCS file: /home/tools/org.eclipse.cdt.ui/src/org/eclipse/cdt/internal/ui/preferences/CEditorPreferencePage.java,v
retrieving revision 1.4
diff -u -r1.4 CEditorPreferencePage.java
--- src/org/eclipse/cdt/internal/ui/preferences/CEditorPreferencePage.java 29 Oct 2002 21:40:58 -0000 1.4
+++ src/org/eclipse/cdt/internal/ui/preferences/CEditorPreferencePage.java 11 Dec 2002 15:20:12 -0000
@@ -560,9 +560,6 @@
private Control fBracketHighlightColor;
private Button fLineHighlightButton;
private Control fLineHighlightColor;
- protected Button fPrintMarginButton;
- protected Control fPrintMarginColor;
- protected Control fPrintMarginColumn;
private Button fProblemIndicationButton;
private Control fProblemIndicationColor;
private Control fFindScopeColor;
@@ -588,14 +585,11 @@
addTextField(behaviorComposite, label, CSourceViewerConfiguration.PREFERENCE_TAB_WIDTH, 2, 0, true);
label= "Print margin col&umn:";
- fPrintMarginColumn= addTextField(behaviorComposite, label, CEditor.PRINT_MARGIN_COLUMN, 4, 0, true);
+ addTextField(behaviorComposite, label, CEditor.PRINT_MARGIN_COLUMN, 4, 0, true);
label= "Insert &space for tabs";
addCheckBox(behaviorComposite, label, CEditor.SPACES_FOR_TABS, 0);
-
- //label= "Show overview &ruler";
- //addCheckBox(behaviorComposite, label, CompilationUnitEditor.OVERVIEW_RULER, 0);
-
+
label= "Highlight &matching brackets";
fBracketHighlightButton= addCheckBox(behaviorComposite, label, CEditor.MATCHING_BRACKETS, 0);
@@ -615,17 +609,7 @@
addCheckBox(behaviorComposite, label, CEditor.OVERVIEW_RULER, 0);
label= "Show print &margin";
- fPrintMarginButton= addCheckBox(behaviorComposite, label, CEditor.PRINT_MARGIN, 0);
-
- fPrintMarginButton.addSelectionListener(new SelectionListener() {
- public void widgetSelected(SelectionEvent e) {
- boolean enabled= fPrintMarginButton.getSelection();
- setEnabled(fPrintMarginColor, enabled);
- setEnabled(fPrintMarginColumn, enabled);
- }
- public void widgetDefaultSelected(SelectionEvent e) {
- }
- });
+ addCheckBox(behaviorComposite, label, CEditor.PRINT_MARGIN, 0);
Label l= new Label(behaviorComposite, SWT.LEFT );
GridData gd= new GridData(GridData.HORIZONTAL_ALIGN_FILL);