now browsing by tag
I’m not sure if this is a bug.
Script 1 errors out on line 3:
// Script 1
var panel = LL.getContainerById(65564);
alert(panel);
alert(panel.getPositionX()); // Wrapped java.lang.NullPointerException
But the following script works:
// Script 2
var panel = LL.getItemById(65564);
alert(panel.getContainer().getPositionX()); // gives me the expected values
In script 1, given that item 65564 is not itself a container, should the exception not occur in the call to getContainerById(65564)? Or perhaps getContainerById(65564) should return null instead of an object?
]]>Hi, I wrote a script in the Resume event of a folder. The first few lines look like this:
var item = LL.getEvent().getItem();
alert(“item=”+item);
This shows “item=null” in the resulting alert.
I expected that in line 2, item would contain a reference to the folder on which the resume event was triggered, but it looks like I’m missing something here. I want to darken the folder item on my desktop when the folder is opened, and lighten it back to the original color when it is closed. What would be the right way to achieve this effect?
Thanks in advance!
]]>