Refactored the ToolTray object and ContextMenu object definition out of the M4 object making it much easier logic to follow and work with.