Detlef Riekenberg : user32: Move a comment about HLOCAL16 to user.exe.

Alexandre Julliard julliard at winehq.org
Tue Jan 5 11:37:52 CST 2010


Module: wine
Branch: master
Commit: 2f529c39fda88a9c5803bd5ff3bf9c63ad0247ac
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=2f529c39fda88a9c5803bd5ff3bf9c63ad0247ac

Author: Detlef Riekenberg <wine.dev at web.de>
Date:   Tue Jan  5 15:58:01 2010 +0100

user32: Move a comment about HLOCAL16 to user.exe.

---

 dlls/user.exe16/message.c |   11 +++++++++++
 dlls/user32/edit.c        |   14 +-------------
 2 files changed, 12 insertions(+), 13 deletions(-)

diff --git a/dlls/user.exe16/message.c b/dlls/user.exe16/message.c
index 011e5c4..1ff58a7 100644
--- a/dlls/user.exe16/message.c
+++ b/dlls/user.exe16/message.c
@@ -2094,6 +2094,17 @@ static LRESULT combo_proc16( HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam,
     return wow_handlers32.combo_proc( hwnd, msg, wParam, lParam, FALSE );
 }
 
+/*********************************************************************
+ * edit_lock_buffer (internal)
+ *
+ * A 16 bit application might send an EM_GETHANDLE message and expect a HLOCAL16
+ * (16 bit SEG:OFF handler). From that moment on we have to keep using this
+ * 16 bit memory handler, because it is supposed to be valid at all times after
+ * EM_GETHANDLE.
+ * We create a HLOCAL16 buffer in edit_get_handle and copy the text from the
+ * HLOCAL buffer, when needed
+ *
+ */
 
 #define GWW_HANDLE16 sizeof(void*)
 
diff --git a/dlls/user32/edit.c b/dlls/user32/edit.c
index d7ab5b4..20a853e 100644
--- a/dlls/user32/edit.c
+++ b/dlls/user32/edit.c
@@ -1088,19 +1088,7 @@ static inline void text_buffer_changed(EDITSTATE *es)
 }
 
 /*********************************************************************
- *
- *	EDIT_LockBuffer
- *
- *	This acts as a LocalLock16(), but it locks only once.  This way
- *	you can call it whenever you like, without unlocking.
- *
- *	Initially the edit control allocates a HLOCAL32 buffer 
- *	(32 bit linear memory handler).  However, 16 bit application
- *	might send an EM_GETHANDLE message and expect a HLOCAL16 (16 bit SEG:OFF
- *	handler).  From that moment on we have to keep using this 16 bit memory
- *	handler, because it is supposed to be valid at all times after EM_GETHANDLE.
- *	What we do is create a HLOCAL16 buffer, copy the text, and do pointer
- *	conversion.
+ * EDIT_LockBuffer
  *
  */
 static void EDIT_LockBuffer(EDITSTATE *es)




More information about the wine-cvs mailing list