diff options
author | Mikhail Khodjaiants | 2010-04-06 00:49:45 +0000 |
---|---|---|
committer | Mikhail Khodjaiants | 2010-04-06 00:49:45 +0000 |
commit | 304f3b2500b6bdfc15c20f75cfc5cb688e00242a (patch) | |
tree | b8be64b7f76c85192b7606fc23e6d639cea4c44e /launch | |
parent | c13a2bfe5227b617784b9b32bdea370130ca190d (diff) | |
download | org.eclipse.cdt-304f3b2500b6bdfc15c20f75cfc5cb688e00242a.tar.gz org.eclipse.cdt-304f3b2500b6bdfc15c20f75cfc5cb688e00242a.tar.xz org.eclipse.cdt-304f3b2500b6bdfc15c20f75cfc5cb688e00242a.zip |
Bug 306569: Dynamic content support for ICDebuggerPage
Diffstat (limited to 'launch')
-rw-r--r-- | launch/org.eclipse.cdt.launch/src/org/eclipse/cdt/launch/internal/ui/AbstractCDebuggerTab.java | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/launch/org.eclipse.cdt.launch/src/org/eclipse/cdt/launch/internal/ui/AbstractCDebuggerTab.java b/launch/org.eclipse.cdt.launch/src/org/eclipse/cdt/launch/internal/ui/AbstractCDebuggerTab.java index 074f25d69cd..27b9ad47544 100644 --- a/launch/org.eclipse.cdt.launch/src/org/eclipse/cdt/launch/internal/ui/AbstractCDebuggerTab.java +++ b/launch/org.eclipse.cdt.launch/src/org/eclipse/cdt/launch/internal/ui/AbstractCDebuggerTab.java @@ -17,6 +17,8 @@ import org.eclipse.cdt.debug.core.ICDTLaunchConfigurationConstants; import org.eclipse.cdt.debug.core.ICDebugConfiguration; import org.eclipse.cdt.debug.ui.CDebugUIPlugin; import org.eclipse.cdt.debug.ui.ICDebuggerPage; +import org.eclipse.cdt.debug.ui.ICDebuggerPageExtension; +import org.eclipse.cdt.debug.ui.ICDebuggerPageExtension.IContentChangeListener; import org.eclipse.cdt.launch.ui.CLaunchConfigurationTab; import org.eclipse.core.runtime.CoreException; import org.eclipse.debug.core.ILaunchConfiguration; @@ -48,7 +50,17 @@ public abstract class AbstractCDebuggerTab extends CLaunchConfigurationTab { private boolean fIsInitializing = false; private boolean fPageUpdated; - protected void setDebugConfig(ICDebugConfiguration config) { + private IContentChangeListener fContentListener = new IContentChangeListener() { + + /* (non-Javadoc) + * @see org.eclipse.cdt.debug.ui.ICDebuggerPageExtension.IContentChangeListener#contentChanged() + */ + public void contentChanged() { + contentsChanged(); + } + }; + + protected void setDebugConfig(ICDebugConfiguration config) { fCurrentDebugConfig = config; } @@ -61,7 +73,11 @@ public abstract class AbstractCDebuggerTab extends CLaunchConfigurationTab { } protected void setDynamicTab(ICDebuggerPage tab) { + if ( fDynamicTab instanceof ICDebuggerPageExtension ) + ((ICDebuggerPageExtension)fDynamicTab).removeContentChangeListener( fContentListener ); fDynamicTab = tab; + if ( fDynamicTab instanceof ICDebuggerPageExtension ) + ((ICDebuggerPageExtension)fDynamicTab).addContentChangeListener( fContentListener ); } protected Composite getDynamicTabHolder() { |