PDA

View Full Version : Quick question about Genericcontrol



drahkar
May 17th, 2011, 03:08
Can it accept an onDrop?

drahkar
May 17th, 2011, 03:26
Better question. Already figured the first one out.

Why, when i send a onDrop a dragdata object by dragging from somewhere else, does it give the error: attempt to index local 'draginfo' (a nil value)

I know it has data in it. I confirm this in the onDrag function that builds the data for for the draginfo object in a onDrag function. But for some reason, the onDrop does not recognize it.

Any ideas?

drahkar
May 17th, 2011, 03:36
Correction to the Refdoc. On the windowcontrol, the details on the onDrop() says that it needs button, x, y, and dragdata. However this is incorrect. It takes x, y, and dragdata. ie onDrop(x, y, draginfo). If you add button in there, draginfo does not work.

https://www.fantasygrounds.com/refdoc/windowcontrol.xcp#onDrop

Moon Wizard
May 17th, 2011, 07:18
Got it.

Thanks,
JPG