updates to importing layouts and device comparison

Viewer is now using CompareDevices to see whether layouts should be
portable to SetList which is safer than comparing just DevNums. And,
Close button replaced by handling window close event.

Also:
- tweaked documentation of CompareDevices
- wrapped CompareDevices for queued devices
- Dialog_AppendLayouts(s) no longer requires user to provide DevNums,
instead getting them itself