Refactor to handle MenuDialog per id.