[Laszlo-checkins] r11385 - openlaszlo/trunk/WEB-INF/lps/lfc/data
bargull@openlaszlo.org
bargull at openlaszlo.org
Thu Oct 9 00:41:38 PDT 2008
Author: bargull
Date: 2008-10-09 00:41:33 -0700 (Thu, 09 Oct 2008)
New Revision: 11385
Modified:
openlaszlo/trunk/WEB-INF/lps/lfc/data/LzDatapath.lzs
openlaszlo/trunk/WEB-INF/lps/lfc/data/LzReplicationManager.lzs
Log:
Change 20081008-bargull-xEZ by bargull at dell--p4--2-53 on 2008-10-08 11:48:04
in /home/Admin/src/svn/openlaszlo/trunk
for http://svn.openlaszlo.org/openlaszlo/trunk
Summary: selection state did not update properly
New Features:
Bugs Fixed: LPP-2339
Technical Reviewer: ptw
QA Reviewer: mamye
Doc Reviewer: (pending)
Documentation:
Release Notes:
Details:
The current selection-logic did not account a selection-change if the data-element didn't change,
which might happen for lazy replicated elements. Therefore I've moved the "setSelected()"-call before
the "if(pc)"-block.
Additionally moved setter for "datacontrolsvisibility" to property declaration
UPDATE:
Tucker asked me to take a more thorough look at clone-pool, especially when a clone gets recycled back to the pool.
This revealed the original cause for the selection-bug: when the clone was recycled, the clone's datapath wasn't reset to null.
Tests:
see bugreport
Modified: openlaszlo/trunk/WEB-INF/lps/lfc/data/LzDatapath.lzs
===================================================================
--- openlaszlo/trunk/WEB-INF/lps/lfc/data/LzDatapath.lzs 2008-10-08 23:46:07 UTC (rev 11384)
+++ openlaszlo/trunk/WEB-INF/lps/lfc/data/LzDatapath.lzs 2008-10-09 07:41:33 UTC (rev 11385)
@@ -101,6 +101,14 @@
*/
var datacontrolsvisibility :Boolean = true;
+/**
+ * @access private
+ * @devnote Setter for datacontrolsvisiblity
+ */
+function $lzc$set_datacontrolsvisibility (v:Boolean) :void {
+ this.datacontrolsvisibility = v;
+}
+
/** @access private */
var __LZtakeDPSlot :Boolean = true;
/** @access private */
@@ -280,8 +288,6 @@
pdp.__LZdepChildren.push( c );
}
}
-
-
}
} else if ($debug) {
Debug.warn("unexpected state for '%w', couldn't find parent-datapath!", this);
@@ -629,14 +635,6 @@
/**
* @access private
- * @devnote Setter for datacontrolsvisiblity
- */
-function $lzc$set_datacontrolsvisibility (v) :void {
- this.datacontrolsvisibility = v;
-}
-
-/**
- * @access private
* @devnote Setter for __LZmanager
*/
function $lzc$set___LZmanager ( m:LzReplicationManager ) :void {
@@ -656,17 +654,16 @@
var pc:Boolean = this.p != p;
this.p = p;
- //FIXME: [20080327 anba] LPP-5328
- //if ( pc || true ) {
+ // FIXME: [20080327 anba] (LPP-5328) this needs some tweaks to detect structural changes
+ // of a data-element, e.g. an attribute-node or a text-node has changed
if ( pc ) {
-
if ( p && this.sel != p.sel ){
this.sel = p.sel || false;
this.immediateparent.setSelected( this.sel );
}
this.__LZpchanged = true;
- this.__LZsetData( );
+ this.__LZsetData();
}
}
Modified: openlaszlo/trunk/WEB-INF/lps/lfc/data/LzReplicationManager.lzs
===================================================================
--- openlaszlo/trunk/WEB-INF/lps/lfc/data/LzReplicationManager.lzs 2008-10-08 23:46:07 UTC (rev 11384)
+++ openlaszlo/trunk/WEB-INF/lps/lfc/data/LzReplicationManager.lzs 2008-10-09 07:41:33 UTC (rev 11385)
@@ -838,7 +838,7 @@
var onremsub:LzDeclaredEventClass = cl.immediateparent.onremovesubview;
if (onremsub.ready) onremsub.sendEvent( cl );
cl.isdetatchedclone = true;
- cl.p = null;
+ cl.datapath.p = null;
}
/**
More information about the Laszlo-checkins
mailing list