View Single Post
01-07-11, 11:17 PM   #5
Akkorian
A Flamescale Wyrmkin
 
Akkorian's Avatar
AddOn Author - Click to view addons
Join Date: Nov 2010
Posts: 111
You can’t do func = EnableMouse because there isn’t any function named EnableMouse. Frame-type objects do have an EnableMouse method, but it’s only accessible through the object, not as a global function. You have to store it as a string, and do a table lookup to get the method.

I’m also not sure what you meant by not being able to use the second example with multiple buttons. The only difference between it and the first example is that instead of passing along “clamp” and then having extra code to turn “clamp” into “SetClampedToScreen”, you just pass along “SetClampedToScreen” directly. There’s nothing in there that ties it to a specific button or frame.
__________________
“Be humble, for you are made of earth. Be noble, for you are made of stars.”
  Reply With Quote