Zhiyi Zhang (@zhiyi) commented about programs/explorer/desktop.c:
+static DWORD WINAPI display_settings_restorer_thread( void *param ) +{
- static const WCHAR display_settings_restorer_classname[] = L"__wine_display_settings_restorer";
- DWORD wait_result;
- WNDCLASSW class;
- ATOM atom;
- MSG msg;
- if (!wait_named_mutex( L"__wine_display_settings_restorer_mutex" )) return 0;
- memset( &class, 0, sizeof(class) );
- class.lpfnWndProc = display_settings_restorer_wndproc;
- class.lpszClassName = display_settings_restorer_classname;
- if (!(atom = RegisterClassW( &class )) && GetLastError() != ERROR_CLASS_ALREADY_EXISTS)
You don't need to save the result atom. You can use window class name instead for calling UnregisterClassW().