I´m not sure what you mean. But if I understand right, you want to have called a function if the left mouse button ist pressed and the mouse is over the button.
If this realy is what you mean the answer is easy, because what you are looking for is the function_on.