diff options
author | jianli@chromium.org <jianli@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-19 22:05:32 +0000 |
---|---|---|
committer | jianli@chromium.org <jianli@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-19 22:05:32 +0000 |
commit | a5acf97edfe6ac555e35ecc279e0c0d3e9f9ffc9 (patch) | |
tree | 503c2b8e128040d192545423044a2c4bb93922ca | |
parent | fb2dafd12b749c047ac50346a7cf05a6c2dd71ac (diff) | |
download | chromium_src-a5acf97edfe6ac555e35ecc279e0c0d3e9f9ffc9.zip chromium_src-a5acf97edfe6ac555e35ecc279e0c0d3e9f9ffc9.tar.gz chromium_src-a5acf97edfe6ac555e35ecc279e0c0d3e9f9ffc9.tar.bz2 |
Fix EventTypeFromNative to return ET_MOUSE_MOVED for WM_NCMOUSEMOVE message.
Unlike WM_MOUSEMOVE, The wParam of WM_NCMOUSEMOVE message contains the hit
test value and we should not use it to check if the mouse button is down.
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/7051010
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@85984 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | views/events/event_win.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/views/events/event_win.cc b/views/events/event_win.cc index 9e063d3..683a4be 100644 --- a/views/events/event_win.cc +++ b/views/events/event_win.cc @@ -60,9 +60,10 @@ ui::EventType EventTypeFromNative(NativeEvent native_event) { case WM_RBUTTONUP: return ui::ET_MOUSE_RELEASED; case WM_MOUSEMOVE: - case WM_NCMOUSEMOVE: return IsButtonDown(native_event) ? ui::ET_MOUSE_DRAGGED : ui::ET_MOUSE_MOVED; + case WM_NCMOUSEMOVE: + return ui::ET_MOUSE_MOVED; case WM_MOUSEWHEEL: return ui::ET_MOUSEWHEEL; case WM_MOUSELEAVE: |