none
Basic user32 processing is broken after the Windows 10 Anniversary Update RRS feed

  • Question

  • Basic user32.dll processing is broken after the Windows 10 Anniversary Update. 

    It is not compatible or hanging. 

    I am in trouble for a long time.

    Case 1:

    It will hang in the operation of a child window of another process. (sample in end of post)
    - Focus on the child window
    - Alt+Space
    - Hang
    or
    - Focus on the child window
    - Press and release the Alt key
    - Hang
    For example, there is a similar problem in the preview pane of the HTML of Windows Explorer. It will hang in the Alt + Space.
    Preview pane is different is the process of a child window.
    No problem in Windows  xp, Vista, 7, 8, 8.1, 10, 10TH2.
    Problem occurs Windows 10 Anniversary Update ONLY.

    Case 2:
    InjectTouchInput()
    It is not converted to mouse events when finger is touching on the screen.
    However, sometimes it can convert to mouse event.
    In simple terms, it is converted successfully only after one second you tap.
    It is a very strange behavior.
    No problem in Windows 8, 8.1, 10, 10, 10TH2.
    Problem occurs Windows 10 Anniversary Update ONLY.
    Please see below :

    InjectTouchInput and RegisterPointerInputTarget not work successfully on Windows 10 Anniversary Update.

    These problems are inter-process / inter-thread operation.

    Please tell me how to solve it.
    Or will it be fixed by Windows Update? (Not fixed in Build 14393.351)


    Sample of case1

    #include <Windows.h>
    
    static FARPROC  pfnEdit;
    LRESULT CALLBACK EditWndProc( HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam ) {
        if( message == WM_DESTROY ) {
            PostQuitMessage(0);
        }
        return CallWindowProc( (WNDPROC)pfnEdit, hwnd, message, wParam, lParam );
    }
    
    int PASCAL WinMain(HINSTANCE hInst,HINSTANCE,LPSTR lpCmdLine,int){
        if( *lpCmdLine != '\0' ) {
            DWORD dwParam = 0;
            while(*lpCmdLine){
                dwParam = dwParam * 10 + ((*lpCmdLine)-'0');
                lpCmdLine ++;
            }
            HWND hwndParent = (HWND)dwParam;
            HWND hwndChild = CreateWindowEx( WS_EX_TOPMOST, TEXT("edit"),
                TEXT("[Child process]\r\n")
                TEXT("Click here and ...\r\n")
                TEXT("\r\n")
                TEXT("Alt+Space to hang\r\n")
                TEXT("in Windows 10 Anniversary Update.\r\n")
                TEXT("\r\n")
                TEXT("Alt key down and up to hang\r\n")
                TEXT("in Windows 10 Anniversary Update.\r\n")
                TEXT("\r\n")
                TEXT("Windows 10 TH2 or previous versions are no problem."),
                WS_CHILD | WS_BORDER | WS_VISIBLE | WS_CLIPSIBLINGS | ES_MULTILINE,
                100, 100, 500, 250, hwndParent, 0, hInst, NULL );
            pfnEdit = (FARPROC)SetWindowLongPtr( hwndChild, GWLP_WNDPROC, (DWORD_PTR)EditWndProc );
        } else {
            HMENU hmenu = CreateMenu();
            AppendMenu(hmenu,MF_STRING,100,TEXT("File"));
            HWND hwndParent = CreateWindowEx( 0, TEXT("edit"),
                TEXT("[Parent process]"),
                WS_OVERLAPPEDWINDOW | WS_VISIBLE | WS_CLIPCHILDREN | ES_MULTILINE,
                0, 0, 1000, 500, NULL, hmenu, hInst, NULL );
            
            TCHAR szExe[MAX_PATH + 1];
            GetModuleFileName(hInst,szExe,sizeof(szExe)/sizeof(szExe[0]) - 1);
            TCHAR szSecondCmdLine[MAX_PATH + 100];
            wsprintf( szSecondCmdLine, TEXT("\"%s\" %d"), szExe, hwndParent );
            PROCESS_INFORMATION pi;
            STARTUPINFOW    si;
            memset( &si, 0, sizeof(si) );
            si.cb = sizeof(si);
            BOOL fSuccess = CreateProcess( NULL, szSecondCmdLine, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi );
            pfnEdit = (FARPROC)SetWindowLongPtr( hwndParent, GWLP_WNDPROC, (DWORD_PTR)EditWndProc );
        }
        MSG msg;
        while( GetMessage( &msg, NULL, 0, 0 ) ) {
            TranslateMessage( &msg );
            DispatchMessage( &msg );
        }
        return 0;
    }


    Sunday, November 6, 2016 1:23 AM

All replies

  • Hi lsmsft,

    Thank you for posting here.

    I try to create win32 application with 4 forms. My OS is win10 and VS version is 2015 update 3.

    But when I press the Alt+Space key. The application doesn’t hang.

    And I also copy your code. Unfortunately the code cannot compile successfully.

     

    Could you please provide a project on one driver?

    Best Regards,

    Hart


    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Tuesday, November 8, 2016 8:08 AM
    Moderator
  • Thank you for testing.
    This happens with multiple PCs.
    Maybe my environment dependency, I refreshed Surface Pro 4 to the initial state now.

    There is no problem with Alt + Space when focused [Parent process] box.
    Problem occurs with Alt + Space when focused [Chikd process] box.

    Windows 10 (normal) is fine.
    Windows 10 Anniversary Update is a problem.

    Test application window is hang.
    Other applications can be operated.

    Project is Win32 project, "Windows application", "Empty project".
    If not a "Empty project", please rewrite first line.
    //#include <windows.h>
    #include "stdafx.h"

    After hangup, you have to kill process by task manager.

    Case 1 and Case 2 have something in common.
    These are crossing the process.
    It seems to have problems with inter-process UI processing in Anniversary Update (Version 1607).
    Tuesday, November 8, 2016 2:10 PM
  • Hi lsmsft,

    I wish you could provide a project for us. 

    My Windows version is 1511. Maybe version 1607 has the problem.

    PS: when my application abnormal shutdown. I will kill the process by task manager. But this is not windows bug.

    Best Regards,

    Hart


    Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Thursday, November 10, 2016 3:21 AM
    Moderator
  • Case 2 problem is fixed by Insider Preview 15058.
    (Probably fixed at 15055)
    Wednesday, March 15, 2017 1:18 PM