Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[cdt-patch] Added the 'hasValueChanged' method to 'CRegister'.

Added the 'hasValueChanged' method to 'CRegister'.

Index: ChangeLog
===================================================================
RCS file: /home/tools/org.eclipse.cdt.debug.core/ChangeLog,v
retrieving revision 1.6
diff -u -r1.6 ChangeLog
--- ChangeLog 10 Oct 2002 22:16:14 -0000 1.6
+++ ChangeLog 10 Oct 2002 22:28:51 -0000
@@ -1,4 +1,8 @@
 2002-10-10 Mikhail Khodjaiants
+ * CVariable.java: Made the 'fChanged' field protected to access to it from the derived class (CRegister).
+ * CRegister.java: Added the 'hasValueChanged' method to 'CRegister'.
+
+2002-10-10 Mikhail Khodjaiants
  * CThread.java: Check if the selected frame is current before calling 'setCurrentStackFrame'.
 
 2002-10-10 Mikhail Khodjaiants
Index: src/org/eclipse/cdt/debug/internal/core/model/CRegister.java
===================================================================
RCS file: /home/tools/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CRegister.java,v
retrieving revision 1.2
diff -u -r1.2 CRegister.java
--- src/org/eclipse/cdt/debug/internal/core/model/CRegister.java 2 Oct 2002 19:25:14 -0000 1.2
+++ src/org/eclipse/cdt/debug/internal/core/model/CRegister.java 10 Oct 2002 22:28:51 -0000
@@ -9,6 +9,7 @@
 import org.eclipse.debug.core.DebugException;
 import org.eclipse.debug.core.model.IRegister;
 import org.eclipse.debug.core.model.IRegisterGroup;
+import org.eclipse.debug.core.model.IValue;
 
 /**
  *
@@ -34,5 +35,18 @@
  public IRegisterGroup getRegisterGroup() throws DebugException
  {
   return (IRegisterGroup)getParent();
+ }
+
+ /* (non-Javadoc)
+  * @see org.eclipse.debug.core.model.IVariable#hasValueChanged()
+  */
+ public boolean hasValueChanged() throws DebugException
+ {
+  IValue value = getValue();
+  if ( value != null )
+  {
+   return ( value.hasVariables() ) ? false : fChanged;
+  }
+  return false;
  }
 }
Index: src/org/eclipse/cdt/debug/internal/core/model/CVariable.java
===================================================================
RCS file: /home/tools/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CVariable.java,v
retrieving revision 1.9
diff -u -r1.9 CVariable.java
--- src/org/eclipse/cdt/debug/internal/core/model/CVariable.java 7 Oct 2002 17:30:48 -0000 1.9
+++ src/org/eclipse/cdt/debug/internal/core/model/CVariable.java 10 Oct 2002 22:28:51 -0000
@@ -56,7 +56,7 @@
  /**
   * Change flag.
   */
- private boolean fChanged = false;
+ protected boolean fChanged = false;
 
  /**
   * The type name of this variable.

Back to the top