Had some issues with the list module loading an xml news list twice, and showing some blank space at the top of the smooth scroller2 module. This might have had something to do with the way i had put my site together, either through updating or possibly from using swfAdress.
This was only happening if I reloaded the browser page to that list module.
I added this code to the XML- AS layer in
the attached list module to test if the list had already been loaded.
| Code: : |
var loaded = false;
var adminMode:Boolean = false;
Flashblocks.user.watch("loggedIn", loggedInFunction);
function loggedInFunction (prop, oldVal, newVal) {
//trace("Logged In! Level:"+Flashblocks.user.level+" id:"+Flashblocks.user.id+" name:"
+Flashblocks.user.name)
adminMode = true;
}
|
and this in the edit block function:
| Code: : |
if ((file && !loaded) || (file && adminMode)) {
loaded = true;
// set editor tags from here rather then from editblock component inspector.
obj.target.editblockHeader = file
totalY = 0
loadMenu(file)
}
|
The orig demo code that my clients purchased using was a couple of versions old. What I'm doing would cause issues if you are dynamically changing the datasource. Has anyone been doing that by the way? Changing the datasource of an element dynamically?