diff options
author | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2008-07-04 06:14:01 +0000 |
---|---|---|
committer | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2008-07-04 06:14:01 +0000 |
commit | 12139f54d758b74db632208d4e7402ebcb9f844d (patch) | |
tree | 44eefe328f0d72a003d4b970eda10ace16b62332 /src/main.c | |
parent | 1b66de3fded1a3aefdd31e21ac99c9f5b290b56b (diff) |
win32: handle window messages even if console is initialized.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@2025 ee746299-78ed-0310-b773-934348b2243d
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 11 |
1 files changed, 4 insertions, 7 deletions
@@ -1007,19 +1007,16 @@ static void register_system_events(void) ATOM klass; HINSTANCE hmodule = GetModuleHandle(NULL); - if (hwnd) - return; - if (ctrl_handler_set) - return; - - if (init_console_done) { + if (init_console_done && !ctrl_handler_set) { debug_print("register_system_events(): SetConsoleCtrlHandler\n"); ctrl_handler_set = SetConsoleCtrlHandler(ctrl_handler, TRUE); if (!ctrl_handler_set) g_warning("SetConsoleCtrlHandler() failed\n"); - return; } + if (hwnd) + return; + debug_print("register_system_events(): RegisterClass\n"); memset(&wclass, 0, sizeof(WNDCLASS)); |