<DIV>
<DIV>Hello Roderick,</DIV>
<DIV> </DIV>
<DIV>Thank you for your answering.</DIV>
<DIV>Actually, now I am trying to use WINE to port an windows application to linux.</DIV>
<DIV>But if I use program loader provided by WINE to directly run the exe file under linux,</DIV>
<DIV>some of the functionalities are involved with IPC between WINE and other local</DIV>
<DIV>X processes, which is not supported by WINE.</DIV>
<DIV> </DIV>
<DIV>So, I need to rewrite the local codes for them, as Mike explained before,</DIV>
<DIV> </DIV>
<DIV>"What you can do is rewrite only the parts that need rewriting and turn<BR>them into shared libraries. Then you can use WineLib to combine the<BR>Win32 code and the Linux code into one program."</DIV>
<DIV> </DIV>
<DIV>Here, I am glad to learn from you there seems a more easy way:</DIV>
<DIV>(As my understanding, the other way you mentioned is the same one as Mike's)</DIV>
<DIV><BR>"An easy way is to put this <BR>X functionality in a winelib dll. This dll can then be used by your app. The <BR>advantage of a winelib dll is that it can use win32 api's but also native <BR>Linux api's."</DIV>
<DIV> </DIV>
<DIV>Could you please make sure whether this method can meet the need to "find any process's window info", not only "windows under WINE" ?</DIV>
<DIV> </DIV>
<DIV>And could you please give some more implementation details about that?</DIV>
<DIV> </DIV>
<DIV>Thanks a lot!</DIV>
<DIV> </DIV>
<DIV>-Lechun</DIV>
<DIV><BR><B><I>Roderick Colenbrander <thunderbird2k@gmx.net></I></B> wrote:</DIV>
<DIV>
<BLOCKQUOTE style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #1010ff 2px solid; WIDTH: 100%">Hi,<BR><BR>As I understand it you have a Windows app that needs to have access to some X <BR>stuff. To access that you somehow need to extend your app with some X <BR>functionality. There are several ways to do that. An easy way is to put this <BR>X functionality in a winelib dll. This dll can then be used by your app. The <BR>advantage of a winelib dll is that it can use win32 api's but also native <BR>Linux api's. The other option is to completely build your app using winelib <BR>and also add the native code. Personally I think the dll is the easiest way.<BR><BR>Roderick<BR><BR>On Thursday 10 July 2003 23:36, dd jj wrote:<BR>> Hello Mike,<BR>><BR>> So as my understanding, even recompile the original windows codes using<BR>> WINELIB will not work, am I correct?<BR>><BR>> Since finding window info under cursor is only one of the functionality in<BR>> this
application, it will be a huge work to rewrite all the codes for X<BR>> window. Is there any Avenue to port such a windows application to Linux?<BR>> Using Visual Mainwin or Win/U is better choices? or any other comments on<BR>> it?<BR>><BR>> Thanks a lot!<BR>><BR>> -Lechun<BR>><BR>> Mike Hearn <MIKE@THEORETIC.COM>wrote:<BR>> Programs run under emulation are only aware of other Wine programs. If<BR>> you want to write an app like that, you'd need to rewrite it for Linux.<BR>><BR>> BTW, you might want to talk to a guy named Bill Haneman (i think that's<BR>> the spelling). He does Gnome accessibility, and i think they have an app<BR>> that can read info about stuff under the mouse cursor.<BR>><BR>> On Thu, 2003-07-10 at 20:41, dd jj wrote:<BR>> > Thank you for response. The following is my further question:<BR>> ><BR>> > Here is my case:<BR>> ><BR>> > Now I am trying to run our own developed application
under wine, the<BR>> > original function of this app is working as a background daemon<BR>> > without GUI who is trying to figure out some window information under<BR>> > the current cursor, such as the window title, class name using<BR>> > GetWindowTitle, GetClassName ... WIN32 API calls.<BR>> ><BR>> > When I run this under WINE, it can't "see" any other Local X<BR>> > application windows such as Xterm, Xclock... which don't run under<BR>> > WINE.<BR>> ><BR>> ><BR>> > I am wondering whether I can recompile the codes to generate a lcoal X<BR>> > application using winelib to solve this problem, or I must write X11<BR>> > based codes?<BR>> ><BR>> > Thanks a lot!<BR>> ><BR>> > -Lechun<BR>> ><BR>> > Mike Hearn wrote:<BR>> > > fixme:class:get_class_ptr reading from class of other<BR>> ><BR>> > process window<BR>> ><BR>> > > 0x2002a<BR>>
> > err:win:WIN_FindWndPtr window 0x2003a belongs to other<BR>> ><BR>> > process<BR>> ><BR>> > Well these two are known problems. I think it's something<BR>> > Alexandre will<BR>> > be working on at some point, inter-process window<BR>> > communication isn't<BR>> > really implemented well in Wine at present.<BR>> ><BR>> > > Also I found other errors when I launch my window appication<BR>> ><BR>> > under<BR>> ><BR>> > > wine:<BR>> > ><BR>> > > err:module:import_dll No implementation for<BR>> ><BR>> > USER32.dll.GetTitleBarInfo<BR>> ><BR>> > > imported from C:\ping\exe\ping.exe, setting to 0xdeadbeef<BR>> > > err:module:import_dll No implementation for<BR>> ><BR>> > USER32.dll.GetMenuBarInfo<BR>> ><BR>> > > imported from C:\ping\exe\ping.exe, setting to 0xdeadbeef<BR>> ><BR>> > Unless the program
actually uses them, this isn't a problem.<BR>> > If it does,<BR>> > the app will crash, at which point we'd need to write those<BR>> > functions or<BR>> > stub them out.<BR>> ><BR>> > thanks -mike<BR>> ><BR>> ><BR>> > ______________________________________________________________________<BR>> > Do you Yahoo!?<BR>> > SBC Yahoo! DSL - Now only $29.95 per month!<BR>><BR>> ---------------------------------<BR>> Do you Yahoo!?<BR>> SBC Yahoo! DSL - Now only $29.95 per month!<BR></BLOCKQUOTE></DIV></DIV><p><hr SIZE=1>
Do you Yahoo!?<br>
<a href="http://pa.yahoo.com/*http://rd.yahoo.com/evt=1207/*http://promo.yahoo.com/sbc/">SBC Yahoo! DSL</a> - Now only $29.95 per month!