From: <ed...@ed...> - 2008-09-27 04:54:16
|
Author: incastrix Date: 2008-09-26 23:28:26 -0500 (Fri, 26 Sep 2008) New Revision: 1611 Modified: trunk/net.sourceforge.phpeclipse.xdebug.core/src/net/sourceforge/phpeclipse/xdebug/php/model/XDebugAbstractValue.java Log: Enable first implementation of value change in varialbles view. Modified: trunk/net.sourceforge.phpeclipse.xdebug.core/src/net/sourceforge/phpeclipse/xdebug/php/model/XDebugAbstractValue.java =================================================================== --- trunk/net.sourceforge.phpeclipse.xdebug.core/src/net/sourceforge/phpeclipse/xdebug/php/model/XDebugAbstractValue.java 2008-09-27 04:26:23 UTC (rev 1610) +++ trunk/net.sourceforge.phpeclipse.xdebug.core/src/net/sourceforge/phpeclipse/xdebug/php/model/XDebugAbstractValue.java 2008-09-27 04:28:26 UTC (rev 1611) @@ -1,5 +1,4 @@ -/* - * Created on 23.11.2004 + /* Created on 23.11.2004 * * TODO To change the template for this generated file go to * Window - Preferences - Java - Code Style - Code Templates @@ -9,6 +8,7 @@ import net.sourceforge.phpeclipse.xdebug.core.Base64; import net.sourceforge.phpeclipse.xdebug.core.PHPDebugUtils; +import org.eclipse.debug.core.DebugEvent; import org.eclipse.debug.core.DebugException; import org.eclipse.debug.core.model.IValue; import org.eclipse.debug.core.model.IVariable; @@ -37,8 +37,8 @@ NumChildren = Integer.parseInt(PHPDebugUtils.getAttributeValue(varNode, "numchildren")); } - NodeList property = varNode.getChildNodes(); if (NumChildren > 0) { + NodeList property = varNode.getChildNodes(); renderValueString(""+property.getLength()); fVariables = new IVariable[property.getLength()]; for (int i = 0; i<property.getLength(); i++) { @@ -53,8 +53,7 @@ } catch (NullPointerException e) { str=""; } - - + String Encoding = PHPDebugUtils.getAttributeValue(varNode,"encoding"); if (Encoding.equals("base64")) { @@ -114,17 +113,14 @@ public abstract boolean verifyValue(String expression); public boolean setValue(String expression) { - if (!verifyValue(expression)) + if (!verifyValue(expression)) { return false; - if( getDebugTarget() == null ) { - renderValueString(expression); - } else { - /* if(((XDebugTarget) getDebugTarget()).setVarValue(fVariable.getFullName(),expression)) { - renderValueString(expression); - return true; - }*/ - } - return false; + } + + renderValueString(expression); + fireEvent(new DebugEvent(this, DebugEvent.CHANGE, DebugEvent.CONTENT)); + + return true; } public boolean supportsValueModification() { |