mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-21 21:52:10 +02:00
Cosmetics.
Fix bad line endings in memory/**/*.java Change-Id: I34b4966b7d3fd965ea43b2f676b77ae9b7b4f2aa
This commit is contained in:
parent
9913afd1eb
commit
fb0df4a130
2 changed files with 1494 additions and 1494 deletions
File diff suppressed because it is too large
Load diff
|
@ -1,99 +1,99 @@
|
|||
/*******************************************************************************
|
||||
* Copyright (c) 2013 IBM Corporation and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* IBM - Initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.debug.ui.memory.traditional;
|
||||
|
||||
import org.eclipse.jface.preference.ColorSelector;
|
||||
import org.eclipse.jface.preference.FieldEditor;
|
||||
import org.eclipse.jface.preference.IPreferenceStore;
|
||||
import org.eclipse.jface.preference.PreferenceConverter;
|
||||
import org.eclipse.swt.SWT;
|
||||
import org.eclipse.swt.layout.GridData;
|
||||
import org.eclipse.swt.widgets.Button;
|
||||
import org.eclipse.swt.widgets.Composite;
|
||||
import org.eclipse.swt.widgets.Control;
|
||||
|
||||
public class ColorAndEffectFieldEditor extends FieldEditor {
|
||||
|
||||
private final String nameBold;
|
||||
private final String nameItalic;
|
||||
private final String nameBox;
|
||||
|
||||
private ColorSelector colorSelector;
|
||||
private Button checkBold;
|
||||
private Button checkItalic;
|
||||
private Button checkBox; // :)
|
||||
|
||||
public ColorAndEffectFieldEditor(String name, String nameBold, String nameItalic, String nameBox, String labelText, Composite parent) {
|
||||
super(name, labelText, parent);
|
||||
this.nameBold = nameBold;
|
||||
this.nameItalic = nameItalic;
|
||||
this.nameBox = nameBox;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void adjustForNumColumns(int numColumns) {
|
||||
((GridData) checkItalic.getLayoutData()).horizontalSpan = numColumns - 4;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void doFillIntoGrid(Composite parent, int numColumns) {
|
||||
Control control = getLabelControl(parent);
|
||||
control.setLayoutData(new GridData());
|
||||
|
||||
colorSelector = new ColorSelector(parent);
|
||||
colorSelector.getButton().setLayoutData(new GridData());
|
||||
|
||||
checkBold = new Button(parent, SWT.CHECK);
|
||||
checkBold.setText(TraditionalRenderingMessages.getString("ColorAndEffectFieldEditor.bold"));
|
||||
checkBold.setLayoutData(new GridData());
|
||||
|
||||
checkItalic = new Button(parent, SWT.CHECK);
|
||||
checkItalic.setText(TraditionalRenderingMessages.getString("ColorAndEffectFieldEditor.italic"));
|
||||
checkItalic.setLayoutData(new GridData());
|
||||
|
||||
checkBox = new Button(parent, SWT.CHECK);
|
||||
checkBox.setText(TraditionalRenderingMessages.getString("ColorAndEffectFieldEditor.box"));
|
||||
checkBox.setLayoutData(new GridData());
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void doLoad() {
|
||||
IPreferenceStore store = getPreferenceStore();
|
||||
colorSelector.setColorValue(PreferenceConverter.getColor(store, getPreferenceName()));
|
||||
checkBold.setSelection(store.getBoolean(nameBold));
|
||||
checkItalic.setSelection(store.getBoolean(nameItalic));
|
||||
checkBox.setSelection(store.getBoolean(nameBox));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void doLoadDefault() {
|
||||
IPreferenceStore store = getPreferenceStore();
|
||||
colorSelector.setColorValue(PreferenceConverter.getDefaultColor(store, getPreferenceName()));
|
||||
checkBold.setSelection(store.getDefaultBoolean(nameBold));
|
||||
checkItalic.setSelection(store.getDefaultBoolean(nameItalic));
|
||||
checkBox.setSelection(store.getDefaultBoolean(nameBox));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void doStore() {
|
||||
IPreferenceStore store = getPreferenceStore();
|
||||
PreferenceConverter.setValue(store, getPreferenceName(), colorSelector.getColorValue());
|
||||
store.setValue(nameBold, checkBold.getSelection());
|
||||
store.setValue(nameItalic, checkItalic.getSelection());
|
||||
store.setValue(nameBox, checkBox.getSelection());
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getNumberOfControls() {
|
||||
return 5;
|
||||
}
|
||||
|
||||
}
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2013 IBM Corporation and others.
|
||||
* All rights reserved. This program and the accompanying materials
|
||||
* are made available under the terms of the Eclipse Public License v1.0
|
||||
* which accompanies this distribution, and is available at
|
||||
* http://www.eclipse.org/legal/epl-v10.html
|
||||
*
|
||||
* Contributors:
|
||||
* IBM - Initial API and implementation
|
||||
*******************************************************************************/
|
||||
package org.eclipse.cdt.debug.ui.memory.traditional;
|
||||
|
||||
import org.eclipse.jface.preference.ColorSelector;
|
||||
import org.eclipse.jface.preference.FieldEditor;
|
||||
import org.eclipse.jface.preference.IPreferenceStore;
|
||||
import org.eclipse.jface.preference.PreferenceConverter;
|
||||
import org.eclipse.swt.SWT;
|
||||
import org.eclipse.swt.layout.GridData;
|
||||
import org.eclipse.swt.widgets.Button;
|
||||
import org.eclipse.swt.widgets.Composite;
|
||||
import org.eclipse.swt.widgets.Control;
|
||||
|
||||
public class ColorAndEffectFieldEditor extends FieldEditor {
|
||||
|
||||
private final String nameBold;
|
||||
private final String nameItalic;
|
||||
private final String nameBox;
|
||||
|
||||
private ColorSelector colorSelector;
|
||||
private Button checkBold;
|
||||
private Button checkItalic;
|
||||
private Button checkBox; // :)
|
||||
|
||||
public ColorAndEffectFieldEditor(String name, String nameBold, String nameItalic, String nameBox, String labelText, Composite parent) {
|
||||
super(name, labelText, parent);
|
||||
this.nameBold = nameBold;
|
||||
this.nameItalic = nameItalic;
|
||||
this.nameBox = nameBox;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void adjustForNumColumns(int numColumns) {
|
||||
((GridData) checkItalic.getLayoutData()).horizontalSpan = numColumns - 4;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void doFillIntoGrid(Composite parent, int numColumns) {
|
||||
Control control = getLabelControl(parent);
|
||||
control.setLayoutData(new GridData());
|
||||
|
||||
colorSelector = new ColorSelector(parent);
|
||||
colorSelector.getButton().setLayoutData(new GridData());
|
||||
|
||||
checkBold = new Button(parent, SWT.CHECK);
|
||||
checkBold.setText(TraditionalRenderingMessages.getString("ColorAndEffectFieldEditor.bold"));
|
||||
checkBold.setLayoutData(new GridData());
|
||||
|
||||
checkItalic = new Button(parent, SWT.CHECK);
|
||||
checkItalic.setText(TraditionalRenderingMessages.getString("ColorAndEffectFieldEditor.italic"));
|
||||
checkItalic.setLayoutData(new GridData());
|
||||
|
||||
checkBox = new Button(parent, SWT.CHECK);
|
||||
checkBox.setText(TraditionalRenderingMessages.getString("ColorAndEffectFieldEditor.box"));
|
||||
checkBox.setLayoutData(new GridData());
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void doLoad() {
|
||||
IPreferenceStore store = getPreferenceStore();
|
||||
colorSelector.setColorValue(PreferenceConverter.getColor(store, getPreferenceName()));
|
||||
checkBold.setSelection(store.getBoolean(nameBold));
|
||||
checkItalic.setSelection(store.getBoolean(nameItalic));
|
||||
checkBox.setSelection(store.getBoolean(nameBox));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void doLoadDefault() {
|
||||
IPreferenceStore store = getPreferenceStore();
|
||||
colorSelector.setColorValue(PreferenceConverter.getDefaultColor(store, getPreferenceName()));
|
||||
checkBold.setSelection(store.getDefaultBoolean(nameBold));
|
||||
checkItalic.setSelection(store.getDefaultBoolean(nameItalic));
|
||||
checkBox.setSelection(store.getDefaultBoolean(nameBox));
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void doStore() {
|
||||
IPreferenceStore store = getPreferenceStore();
|
||||
PreferenceConverter.setValue(store, getPreferenceName(), colorSelector.getColorValue());
|
||||
store.setValue(nameBold, checkBold.getSelection());
|
||||
store.setValue(nameItalic, checkItalic.getSelection());
|
||||
store.setValue(nameBox, checkBox.getSelection());
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getNumberOfControls() {
|
||||
return 5;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue