Prepare for alarm support. Improve device-add/edit dialog.