http://bugs.winehq.org/show_bug.cgi?id=10643
Summary: WInUAE settings window reappears after being dismissed Product: Wine Version: 0.9.50. Platform: PC OS/Version: Linux Status: UNCONFIRMED Severity: minor Priority: P2 Component: wine-user AssignedTo: wine-bugs@winehq.org ReportedBy: markk@clara.co.uk
Hi,
WinUAE is an open source (GPL) emulator of Amiga computers. After running WinUAE and starting the emulation, pressing F12 brings up the settings window.
When this is dismissed by pressing Reset, Quit, Restart, OK, or Cancel, the window closes and reopens. It should not reopen. That repeats if you press one of those buttons again. If you press Quit, then Cancel a few times after the window closes and reopens, the program does eventually quit.
Steps to demonstrate the problem:
(Typical usage of WinUAE involves obtaining an Amiga ROM image file, however it is possible to use some software without.)
- Download WinUAE 1.4.4 from http://www.winuae.net/. Direct URL for the installer is http://www.winuae.net/files/InstallWinUAE1440.exe - Run the installer. - For an example disk image, you can download e.g. ftp://ftp.coresystems.de/pub/uae/rsi1.adf.gz - Start WinUAE. The settings/configuration window appears. Click the "Floppy drives" entry in the left side of the window, then the "..." button for drive DF0:. Select the rsi1.adf.gz file. - Click Start to start emulation. - Press F12 to bring up the settings window. - Try to dismiss the window by pressing one of the buttons at the bottom.
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #1 from markk@clara.co.uk 2007-12-02 09:30:11 --- I'm running Ubuntu 7.10.
http://bugs.winehq.org/show_bug.cgi?id=10643
Lei Zhang thestig@google.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever Confirmed|0 |1 Keywords| |download, source
--- Comment #2 from Lei Zhang thestig@google.com 2007-12-02 11:41:31 --- same problem here
http://bugs.winehq.org/show_bug.cgi?id=10643
psykotik linux@ikiru.ch changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |linux@ikiru.ch
--- Comment #3 from psykotik linux@ikiru.ch 2008-06-24 08:31:56 --- I experiment same issue with preferences window (called by F12).
Since there is no other amiga emulator but WinUAE (E-Uae is too limited to be called as emulator), hope a fix will be found.
http://bugs.winehq.org/show_bug.cgi?id=10643
Austin English austinenglish@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |amlopezalonso@gmail.com
--- Comment #4 from Austin English austinenglish@gmail.com 2008-08-29 13:26:06 --- *** Bug 12213 has been marked as a duplicate of this bug. ***
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #5 from markk@clara.co.uk 2008-09-03 12:30:40 --- The bug is probably related to Wine's DirectInput implementation. The problem seems to be that when F12 is pressed the WinUAE main window is active. WinUAE then opens its settings window, which makes the main window inactive whilst F12 is still pressed down.
Upon closing the settings window, WinUAE (or Wine DirectInput?) still sees F12 as being pressed down, presumably because the main window never received the key-up event. So WinUAE opens its settings window again.
I have found a workaround to at least allow WinUAE to be used under Wine. Before dismissing the settings window, click in the main window to activate it, then press and release F12. You can then dismiss the settings window and it will not reappear.
http://bugs.winehq.org/show_bug.cgi?id=10643
markk@clara.co.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- URL| |http://www.winuae.net/ Component|user32 |directx-dinput Summary|WInUAE settings window |WinUAE settings window |reappears after being |reappears after being |dismissed |dismissed
--- Comment #6 from markk@clara.co.uk 2008-09-13 09:44:30 --- This problem still occurs with the current Wine 1.1.4. The WinUAE developer reports that:
"Ok, Wine bug seems to be something like this:
- IDirectInputDevice8_GetDeviceData() returns F12 pressed (0x58, state=press) - WinUAE unacquires all DirectInput devices - open GUI - user releases the key - exit GUI - acquire DirectInput devices - IDirectInputDevice8_GetDeviceState() returns keyboard state array with F12 still pressed."
http://bugs.winehq.org/show_bug.cgi?id=10643
Vitaliy Margolen vitaliy@kievinfo.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Component|directx-dinput |winex11.drv
--- Comment #7 from Vitaliy Margolen vitaliy@kievinfo.com 2008-09-20 13:49:07 --- Not dinput problem. It's getting it's event's from x11drv
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #8 from markk@clara.co.uk 2010-04-15 11:55:40 --- WinUAE version 1.5.1 beta 6 and later support a "-rawkeyboard" command-line argument. If you specify that when running WinUAE, it uses a different method (not DirectInput) to read the keyboard.
For me, running WinUAE that way ("wine winuae.exe -rawinput") does not have the "stuck key" problem, and the settings window goes away as it should. Without -rawkeyboard the problem remains.
If someone wants to figure out what the problem with Wine is, maybe examining the source of a recent WinUAE version could help, to see how its keyboard reading differs when -rawkeyboard is used?
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #9 from markk@clara.co.uk 2010-04-15 11:58:42 --- Without specifying -rawinput, the current Wine 1.1.42 still has the keyboard problem.
http://bugs.winehq.org/show_bug.cgi?id=10643
Juan Lang juan_lang@yahoo.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |saverio.pub@inbox.com
--- Comment #10 from Juan Lang juan_lang@yahoo.com 2010-04-15 13:51:03 --- *** Bug 21626 has been marked as a duplicate of this bug. ***
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #11 from markk@clara.co.uk 2010-04-15 15:52:42 --- Sorry, the command-line option is -rawkeyboard not -rawinput!
http://bugs.winehq.org/show_bug.cgi?id=10643
mattsl cody.custard@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |cody.custard@gmail.com
--- Comment #12 from mattsl cody.custard@gmail.com 2011-03-31 17:02:42 CDT --- Same problem confirmed on Mac OS X 10.6.6.
http://bugs.winehq.org/show_bug.cgi?id=10643
Mark K markk@clara.co.uk changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |markk@clara.co.uk
--- Comment #13 from Mark K markk@clara.co.uk 2011-06-03 11:11:04 CDT --- Testing with Wine 1.3.15, this issue is still present.
Also, running WinUAE with -rawkeyboard as mentioned in comment 8 no longer works around the problem for WinUAE version 2.2.0 and later.
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #14 from Mark K markk@clara.co.uk 2011-06-12 08:54:58 CDT --- Created an attachment (id=35110) --> (http://bugs.winehq.org/attachment.cgi?id=35110) Logs for WinUAE keyboard issue
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #15 from Mark K markk@clara.co.uk 2011-06-12 08:56:00 CDT --- WinUAE 2.1.0 (the last version for which -rawkeyboard works around this Wine bug), as well and the most recent version 2.3.2 show 0 rawinput devices in the "winuaebootlog.txt" file.
For WinUAE 2.2.0 and later, "-rawkeyboard" is now the default.
I noticed when testing WinUAE 2.3.2 under Wine 1.3.22, if I tap F12 very briefly, the settings window does not reappear when dismissed. If I press F12 normally the settings window does reappear. Perhaps that behaviour depends on PC speed? If F12 is pressed for a very short time on a slower PC, the key might be released before the settings window is opened, which could avoid the problem.
I have attached an archive containing WinUAE 2.1.0 boot logs with and without the -rawkeyboard option. There are also some Wine logs. I created those using a command like this: WINEDEBUG=+key,+keyboard wine winuae.exe then starting emulation, pressing F12 to bring up the settings window (if necessary clicking in the main window and pressing F12 again), then quitting. Try "diff"ing the files winuae2100_key_keyboard_log.txt and winuae2100_-rawkeyboard_key_keyboard_log.txt to see how the keyboard is accessed differently when -rawkeyboard is used.
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #16 from Mark K markk@clara.co.uk 2011-12-13 10:55:42 CST --- I tested WinUAE 2.3.3 with Wine 1.3.34. This problem is still present.
I'm going to attach two logs made with WINEDEBUG=+key,+keyboard,+dinput. A description of what I did for each log:
key_keyboard_dinput_log_1.txt: - Start WinUAE. Click OK at dialog box then click Start. Emulation window opens. - Tap F12 very briefly. WinUAE Properties window appears. - Click Quit. Program exits.
That is what should happen. The next log was created by pressing and releasing F12 normally.
key_keyboard_dinput_log_3.txt: - Start WinUAE. Click OK at dialog box then click Start. Emulation window opens. - Press and release F12. WinUAE Properties window appears. - Click Okay. Properties window closes and opens. - Click Okay. Properties window closes and opens. - Click Okay. Properties window closes and opens. - Click in the emulation window. Press and release F12. - Click Quit. Program exits.
Doing grep "KeyEvent Key" key_keyboard_dinput_log_3.txt shows two F12 press/releases (which is correct). So the problem probably lies elsewhere.
First key release shown in log starting at line 20233: trace:key:X11DRV_KeyEvent type 3, window 2c0001b, state 0x0000, keycode 96 trace:key:X11DRV_KeyEvent nbyte = 0, status 0 trace:key:X11DRV_KeyEvent KeyRelease : keysym=ffc9 (F12), # of chars=0 / "" trace:key:EVENT_event_to_vkey e->keycode = 96 trace:key:X11DRV_KeyEvent keycode 96 converted to vkey 0x7B trace:key:X11DRV_KeyEvent bScan = 0x58. trace:key:X11DRV_send_keyboard_input hwnd 0x3009a vkey=007b scan=0058 flags=0002
Line 20317: trace:dinput:IDirectInputDevice2WImpl_Unacquire (0x1650c0) trace:dinput:IDirectInputDevice2WImpl_SetCooperativeLevel (0x1650c0) 0x3009a,0x00000015 trace:dinput:_dump_cooperativelevel_DI cooperative level : DISCL_EXCLUSIVE DISCL_FOREGROUND DISCL_NOWINKEY trace:dinput:IDirectInputDevice2WImpl_Acquire (0x1650c0) trace:dinput:hook_thread_proc Processing hook change notification lp:0 trace:dinput:IDirectInputDevice2WImpl_GetDeviceData (0x1333f8) 0x3b7f8a8 -> 0x3b7f884(30) x20, 0x00000000 trace:dinput:IDirectInputDevice2WImpl_GetDeviceData Returning 0 events queued trace:dinput:SysKeyboardWImpl_GetDeviceState (0x1650c0)->(256,0x3b7f5e4) trace:dinput:SysKeyboardWImpl_GetDeviceState - 58: 80 ... trace:dinput:fill_DataFormat Copying (c) to 88 from 88 (value -128) ... Line 20720: trace:dinput:IDirectInputDevice2WImpl_Unacquire (0x1650c0) trace:dinput:IDirectInputDevice2WImpl_SetCooperativeLevel (0x1650c0) 0x3009a,0x00000015 trace:dinput:_dump_cooperativelevel_DI cooperative level : DISCL_EXCLUSIVE DISCL_FOREGROUND DISCL_NOWINKEY trace:dinput:IDirectInputDevice2WImpl_Acquire (0x1650c0) trace:dinput:hook_thread_proc Processing hook change notification lp:0 trace:dinput:IDirectInputDevice2WImpl_GetDeviceData (0x1333f8) 0x3b7f8a8 -> 0x3b7f884(30) x20, 0x00000000 trace:dinput:IDirectInputDevice2WImpl_GetDeviceData Returning 0 events queued trace:dinput:SysKeyboardWImpl_GetDeviceState (0x1650c0)->(256,0x3b7f5e4) trace:dinput:SysKeyboardWImpl_GetDeviceState - 58: 80 ... trace:dinput:fill_DataFormat Copying (c) to 88 from 88 (value -128) ... Line 21118: trace:dinput:IDirectInputDevice2WImpl_Unacquire (0x1650c0) trace:dinput:IDirectInputDevice2WImpl_SetCooperativeLevel (0x1650c0) 0x3009a,0x00000015 trace:dinput:_dump_cooperativelevel_DI cooperative level : DISCL_EXCLUSIVE DISCL_FOREGROUND DISCL_NOWINKEY trace:dinput:IDirectInputDevice2WImpl_Acquire (0x1650c0) trace:dinput:hook_thread_proc Processing hook change notification lp:0 trace:dinput:IDirectInputDevice2WImpl_GetDeviceData (0x1333f8) 0x3b7f8a8 -> 0x3b7f884(30) x20, 0x00000000 trace:dinput:IDirectInputDevice2WImpl_GetDeviceData Returning 0 events queued trace:dinput:SysKeyboardWImpl_GetDeviceState (0x1650c0)->(256,0x3b7f5e4) trace:dinput:SysKeyboardWImpl_GetDeviceState - 58: 80 ... trace:dinput:fill_DataFormat Copying (c) to 88 from 88 (value -128) ...
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #17 from Mark K markk@clara.co.uk 2011-12-13 10:56:36 CST --- Created attachment 37957 --> http://bugs.winehq.org/attachment.cgi?id=37957 key_keyboard_dinput_log_1.txt
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #18 from Mark K markk@clara.co.uk 2011-12-13 10:56:56 CST --- Created attachment 37958 --> http://bugs.winehq.org/attachment.cgi?id=37958 key_keyboard_dinput_log_3.txt.bz2
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #19 from Mark K markk@clara.co.uk 2011-12-14 13:19:04 CST --- The WinUAE developer said:
"... but perhaps this is the problem:
DInputKeyState is only changed in KeyboardCallback(). GetDeviceState() only uses DInputKeyState.
KeyboardCallback() is only called (and DInputKeyState updated) when device is acquired. This is only my guess but it would cause this problem."
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #20 from Mark K markk@clara.co.uk 2012-02-20 11:35:09 CST --- If it helps encourage someone to investigate this bug, I'll offer US$50 (or equivalent) once a fix goes into Wine.
http://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #21 from Mark K markk@clara.co.uk 2012-10-30 12:12:06 CDT --- As of Wine 1.5.16, support for raw input is implemented sufficiently for recent WinUAE versions (I tested 2.4.1) to use it. WinUAE uses raw input if available.
Under Wine 1.5.16, the reappearing settings window issue doesn't happen. However this bug is still present (presumably related to DirectInput which WinUAE no longer uses by default): if you run WinUAE with the -norawinput option, the bug shows up as before.
https://bugs.winehq.org/show_bug.cgi?id=10643
Béla Gyebrószki gyebro69@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |gyebro69@gmail.com
--- Comment #22 from Béla Gyebrószki gyebro69@gmail.com --- Should be fixed by http://source.winehq.org/git/wine.git/commitdiff/0d91274defcf65093957cf8e439...
Tested with WinUAE 2.4.0. To test this bug I started the app like this: wine winuae.exe -norawinput
Fedora 21 XOrg 1.16.3 XFCE 4.10
InstallWinUAE2400.exe sha1: 8995ce01923145678aae82332a4723ef2994cc23
https://bugs.winehq.org/show_bug.cgi?id=10643
super_man@post.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |super_man@post.com
--- Comment #23 from super_man@post.com --- Restart seems to bring that menu, but other options I tried seem to close it.
wine 1.7.49(git)
https://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #24 from super_man@post.com --- I tried same version as Béla for testng.
https://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #25 from Nikolay Sivov bunglehead@gmail.com --- Hi, Mark.
Could you retest with current wine? I'm unable to download image from bug description.
https://bugs.winehq.org/show_bug.cgi?id=10643
--- Comment #26 from Mark K markk@clara.co.uk --- Testing with Wine 1.9.15, WinUAE 2.3.3 and 2.4.0 with -norawinput command-line argument, this issue seems to be fixed.
You don't actually need an example disk image for testing, just clicking Start then after a while pressing F12 should work. But you could try ftp://ftp.amigascne.org/pub/amiga/Groups/R/Red_Sector/RSI-MegademoA.dms
https://bugs.winehq.org/show_bug.cgi?id=10643
Frédéric Delanoy frederic.delanoy@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |frederic.delanoy@gmail.com Status|NEW |RESOLVED Resolution|--- |FIXED
--- Comment #27 from Frédéric Delanoy frederic.delanoy@gmail.com --- Seems fixed in wine-1.9.18-121-g4e9cc30
https://bugs.winehq.org/show_bug.cgi?id=10643
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #28 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 1.9.19.