comctl32/updown: Don't pass VK_[UP|DOWN] to original Up/Don control buddy's winproc

Nikolay Sivov bunglehead at gmail.com
Thu Apr 2 16:30:22 CDT 2009


http://bugs.winehq.org/show_bug.cgi?id=7033

When you press up/down keys caretr should be set to leftmost position
of updown control buddy edit control if a value changed.
If value didn't change caret shouldn't change position.
Mouse wheel isn't affected here cause buddy defproc handle it the way we want
for up/down.

Changelog:
    - Don't pass VK_[UP|DOWN] to original Up/Don control buddy's winproc

>From 43df5625f4fb2b4bafacffce56c6da5281aeb0f6 Mon Sep 17 00:00:00 2001
From: Nikolay Sivov <bunglehead at gmail.com>
Date: Thu, 2 Apr 2009 17:20:50 -0400
Subject: Don't pass VK_[UP|DOWN] to original Up/Don control buddy's winproc

---
 dlls/comctl32/updown.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/dlls/comctl32/updown.c b/dlls/comctl32/updown.c
index abe5f95..c9ec23c 100644
--- a/dlls/comctl32/updown.c
+++ b/dlls/comctl32/updown.c
@@ -507,6 +507,7 @@ UPDOWN_Buddy_SubclassProc(HWND  hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
         HWND upDownHwnd = GetPropW(hwnd, BUDDY_UPDOWN_HWND);
 
 	UPDOWN_KeyPressed(UPDOWN_GetInfoPtr(upDownHwnd), (int)wParam);
+	if ((wParam == VK_UP) || (wParam == VK_DOWN)) return 0;
     }
     else if (uMsg == WM_MOUSEWHEEL) {
         HWND upDownHwnd = GetPropW(hwnd, BUDDY_UPDOWN_HWND);
-- 
1.5.6.5





More information about the wine-patches mailing list