popUpMenu mel notes: "dagObjectHit" "link" Lots of in-depth notes, links and A template for creating an object aware menu "WITHOUT" hacking maya's internal mel files.
The upper leg bones top should be very far outward instead of in the center of the leg to avoid collapsing. Your skinning probably also needs some work.