Factor out helper functions for menu duplication

Create helper function for cloning object by reference
Create helper function for cloning menu action pairs, then linking them
Add ui menu generation

Implement first part of duplicating Program menu.

Signed-off-by: Sandy Carter <sandy.carter@savoirfairelinux.com>
Copy result chain menu

Add aditional_domain param to _clone_menu_action
Copy Configuration menus and submenus

Add helper functions to get custom domains and contexts
Add top_level_menu_id field for other configuration menus