Created additional conditions to allow more flexibility

You can now disable the default submenus, and display only custom ones
if you like.