fixed merge conflict
wip merge
added the modal dialog back in.