KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > debug > internal > ui > views > memory > ResetMemoryBlockPreferencePage


1 /*******************************************************************************
2  * Copyright (c) 2005, 2006 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11
12 package org.eclipse.debug.internal.ui.views.memory;
13
14 import org.eclipse.debug.internal.ui.DebugUIMessages;
15 import org.eclipse.debug.internal.ui.preferences.IDebugPreferenceConstants;
16 import org.eclipse.debug.ui.DebugUITools;
17 import org.eclipse.debug.ui.IDebugUIConstants;
18 import org.eclipse.jface.preference.FieldEditorPreferencePage;
19 import org.eclipse.jface.preference.RadioGroupFieldEditor;
20 import org.eclipse.swt.widgets.Composite;
21 import org.eclipse.swt.widgets.Control;
22 import org.eclipse.ui.PlatformUI;
23
24 public class ResetMemoryBlockPreferencePage extends FieldEditorPreferencePage{
25     
26     public ResetMemoryBlockPreferencePage()
27     {
28         super(FieldEditorPreferencePage.GRID);
29         setPreferenceStore(DebugUITools.getPreferenceStore());
30         setTitle(DebugUIMessages.ResetMemoryBlockPreferencePage_0);
31     }
32     
33
34     protected void createFieldEditors() {
35         RadioGroupFieldEditor editor = new RadioGroupFieldEditor(IDebugPreferenceConstants.PREF_RESET_MEMORY_BLOCK, DebugUIMessages.ResetMemoryBlockPreferencePage_1, 1, new String JavaDoc[][] {{DebugUIMessages.ResetMemoryBlockPreferencePage_2, IDebugPreferenceConstants.RESET_VISIBLE},{DebugUIMessages.ResetMemoryBlockPreferencePage_3, IDebugPreferenceConstants.RESET_ALL}}, getFieldEditorParent());
36         addField(editor);
37     }
38     
39     protected Control createContents(Composite parent) {
40         PlatformUI.getWorkbench().getHelpSystem().setHelp(parent, IDebugUIConstants.PLUGIN_ID + ".resetMemoryMonitor_preference_page_context"); //$NON-NLS-1$
41
return super.createContents(parent);
42     }
43
44 }
45
Popular Tags