<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class='hmmessage'>
<BR>&gt; &gt; ==============================================================================<BR>&gt; &gt; # Patch<BR>&gt; &gt; ==============================================================================<BR>&gt; &gt; --- wine-1.1.1-orig/dlls/user32/win.c 2008-07-12 01:55:55.000000000 +1000<BR>&gt; &gt; +++ wine-1.1.1/dlls/user32/win.c 2008-07-14 16:49:21.000000000 +1000<BR>&gt; &gt; @@ -173,6 +173,13 @@ static WND *create_window_handle( HWND p<BR>&gt; &gt; win-&gt;owner = full_owner;<BR>&gt; &gt; win-&gt;class = class;<BR>&gt; &gt; win-&gt;winproc = get_class_winproc( class );<BR>&gt; &gt; + /* This is a window hack - When builtin Edit class has been subclassed by SetClassLong(Ptr)W */<BR>&gt; &gt; + /* If creating ansi Edit window &amp; the class does not have a ansi proc, use unicode proc as ansi */<BR>&gt; &gt; + if(!unicode &amp;&amp; !IS_INTRESOURCE(name) &amp;&amp; !strcmpiW( name, EDIT_builtin_class.name )<BR>&gt; &gt; + &amp;&amp; WINPROC_IsUnicode( win-&gt;winproc, 0 ) &amp;&amp; WINPROC_IsUnicode( win-&gt;winproc, 1 ))<BR>&gt; &gt; + {<BR>&gt; &gt; + win-&gt;winproc = WINPROC_AllocProc((WNDPROC)WINPROC_GetProc( win-&gt;winproc, 1 ), NULL);<BR>&gt; &gt; + }<BR>&gt; <BR>&gt; It doesn't seem likely that this behaviour just applies to edit<BR>&gt; controls. More likely, it applies to all builtin classes.<BR>&gt; <BR>&gt; -- <BR>&gt; Rob Shearman<BR><BR>
&nbsp;<BR>
Yes you are right, this behaviour applies to all builtin classes. I can either <BR>
&nbsp;<BR>
1. add more strcmpiW to compare with all the class names, <BR>
&nbsp;&nbsp;&nbsp; <BR>
&nbsp;&nbsp; This can slow down create_window_handle() a little bit.<BR>
&nbsp;<BR>
or<BR>
2. prove that there is no need for other builtin classes.<BR>
&nbsp;<BR>
&nbsp;&nbsp; The major difference before Edit and other builtin controls is: the Text in other builtin control does<BR>
&nbsp;&nbsp; not interact with user, the&nbsp;WM_SETTEXT&nbsp;message do A-&gt;W&nbsp;conversion, WM_GETTEXT do a <BR>
&nbsp;&nbsp; W-&gt;A conversion, it can get&nbsp;same string back. &nbsp;so current wine can handle it.<BR>
&nbsp;<BR>
&nbsp; The Edit control interact with user and input system, W-&gt;A conversion of SendMessageA(WM_GETTEXT)<BR>
&nbsp;&nbsp;will not&nbsp;get eact&nbsp;the same string&nbsp;as user entered (eg CJK text). So if we create a Ansi Edit window, we do<BR>
&nbsp;&nbsp;not want W-&gt;A&nbsp;&nbsp;conversion. That is why my patch is needed to make Edit window a Ansi window.<BR>
&nbsp;<BR>
So what do you think we should do?<BR>
&nbsp;<BR>
Regards<BR>
Hongbo<BR><br /><hr />Sell your car for just $40 at CarPoint.com.au <a href='http://a.ninemsn.com.au/b.aspx?URL=http%3A%2F%2Fsecure%2Dau%2Eimrworldwide%2Ecom%2Fcgi%2Dbin%2Fa%2Fci%5F450304%2Fet%5F2%2Fcg%5F801459%2Fpi%5F1004813%2Fai%5F859641&_t=762955845&_r=tig_OCT07&_m=EXT' target='_new'>It's simple! </a></body>
</html>