diff options
author | cpu@google.com <cpu@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-19 17:57:39 +0000 |
---|---|---|
committer | cpu@google.com <cpu@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-19 17:57:39 +0000 |
commit | a54f8ed6c7d2609319568e085993410b8bf8303c (patch) | |
tree | 72c2eba393e01dec5a132120d7dec00450bf9c9c /chrome | |
parent | 1592f712f88406bf59bd71389f7e5ca634f833e2 (diff) | |
download | chromium_src-a54f8ed6c7d2609319568e085993410b8bf8303c.zip chromium_src-a54f8ed6c7d2609319568e085993410b8bf8303c.tar.gz chromium_src-a54f8ed6c7d2609319568e085993410b8bf8303c.tar.bz2 |
Use correct calling convention for intercepted call
- Thanks to zhu.she.pi@gmail.com for finding the bug
BUG=14631
TEST=no test
Review URL: http://codereview.chromium.org/131066
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18827 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r-- | chrome/browser/autocomplete/autocomplete_edit_view_win.cc | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/chrome/browser/autocomplete/autocomplete_edit_view_win.cc b/chrome/browser/autocomplete/autocomplete_edit_view_win.cc index 5cc2662..03e7824 100644 --- a/chrome/browser/autocomplete/autocomplete_edit_view_win.cc +++ b/chrome/browser/autocomplete/autocomplete_edit_view_win.cc @@ -331,7 +331,8 @@ const SkColor kSchemeSelectedStrikeoutColor = HWND edit_hwnd = NULL; PAINTSTRUCT paint_struct; -HDC BeginPaintIntercept(HWND hWnd, LPPAINTSTRUCT lpPaint) { +// Intercepted method for BeginPaint(). Must use __stdcall convention. +HDC WINAPI BeginPaintIntercept(HWND hWnd, LPPAINTSTRUCT lpPaint) { if (!edit_hwnd || (hWnd != edit_hwnd)) return ::BeginPaint(hWnd, lpPaint); @@ -339,7 +340,8 @@ HDC BeginPaintIntercept(HWND hWnd, LPPAINTSTRUCT lpPaint) { return paint_struct.hdc; } -BOOL EndPaintIntercept(HWND hWnd, const PAINTSTRUCT* lpPaint) { +// Intercepted method for EndPaint(). Must use __stdcall convention. +BOOL WINAPI EndPaintIntercept(HWND hWnd, const PAINTSTRUCT* lpPaint) { return (edit_hwnd && (hWnd == edit_hwnd)) ? true : ::EndPaint(hWnd, lpPaint); } |