Hook up dialog to state vars