get 'modified' indicator working on document windows again (fixes #2194)