adding "menuAtPointer" function. Will come handy to make a test to check the number of menu items.
adding check for the number of items in the menu under the mouse.