2007-03-20, 23:59
I was looking at making a script using WindowXML, and i wanted to get the position in the list and i noticed whoops i forgot those functions. However i quickly added them
print self.getCurrentListPosition()
print self.getListItemself.getSelectedListItem().getLabel2()
print self.getSelectedListItem().getLabel()
So ive added getListItem and getCurrentListPosition. There was getSelectedListItem but that was removed due to redudancy of hte getListItem.
Note) getListItem is a new object created with the infomation from the list item in the windows vectorlist, im 99% sure that setLabel2 and setLabel will not work. I'll look at adding a setListItem so you can change the infomation.
Also, next day or two i might change the WindowXML so it takes
scriptPath = os.getcwd().replace(';','')
WindowXML("Script_WindowXMLExample.xml",scriptPath,"DefaultSkin")
point of this is WindowXML would now also check scriptPath+"\\skins\\currentskin\\" for the file then scriptPath+"\\skins\\DefaultSkin\\" as a last resort. Thanks Jezz_X for this idea. Ill try to make "DefaultSkin" variable optional and default to "Default". So bare this in mind if you’re considering using WindowXML soon.
print self.getCurrentListPosition()
print self.getListItemself.getSelectedListItem().getLabel2()
print self.getSelectedListItem().getLabel()
So ive added getListItem and getCurrentListPosition. There was getSelectedListItem but that was removed due to redudancy of hte getListItem.
Note) getListItem is a new object created with the infomation from the list item in the windows vectorlist, im 99% sure that setLabel2 and setLabel will not work. I'll look at adding a setListItem so you can change the infomation.
Also, next day or two i might change the WindowXML so it takes
scriptPath = os.getcwd().replace(';','')
WindowXML("Script_WindowXMLExample.xml",scriptPath,"DefaultSkin")
point of this is WindowXML would now also check scriptPath+"\\skins\\currentskin\\" for the file then scriptPath+"\\skins\\DefaultSkin\\" as a last resort. Thanks Jezz_X for this idea. Ill try to make "DefaultSkin" variable optional and default to "Default". So bare this in mind if you’re considering using WindowXML soon.