View | Details | Raw Unified | Return to bug 879
Collapse All | Expand All

(-)a/src/newt/native/WindowsWindow.c (-3 / +3 lines)
Lines 972-978 static LRESULT CALLBACK wndProc(HWND wnd, UINT message, WPARAM wParam, LPARAM lP Link Here
972
                wud->width, wud->height, wud->mouseInside, wud->touchDownCount, wud->touchDownLastUp);
972
                wud->width, wud->height, wud->mouseInside, wud->touchDownCount, wud->touchDownLastUp);
973
            if( 0 == wud->touchDownLastUp && 0 == wud->touchDownCount ) {
973
            if( 0 == wud->touchDownLastUp && 0 == wud->touchDownCount ) {
974
                wud->mouseInside = 1;
974
                wud->mouseInside = 1;
975
                (*env)->CallVoidMethod(env, window, requestFocusID, JNI_FALSE);
975
                SetFocus(wnd);
976
                (*env)->CallVoidMethod(env, window, sendMouseEventID,
976
                (*env)->CallVoidMethod(env, window, sendMouseEventID,
977
                                       (jshort) EVENT_MOUSE_PRESSED,
977
                                       (jshort) EVENT_MOUSE_PRESSED,
978
                                       GetModifiers( 0 ),
978
                                       GetModifiers( 0 ),
Lines 1008-1014 static LRESULT CALLBACK wndProc(HWND wnd, UINT message, WPARAM wParam, LPARAM lP Link Here
1008
                wud->width, wud->height, wud->mouseInside, wud->touchDownCount, wud->touchDownLastUp);
1008
                wud->width, wud->height, wud->mouseInside, wud->touchDownCount, wud->touchDownLastUp);
1009
            if( 0 == wud->touchDownCount ) {
1009
            if( 0 == wud->touchDownCount ) {
1010
                wud->mouseInside = 1;
1010
                wud->mouseInside = 1;
1011
                (*env)->CallVoidMethod(env, window, requestFocusID, JNI_FALSE);
1011
                SetFocus(wnd);
1012
                (*env)->CallVoidMethod(env, window, sendMouseEventID,
1012
                (*env)->CallVoidMethod(env, window, sendMouseEventID,
1013
                                       (jshort) EVENT_MOUSE_PRESSED,
1013
                                       (jshort) EVENT_MOUSE_PRESSED,
1014
                                       GetModifiers( 0 ),
1014
                                       GetModifiers( 0 ),
Lines 1041-1047 static LRESULT CALLBACK wndProc(HWND wnd, UINT message, WPARAM wParam, LPARAM lP Link Here
1041
                wud->width, wud->height, wud->mouseInside, wud->touchDownCount, wud->touchDownLastUp);
1041
                wud->width, wud->height, wud->mouseInside, wud->touchDownCount, wud->touchDownLastUp);
1042
            if( 0 == wud->touchDownCount ) {
1042
            if( 0 == wud->touchDownCount ) {
1043
                wud->mouseInside = 1;
1043
                wud->mouseInside = 1;
1044
                (*env)->CallVoidMethod(env, window, requestFocusID, JNI_FALSE);
1044
                SetFocus(wnd);
1045
                (*env)->CallVoidMethod(env, window, sendMouseEventID,
1045
                (*env)->CallVoidMethod(env, window, sendMouseEventID,
1046
                                       (jshort) EVENT_MOUSE_PRESSED,
1046
                                       (jshort) EVENT_MOUSE_PRESSED,
1047
                                       GetModifiers( 0 ),
1047
                                       GetModifiers( 0 ),

Return to bug 879