Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDarin Wright2004-11-25 03:22:15 +0000
committerDarin Wright2004-11-25 03:22:15 +0000
commit4af408da2b9b70deb27009fad189d0ca89dd1ffb (patch)
tree28a517be803e15a604682f5a17cbd2294ce84a29
parent31b5add74b9a0b69b0fb557f017621bb1b13603c (diff)
downloadeclipse.platform.debug-4af408da2b9b70deb27009fad189d0ca89dd1ffb.tar.gz
eclipse.platform.debug-4af408da2b9b70deb27009fad189d0ca89dd1ffb.tar.xz
eclipse.platform.debug-4af408da2b9b70deb27009fad189d0ca89dd1ffb.zip
Bug 79450 - flashing cursor, invalid stack frames, stepping problems
-rw-r--r--org.eclipse.debug.ui/plugin.xml7
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/DebugUIPreferenceInitializer.java4
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugWorkInProgressPreferencePage.java65
-rw-r--r--org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/DebugViewContentProvider.java35
4 files changed, 109 insertions, 2 deletions
diff --git a/org.eclipse.debug.ui/plugin.xml b/org.eclipse.debug.ui/plugin.xml
index b7b96bb04..d1492cd2d 100644
--- a/org.eclipse.debug.ui/plugin.xml
+++ b/org.eclipse.debug.ui/plugin.xml
@@ -146,6 +146,13 @@
class="org.eclipse.debug.internal.ui.preferences.StringVariablePreferencePage"
id="org.eclipse.debug.ui.StringVariablePreferencePage">
</page>
+ <!-- WORK IN PROGRESS PAGE TO BE REMOVED -->
+ <page
+ name="Work in Progress"
+ category="org.eclipse.debug.ui.DebugPreferencePage"
+ class="org.eclipse.debug.internal.ui.preferences.DebugWorkInProgressPreferencePage"
+ id="org.eclipse.debug.ui.WorkInProgressPreferencePage">
+ </page>
</extension>
<extension
point="org.eclipse.ui.actionSets">
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/DebugUIPreferenceInitializer.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/DebugUIPreferenceInitializer.java
index 0a8e8365d..660bb0632 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/DebugUIPreferenceInitializer.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/DebugUIPreferenceInitializer.java
@@ -11,6 +11,7 @@
package org.eclipse.debug.internal.ui;
import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
+import org.eclipse.debug.internal.ui.preferences.DebugWorkInProgressPreferencePage;
import org.eclipse.debug.internal.ui.preferences.IDebugPreferenceConstants;
import org.eclipse.debug.ui.IDebugUIConstants;
import org.eclipse.jface.dialogs.MessageDialogWithToggle;
@@ -91,5 +92,8 @@ public class DebugUIPreferenceInitializer extends AbstractPreferenceInitializer
// set default for column size preference
prefs.setDefault(IDebugPreferenceConstants.PREF_COLUMN_SIZE,
IDebugPreferenceConstants.PREF_COLUMN_SIZE_DEFAULT);
+
+ // TODO: REMOVE WORK IN PROGRESS SWITCHES
+ prefs.setDefault(DebugWorkInProgressPreferencePage.WIP_PREF_USE_BACKGROUND_CONTENT, false);
}
} \ No newline at end of file
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugWorkInProgressPreferencePage.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugWorkInProgressPreferencePage.java
new file mode 100644
index 000000000..1631ec5ed
--- /dev/null
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/preferences/DebugWorkInProgressPreferencePage.java
@@ -0,0 +1,65 @@
+/*******************************************************************************
+ * Copyright (c) 2000, 2004 IBM Corporation and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Common Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/cpl-v10.html
+ *
+ * Contributors:
+ * IBM Corporation - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.debug.internal.ui.preferences;
+
+import org.eclipse.debug.internal.ui.DebugUIPlugin;
+import org.eclipse.jface.preference.BooleanFieldEditor;
+import org.eclipse.jface.preference.FieldEditorPreferencePage;
+import org.eclipse.jface.preference.IPreferenceStore;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.ui.IWorkbench;
+import org.eclipse.ui.IWorkbenchPreferencePage;
+
+/**
+ * The page for setting debugger work in progress preferences.
+ */
+public class DebugWorkInProgressPreferencePage extends FieldEditorPreferencePage implements IWorkbenchPreferencePage, IDebugPreferenceConstants {
+
+ public static final String WIP_PREF_USE_BACKGROUND_CONTENT = DebugUIPlugin.getUniqueIdentifier() + ".WIP_USE_BACKGROUND_CONTENT"; //$NON-NLS-1$
+
+ public DebugWorkInProgressPreferencePage() {
+ super(GRID);
+
+ IPreferenceStore store= DebugUIPlugin.getDefault().getPreferenceStore();
+ setPreferenceStore(store);
+ setDescription("Work In Progress"); //$NON-NLS-1$
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.preference.PreferencePage#createControl(Composite)
+ */
+ public void createControl(Composite parent) {
+ super.createControl(parent);
+ }
+
+ /**
+ * @see FieldEditorPreferencePage#createFieldEditors
+ */
+ protected void createFieldEditors() {
+ addField(new BooleanFieldEditor(WIP_PREF_USE_BACKGROUND_CONTENT, "Use background content in debug views", SWT.NONE, getFieldEditorParent())); //$NON-NLS-1$
+ }
+
+ /**
+ * @see IWorkbenchPreferencePage#init(IWorkbench)
+ */
+ public void init(IWorkbench workbench) {
+ }
+
+ /* (non-Javadoc)
+ * @see org.eclipse.jface.preference.IPreferencePage#performOk()
+ */
+ public boolean performOk() {
+ boolean ok= super.performOk();
+ DebugUIPlugin.getDefault().savePluginPreferences();
+ return ok;
+ }
+} \ No newline at end of file
diff --git a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/DebugViewContentProvider.java b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/DebugViewContentProvider.java
index acb2a287f..c71665151 100644
--- a/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/DebugViewContentProvider.java
+++ b/org.eclipse.debug.ui/ui/org/eclipse/debug/internal/ui/views/launch/DebugViewContentProvider.java
@@ -19,7 +19,12 @@ import org.eclipse.debug.core.model.IDebugTarget;
import org.eclipse.debug.core.model.IProcess;
import org.eclipse.debug.core.model.IStackFrame;
import org.eclipse.debug.core.model.IThread;
+import org.eclipse.debug.internal.ui.preferences.DebugWorkInProgressPreferencePage;
import org.eclipse.debug.internal.ui.views.RemoteTreeContentManager;
+import org.eclipse.debug.ui.DebugUITools;
+import org.eclipse.jface.preference.IPreferenceStore;
+import org.eclipse.jface.util.IPropertyChangeListener;
+import org.eclipse.jface.util.PropertyChangeEvent;
import org.eclipse.ui.IWorkbenchPartSite;
import org.eclipse.ui.model.BaseWorkbenchContentProvider;
import org.eclipse.ui.progress.DeferredTreeContentManager;
@@ -29,19 +34,30 @@ import org.eclipse.ui.progress.IDeferredWorkbenchAdapter;
* Provides deferred content for the debug view.
* @since 3.1
*/
-public class DebugViewContentProvider extends BaseWorkbenchContentProvider {
+public class DebugViewContentProvider extends BaseWorkbenchContentProvider implements IPropertyChangeListener {
private DeferredTreeContentManager fManager;
+ // TODO: work in progress - to be removed
+ private boolean fUseDeferredContent = false;
+
public DebugViewContentProvider(LaunchViewer tree, IWorkbenchPartSite site) {
fManager = new RemoteTreeContentManager(this, tree, site);
+ // TODO: remove work in progress
+ IPreferenceStore preferenceStore = DebugUITools.getPreferenceStore();
+ fUseDeferredContent = preferenceStore.getBoolean(DebugWorkInProgressPreferencePage.WIP_PREF_USE_BACKGROUND_CONTENT);
+ preferenceStore.addPropertyChangeListener(this);
+
}
/* (non-Javadoc)
* @see org.eclipse.jface.viewers.ITreeContentProvider#getChildren(java.lang.Object)
*/
public Object[] getChildren(Object parentElement) {
- Object[] children = fManager.getChildren(parentElement);
+ Object[] children = null;
+ if (fUseDeferredContent) {
+ children = fManager.getChildren(parentElement);
+ }
if (children == null) {
children = super.getChildren(parentElement);
}
@@ -93,7 +109,22 @@ public class DebugViewContentProvider extends BaseWorkbenchContentProvider {
*/
public void dispose() {
fManager.cancel(DebugPlugin.getDefault().getLaunchManager());
+ // TODO: remove work in progress
+ DebugUITools.getPreferenceStore().removePropertyChangeListener(this);
super.dispose();
}
+ /* (non-Javadoc)
+ *
+ * TODO: remove work in progress
+ *
+ * @see org.eclipse.jface.util.IPropertyChangeListener#propertyChange(org.eclipse.jface.util.PropertyChangeEvent)
+ */
+ public void propertyChange(PropertyChangeEvent event) {
+ if (event.getProperty().equals(DebugWorkInProgressPreferencePage.WIP_PREF_USE_BACKGROUND_CONTENT)) {
+ fUseDeferredContent = DebugUITools.getPreferenceStore().getBoolean(DebugWorkInProgressPreferencePage.WIP_PREF_USE_BACKGROUND_CONTENT);
+ }
+
+ }
+
}

Back to the top