fix WPopupMenu issue: deleting the popup menu anchor button before deleting the popup menu