Tk Source Code

Check-in [cf189c70]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix [35a8df9a42]: tk_getOpenFile & Co fail on Windows with "CoInitialize has not been called" if no toplevel has been mapped yet

Since [03ce8fe9d1] tkWinDialog.c relied on CoInitialize() being called in UpdateWrapper(), which happens only when a toplevel is mapped.

Downloads: See separate download page
Timelines: family | ancestors | descendants | both | win-dialog-coinitialize
Files: files | file ages | folders
SHA3-256: cf189c70d7e6b03b56ac42df56f75d08792313e1e6f64c36c35a42a2a2e2c961
User & Date: serhiy.storchaka 2026-09-18 11:38:05.858
Original Comment: Fix tk_getOpenFile & Co failing on Windows with "CoInitialize has not been called" if no toplevel has been mapped yet

Since [03ce8fe9d1] tkWinDialog.c relied on CoInitialize() being called in UpdateWrapper(), which happens only when a toplevel is mapped.

References
2026-09-29
19:09 • Closed ticket [35a8df9a]: MS-Win: tk_getOpenFile fails with "CoInitialize has not been called" if no toplevel has been mapped yet plus 9 other changes artifact: 9d923653 user: oehhar
Context
2026-09-21
10:54
Add a test for [35a8df9a42] check-in: bf677906 user: serhiy.storchaka tags: win-dialog-coinitialize
2026-09-18
11:38
Fix [35a8df9a42]: tk_getOpenFile & Co fail on Windows with "CoInitialize has not been called" if no toplevel has been mapped yet

Since [03ce8fe9d1] tkWinDialog.c relied on CoInitialize() being called in UpdateWrapper(), which happens only when a toplevel is mapped. check-in: cf189c70 user: serhiy.storchaka tags: win-dialog-coinitialize

2026-09-17
14:49
Follow-up to [3cb7c4ac72]: don't clamp the result of Tk_GetUserInactiveTime() on Windows check-in: d2b7156d user: jan.nijtmans tags: trunk, main
Changes
Unified Diff Side-by-Side Diff Patch
Changes to win/tkWinDialog.c.