[Bug 28154] AutoIt v3.x 'Inputbox' function fails to display dialog with edit field (MonitorFromRect called with rect {Left=0,Top=0,Right=-1,Bottom=-1})

wine-bugs at winehq.org wine-bugs at winehq.org
Sun Dec 29 14:48:14 CST 2013


http://bugs.winehq.org/show_bug.cgi?id=28154

Anastasius Focht <focht at gmx.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |download
             Status|UNCONFIRMED                 |NEW
                URL|                            |http://www.autoitscript.com
                   |                            |/site/autoit/downloads/
                 CC|                            |focht at gmx.net
            Summary|AutoIt - InputBox           |AutoIt v3.x 'Inputbox'
                   |                            |function fails to display
                   |                            |dialog with edit field
                   |                            |(MonitorFromRect called
                   |                            |with rect
                   |                            |{Left=0,Top=0,Right=-1,Bott
                   |                            |om=-1})
     Ever confirmed|0                           |1

--- Comment #4 from Anastasius Focht <focht at gmx.net> ---
Hello folks,

confirming.

Reference for AutoIt 'InputBox' function:
http://www.autoitscript.com/autoit3/docs/functions/InputBox.htm

Relevant part of trace log:

--- snip ---
$ pwd
/home/focht/.wine/drive_c/Program Files/AutoIt3

$ WINEDEBUG=+tid,+seh,+relay,+win wine ./AutoIt3.exe test.au3 >>log.txt 2>&1
...
002a:Call KERNEL32.MultiByteToWideChar(00000000,00000001,00147938
"InputBox(\"meh\", \"meh\")",00000017,00147970,00000017) ret=004073e5
002a:Ret  KERNEL32.MultiByteToWideChar() retval=00000017 ret=004073e5 
...
002a:Call user32.CreateWindowExW(00000000,0049faa8 L"AutoIt v3",0049faa8
L"AutoIt
v3",00cf0000,80000000,80000000,0000012c,00000064,00000000,00000000,00400000,00000000)
ret=00403903 
...
002a:Ret  user32.CreateWindowExW() retval=00020074 ret=00403903
002a:Call user32.CreateWindowExW(00000000,0049fabc
L"edit",00000000,50b008c4,00000000,00000000,00000000,00000000,00020074,00000001,00400000,00000000)
ret=00403924
002a:trace:win:WIN_CreateWindowEx (null) L"edit" ex=00000000 style=50b008c4 0,0
0x0 parent=0x20074 menu=0x1 inst=0x400000 params=(nil)
002a:trace:win:dump_window_styles style: WS_CHILD WS_VISIBLE WS_BORDER
WS_VSCROLL WS_HSCROLL 000008c4
002a:trace:win:dump_window_styles exstyle:
002a:trace:win:WIN_SetWindowLong 0x1007c -12 1 W 
...
002a:trace:win:WIN_CreateWindowEx created window 0x1007c
002a:Ret  user32.CreateWindowExW() retval=0001007c ret=00403924
002a:Call user32.ShowWindow(00020074,00000000) ret=00403938
002a:trace:win:show_window hwnd=0x20074, cmd=0, wasVisible 0
002a:Ret  user32.ShowWindow() retval=00000000 ret=00403938
002a:Call user32.ShowWindow(00020074,00000000) ret=00403941
002a:trace:win:show_window hwnd=0x20074, cmd=0, wasVisible 0
002a:Ret  user32.ShowWindow() retval=00000000 ret=00403941 
...
002a:Call user32.MonitorFromRect(008ef744,00000000) ret=0044898c
002a:Call winex11.drv.EnumDisplayMonitors(00000000,00000000,7eb36a40,008ef6a4)
ret=7eb370d1
002a:Call winex11.drv.GetMonitorInfo(00000001,008ef524) ret=7eb37001
002a:Ret  winex11.drv.GetMonitorInfo() retval=00000001 ret=7eb37001
002a:trace:win:GetMonitorInfoW flags 0001, monitor (0,0)-(800,600), work
(0,0)-(800,600)
002a:Ret  winex11.drv.EnumDisplayMonitors() retval=00000001 ret=7eb370d1
002a:trace:win:MonitorFromRect (0,0)-(-1,-1) flags 0 returning (nil)
002a:Ret  user32.MonitorFromRect() retval=00000000 ret=0044898c 
...
002a:Call user32.LockWindowUpdate(00000000) ret=0040fd9f
002a:fixme:win:LockWindowUpdate ((nil)), partial stub!
002a:Ret  user32.LockWindowUpdate() retval=00000001 ret=0040fd9f
002a:Call user32.DestroyWindow(00020074) ret=0040fdab
002a:trace:win:DestroyWindow (0x20074)
002a:Call window proc 0x4033b3
(hwnd=0x20074,msg=WM_DESTROY,wp=00000000,lp=00000000) 
...
002a:Call winmm.mciSendStringW(004b0ea4 L"close
all",00000000,00000000,00000000) ret=004051fc 
...
002a:Call KERNEL32.ExitProcess(00000000) ret=00422dca 
--- snip ---

The application code calls 'MonitorFromRect( &rect, MONITOR_DEFAULTTONULL)'

Input 'rect' is hard-coded to { Left=0, Top=0, Right=-1, Bottom=-1 }

I used virtual desktop mode with 800x600 resolution hence Wine has monitor rect
(0,0)-(800,600).

The app terminates itself because MonitorFromRect() -> winex11_drv ->
X11DRV_EnumDisplayMonitors() treats this as no intersection, returning NULL
HMONITOR.

$ sha1sum autoit-v3-setup.exe
ba7499fe9fb55438348ac013109febfc12c73437  autoit-v3-setup.exe

$ du -sh autoit-v3-setup.exe
11M    autoit-v3-setup.exe

$ wine --version
wine-1.7.9-209-gb231b4b

Regards

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list