updated menu element registration to use new callback functionality