Fix weird errors that have been around since forever. Start filling in modality for win32.
Fill in modality on win32.
Kill debug code.