- Aug 01, 2022
-
-
Thomas Huth authored
Some files wrongly contain the same word twice in a row. One of them should be removed or replaced. Message-Id: <20220722145859.1952732-1-thuth@redhat.com> Signed-off-by:
Thomas Huth <thuth@redhat.com>
-
- Jul 28, 2022
-
-
Paolo Bonzini authored
Without CONFIG_GBM, compiling dbus-display fails with ../ui/dbus.c: In function ‘dbus_create_context’: ../ui/dbus.c:47:20: error: ‘qemu_egl_rn_ctx’ undeclared (first use in this function); did you mean ‘qemu_egl_init_ctx’? 47 | qemu_egl_rn_ctx); | ^~~~~~~~~~~~~~~ | qemu_egl_init_ctx ../ui/dbus.c:47:20: note: each undeclared identifier is reported only once for each function it appears in and many other similar errors, because include/ui/egl-helpers.h only has these declaration if gbm is found on the system. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1108 Reviewed-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by:
Daniel P. Berrangé <berrange@redhat.com> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>
-
- Jul 19, 2022
-
-
Felix xq Queißner authored
The patch adds "show_tabs" command line option for GTK ui similar to "grab_on_hover". This option allows tabbed view mode to not have to be enabled by hand at each start of the VM. Signed-off-by:
Felix "xq" Queißner <xq@random-projects.net> Reviewed-by:
Thomas Huth <thuth@redhat.com> Reviewed-by:
Hanna Reitz <hreitz@redhat.com> Message-Id: <20220712133753.18937-1-xq@random-projects.net> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
Marc-André Lureau authored
The D-Bus connection starts processing messages before QEMU has the time to set the object manager server. This is causing dbus-display-test to fail randomly with: ERROR:../tests/qtest/dbus-display-test.c:68:test_dbus_display_vm: assertion failed (qemu_dbus_display1_vm_get_name(QEMU_DBUS_DISPLAY1_VM(vm)) == "dbus-test"): (NULL == "dbus-test") ERROR Use the delayed message processing flag and method to avoid that situation. (the bus connection doesn't need a fix, as the initialization is done synchronously) Reported-by:
Robinson, Cole <crobinso@redhat.com> Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Tested-by:
Cole Robinson <crobinso@redhat.com> Message-Id: <20220609152647.870373-1-marcandre.lureau@redhat.com> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
- Jul 12, 2022
-
-
Akihiko Odaki authored
Retrieve the refresh rate of the display and reflect it with dpy_set_ui_info() and update_displaychangelistener(), allowing the guest and DisplayChangeListener to consume the information. The information will be used as a hint how often the display should be updated. For example, when we run 30 Hz physical display updates it is pointless for the guest to update the screen at 60Hz frequency, the guest can spare some work instead. Signed-off-by:
Akihiko Odaki <akihiko.odaki@gmail.com> Reviewed-by:
Peter Maydell <peter.maydell@linaro.org> Message-Id: <20220702142519.12188-1-akihiko.odaki@gmail.com> Signed-off-by:
Philippe Mathieu-Daudé <f4bug@amsat.org>
-
Peter Delevoryas authored
I noticed this error while building QEMU on Mac OS X: [1040/1660] Compiling Objective-C object libcommon.fa.p/ui_cocoa.m.o ../ui/cocoa.m:803:17: warning: variable 'switched_to_fullscreen' set but not used [-Wunused-but-set-variable] static bool switched_to_fullscreen = false; ^ 1 warning generated. I think the behavior is fine if you remove "switched_to_fullscreen", I can still switch in and out of mouse grabbed mode and fullscreen mode with this change, and Command keycodes will only be passed to the guest if the mouse is grabbed, which I think is the right behavior. I'm not sure why a static piece of state was needed to handle that in the first place. Perhaps the refactoring of the flags-state-change fixed that by toggling the Command keycode on. I tested this with an Ubuntu core image on macOS 12.4 wget https://cdimage.ubuntu.com/ubuntu-core/18/stable/current/ubuntu-core-18-i386.img.xz xz -d ubuntu-core-18-i386.img.xz qemu-system-x86_64 -drive file=ubuntu-core-18.i386.img,format=raw Fixes: 6d73bb64 ("ui/cocoa: Clear modifiers whenever possible") Signed-off-by:
Peter Delevoryas <peter@pjd.dev> Reviewed-by:
Akihiko Odaki <akihiko.odaki@gmail.com> Signed-off-by:
Philippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20220702044304.90553-1-peter@pjd.dev> Signed-off-by:
Philippe Mathieu-Daudé <f4bug@amsat.org>
-
- Jul 01, 2022
-
-
Akihiko Odaki authored
[-NSPasteboard dataForType:] returns an autoreleased NSString, and callings its release method will result in double-free when the global autorelease pool is released. Use NSAutoreleasePool to release it properly. Signed-off-by:
Akihiko Odaki <akihiko.odaki@gmail.com> Reviewed-by:
Peter Maydell <peter.maydell@linaro.org> Message-Id: <20220614212131.94696-1-akihiko.odaki@gmail.com> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
Wen, Jianxian authored
The update makes it easier to find and specify devices. They can only be found by device type name without the id field, for example, devices of the same type have the same label. The update also adds a head field, which is useful for devices that support multiple heads, such as virtio-gpu. Signed-off-by:
Jianxian Wen <jianxian.wen@verisilicon.com> Signed-off-by:
Lu Gao <lu.gao@verisilicon.com> Message-Id: <4C23C17B8E87E74E906A25A3254A03F4018FC045B0@SHASXM06.verisilicon.com> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
- Jun 28, 2022
-
-
Dr. David Alan Gilbert authored
Inspired by Julia Lawall's fixing of Linux kernel comments, I looked at qemu, although I did it manually. Signed-off-by:
Dr. David Alan Gilbert <dgilbert@redhat.com> Reviewed-by:
Daniel Henrique Barboza <danielhb413@gmail.com> Reviewed-by:
Klaus Jensen <k.jensen@samsung.com> Message-Id: <20220614104045.85728-2-dgilbert@redhat.com> Signed-off-by:
Laurent Vivier <laurent@vivier.eu>
-
- Jun 14, 2022
-
-
Akihiko Odaki authored
This change adds a new member, refresh_rate to QemuUIInfo in include/ui/console.h. It represents the refresh rate of the physical display backend, and it is more appropriate than GUI update interval as the refresh rate which the emulated device reports: - sdl may set GUI update interval shorter than the refresh rate of the physical display to respond to user-generated events. - sdl and vnc aggressively changes GUI update interval, but a guests is typically not designed to respond to frequent refresh rate changes, or frequent "display mode" changes in general. The frequency of refresh rate changes of the physical display backend matches better to the guest's expectation. QemuUIInfo also has other members representing "display mode", which makes it suitable for refresh rate representation. It has a throttling of update notifications, and prevents frequent changes of the display mode. Signed-off-by:
Akihiko Odaki <akihiko.odaki@gmail.com> Message-Id: <20220226115516.59830-3-akihiko.odaki@gmail.com> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
Akihiko Odaki authored
Signed-off-by:
Akihiko Odaki <akihiko.odaki@gmail.com> Reviewed-by:
Philippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20220529082508.89097-1-akihiko.odaki@gmail.com> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
Volker Rümelin authored
Since about 2018 virglrenderer (commit fa835b0f88 "vrend: don't hardcode context version") tries to open the highest available GL context version. This is done by creating the known GL context versions from the highest to the lowest until (*create_gl_context) returns a context != NULL. This does not work properly with the current QEMU gd_gl_area_create_context() function, because gdk_gl_context_realize() on Wayland creates a version 3.0 legacy context if the requested GL context version can't be created. In order for virglrenderer to find the highest available GL context version, return NULL if the created context version is lower than the requested version. This fixes the following error: QEMU started with -device virtio-vga-gl -display gtk,gl=on. Under Wayland, the guest window remains black and the following information can be seen on the host. gl_version 30 - compat profile (qemu:5978): Gdk-WARNING **: 16:19:01.533: gdk_gl_context_set_required_version - GL context versions less than 3.2 are not supported. (qemu:5978): Gdk-WARNING **: 16:19:01.537: gdk_gl_context_set_required_version - GL context versions less than 3.2 are not supported. (qemu:5978): Gdk-WARNING **: 16:19:01.554: gdk_gl_context_set_required_version - GL context versions less than 3.2 are not supported. vrend_renderer_fill_caps: Entering with stale GL error: 1282 To reproduce this error, an OpenGL driver is required on the host that doesn't have the latest OpenGL extensions fully implemented. An example for this is the Intel i965 driver on a Haswell processor. Signed-off-by:
Volker Rümelin <vr_qemu@t-online.de> Message-Id: <20220605085131.7711-2-vr_qemu@t-online.de> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
Volker Rümelin authored
The counterpart function for gd_gl_area_create_context() is currently empty. Implement the gd_gl_area_destroy_context() function to avoid GL context leaks. Signed-off-by:
Volker Rümelin <vr_qemu@t-online.de> Message-Id: <20220605085131.7711-1-vr_qemu@t-online.de> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
- Jun 03, 2022
-
-
Thomas Huth authored
The "-display sdl" option still uses a hand-crafted parser for its parameters since we didn't want to drag an interface we considered somewhat flawed into the QAPI schema. Since the flaws are gone now, it's time to QAPIfy. This introduces the new "DisplaySDL" QAPI struct that is used to hold the parameters that are unique to the SDL display. The only specific parameter is currently "grab-mod" that is used to specify the required modifier keys to escape from the mouse grabbing mode. Message-Id: <20220519155625.1414365-3-thuth@redhat.com> Reviewed-by:
Markus Armbruster <armbru@redhat.com> Signed-off-by:
Thomas Huth <thuth@redhat.com>
-
- May 12, 2022
-
-
Kshitij Suri authored
Currently png support is dependent on vnc for linking object file to libpng. This commit makes the parameter independent of vnc as it breaks system emulator with --disable-vnc unless --disable-png is added. Fixes: 9a0a119a ("Added parameter to take screenshot with screendump as PNG", 2022-04-27) Signed-off-by:
Kshitij Suri <kshitij.suri@nutanix.com> Message-Id: <20220510161932.228481-1-kshitij.suri@nutanix.com> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>
-
Paolo Bonzini authored
Because qemu_co_queue_restart_all does not release the lock, it should be used only in coroutine context. Introduce a new function that, like qemu_co_enter_next, does release the lock, and use it whenever qemu_co_queue_restart_all was used outside coroutine context. Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com> Reviewed-by:
Eric Blake <eblake@redhat.com> Message-Id: <20220427130830.150180-3-pbonzini@redhat.com> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>
-
- May 11, 2022
-
-
Markus Armbruster authored
Leading underscores are ill-advised because such identifiers are reserved. Trailing underscores are merely ugly. Strip both. Our header guards commonly end in _H. Normalize the exceptions. Macros should be ALL_CAPS. Normalize the exception. Done with scripts/clean-header-guards.pl. include/hw/xen/interface/ and tools/virtiofsd/ left alone, because these were imported from Xen and libfuse respectively. Signed-off-by:
Markus Armbruster <armbru@redhat.com> Message-Id: <20220506134911.2856099-3-armbru@redhat.com> Reviewed-by:
Richard Henderson <richard.henderson@linaro.org>
-
- May 03, 2022
-
-
Marc-André Lureau authored
The call is POSIX-specific. Use the dedicated GLib API. (this is a preliminary patch before renaming qemu_set_nonblock()) Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by:
Daniel P. Berrangé <berrange@redhat.com>
-
- Apr 28, 2022
-
-
Paolo Bonzini authored
Reviewed-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>
-
Paolo Bonzini authored
Reviewed-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>
-
- Apr 27, 2022
-
-
Vladimir Sementsov-Ogievskiy authored
Add possibility to change addresses where VNC server listens for new connections. Prior to 6.0 this functionality was available through 'change' qmp command which was deleted. Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@openvz.org> Reviewed-by:
Daniel P. Berrangé <berrange@redhat.com> Message-Id: <20220401143936.356460-3-vsementsov@openvz.org> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
Vladimir Sementsov-Ogievskiy authored
Let's use SocketAddressList instead of dynamic arrays. Benefits: - Automatic cleanup: don't need specific freeing function and drop some gotos. - Less indirection: no triple asterix anymore! - Prepare for the following commit, which will reuse new interface of vnc_display_listen(). Signed-off-by:
Vladimir Sementsov-Ogievskiy <vsementsov@openvz.org> Reviewed-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by:
Daniel P. Berrangé <berrange@redhat.com> Message-Id: <20220401143936.356460-2-vsementsov@openvz.org> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
Kshitij Suri authored
Currently screendump only supports PPM format, which is un-compressed. Added a "format" parameter to QMP and HMP screendump command to support PNG image capture using libpng. QMP example usage: { "execute": "screendump", "arguments": { "filename": "/tmp/image", "format":"png" } } HMP example usage: screendump /tmp/image -f png Resolves: https://gitlab.com/qemu-project/qemu/-/issues/718 Signed-off-by:
Kshitij Suri <kshitij.suri@nutanix.com> Reviewed-by:
Daniel P. Berrangé <berrange@redhat.com> Acked-by:
Markus Armbruster <armbru@redhat.com> Acked-by:
Dr. David Alan Gilbert <dgilbert@redhat.com> Message-Id: <20220408071336.99839-3-kshitij.suri@nutanix.com> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
Kshitij Suri authored
Libpng is only detected if VNC is enabled currently. This patch adds a generalised png option in the meson build which is aimed to replace use of CONFIG_VNC_PNG with CONFIG_PNG. Signed-off-by:
Kshitij Suri <kshitij.suri@nutanix.com> Reviewed-by:
Daniel P. Berrangé <berrange@redhat.com> Message-Id: <20220408071336.99839-2-kshitij.suri@nutanix.com> [ kraxel: add meson-buildoptions.sh updates ] [ kraxel: fix centos8 testcase ] [ kraxel: update --enable-vnc-png too ] Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com> --enable-vnc-png fixup Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
- Apr 26, 2022
-
-
Daniel P. Berrangé authored
Users requiring FIPS support must build QEMU with either the libgcrypt or gnutls libraries as the crytography backend. Reviewed-by:
Philippe Mathieu-Daudé <f4bug@amsat.org> Signed-off-by:
Daniel P. Berrangé <berrange@redhat.com>
-
- Apr 25, 2022
-
-
Denis V. Lunev authored
'blockdev-change-medium' is a convinient wrapper for the following sequence of commands: * blockdev-open-tray * blockdev-remove-medium * blockdev-insert-medium * blockdev-close-tray and should be used f.e. to change ISO image inside the CD-ROM tray. Though the guest could lock the tray and some linux guests like CentOS 8.5 actually does that. In this case the execution if this command results in the error like the following: Device 'scsi0-0-1-0' is locked and force was not specified, wait for tray to open and try again. This situation is could be resolved 'blockdev-open-tray' by passing flag 'force' inside. Thus is seems reasonable to add the same capability for 'blockdev-change-medium' too. Signed-off-by:
Denis V. Lunev <den@openvz.org> Reviewed-by:
Vladimir Sementsov-Ogievskiy <vsementsov@openvz.org> Acked-by:
"Dr. David Alan Gilbert" <dgilbert@redhat.com> CC: Kevin Wolf <kwolf@redhat.com> CC: Hanna Reitz <hreitz@redhat.com> CC: Eric Blake <eblake@redhat.com> CC: Markus Armbruster <armbru@redhat.com> Message-Id: <20220412221846.280723-1-den@openvz.org> Reviewed-by:
Daniel P. Berrangé <berrange@redhat.com> Signed-off-by:
Hanna Reitz <hreitz@redhat.com>
-
- Apr 21, 2022
-
-
Marc-André Lureau authored
Since it depends on monitor code, and error_vprintf_unless_qmp() is already there. This will help to move error-report in a common subproject. Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by:
Daniel P. Berrangé <berrange@redhat.com> Message-Id: <20220420132624.2439741-31-marcandre.lureau@redhat.com>
-
Marc-André Lureau authored
Suggested-by:
Peter Maydell <peter.maydell@linaro.org> Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by:
Warner Losh <imp@bsdimp.com> Message-Id: <20220420132624.2439741-7-marcandre.lureau@redhat.com>
-
Marc-André Lureau authored
Move qemu_main() declaration to a new header. Simplify main.c since both cocoa & sdl cannot be enabled together. Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by:
Akihiko Odaki <akihiko.odaki@gmail.com> Reviewed-by:
Daniel P. Berrangé <berrange@redhat.com> Message-Id: <20220420132624.2439741-5-marcandre.lureau@redhat.com>
-
- Apr 07, 2022
-
-
Mauro Matteo Cascella authored
Prevent potential integer overflow by limiting 'width' and 'height' to 512x512. Also change 'datasize' type to size_t. Refer to security advisory https://starlabs.sg/advisories/22-4206/ for more information. Fixes: CVE-2021-4206 Signed-off-by:
Mauro Matteo Cascella <mcascell@redhat.com> Reviewed-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20220407081712.345609-1-mcascell@redhat.com> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
- Apr 06, 2022
-
-
Marc-André Lureau authored
Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20220323155743.1585078-33-marcandre.lureau@redhat.com> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>
-
Marc-André Lureau authored
Replace a config-time define with a compile time condition define (compatible with clang and gcc) that must be declared prior to its usage. This avoids having a global configure time define, but also prevents from bad usage, if the config header wasn't included before. This can help to make some code independent from qemu too. gcc supports __BYTE_ORDER__ from about 4.6 and clang from 3.2. Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> [ For the s390x parts I'm involved in ] Acked-by:
Halil Pasic <pasic@linux.ibm.com> Reviewed-by:
Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by:
Richard Henderson <richard.henderson@linaro.org> Message-Id: <20220323155743.1585078-7-marcandre.lureau@redhat.com> Signed-off-by:
Paolo Bonzini <pbonzini@redhat.com>
-
- Mar 28, 2022
-
-
Akihiko Odaki authored
Without this change, The GL output of a console overwrites the other consoles and makes them unusable. Signed-off-by:
Akihiko Odaki <akihiko.odaki@gmail.com> Reviewed-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by:
Philippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20220325161216.74582-1-akihiko.odaki@gmail.com> Signed-off-by:
Philippe Mathieu-Daudé <f4bug@amsat.org>
-
Akihiko Odaki authored
Signed-off-by:
Akihiko Odaki <akihiko.odaki@gmail.com> Fixes: 4797adce ("ui/cocoa: add option to swap Option and Command") Reviewed-by:
Philippe Mathieu-Daudé <f4bug@amsat.org> Message-Id: <20220317152949.68666-1-akihiko.odaki@gmail.com> Signed-off-by:
Philippe Mathieu-Daudé <f4bug@amsat.org>
-
- Mar 21, 2022
-
-
Markus Armbruster authored
g_new(T, n) is neater than g_malloc(sizeof(T) * n). It's also safer, for two reasons. One, it catches multiplication overflowing size_t. Two, it returns T * rather than void *, which lets the compiler catch more type errors. This commit only touches allocations with size arguments of the form sizeof(T). Patch created mechanically with: $ spatch --in-place --sp-file scripts/coccinelle/use-g_new-etc.cocci \ --macro-file scripts/cocci-macro-file.h FILES... Signed-off-by:
Markus Armbruster <armbru@redhat.com> Reviewed-by:
Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by:
Cédric Le Goater <clg@kaod.org> Reviewed-by:
Alex Bennée <alex.bennee@linaro.org> Acked-by:
Dr. David Alan Gilbert <dgilbert@redhat.com> Message-Id: <20220315144156.1595462-4-armbru@redhat.com> Reviewed-by:
Pavel Dovgalyuk <Pavel.Dovgalyuk@ispras.ru>
-
- Mar 18, 2022
-
-
Wen, Jianxian authored
Check the dirty bits in advance to avoid unnecessary memory operations. In the case that guest surface has different format than the server, but it does not have dirty bits which means no refresh is actually needed, the memory operations is not necessary. Signed-off-by:
Jianxian Wen <jianxian.wen@verisilicon.com> Signed-off-by:
Lu Gao <lu.gao@verisilicon.com> Reviewed-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <4C23C17B8E87E74E906A25A3254A03F4FA22100C@SHASXM06.verisilicon.com> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
K. Lange authored
GTK already produces corresponding GDK_BUTTON_PRESS events alongside 2BUTTON and 3BUTTON_PRESS events. The 2BUTTON and 3BUTTON_PRESS events were incorrectly being interpreted and passed to guests as button release events. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/558 Signed-off-by:
K. Lange <klange@toaruos.org> Message-Id: <20220305104521.3583703-1-klange@toaruos.org> Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com>
-
- Mar 15, 2022
-
-
Gustavo Noronha Silva authored
On Mac OS X the Option key maps to Alt and Command to Super/Meta. This change swaps them around so that Alt is the key closer to the space bar and Meta/Super is between Control and Alt, like on non-Mac keyboards. It is a cocoa display option, disabled by default. Acked-by:
Markus Armbruster <armbru@redhat.com> Signed-off-by:
Gustavo Noronha Silva <gustavo@noronha.dev.br> Message-Id: <20210713213200.2547-3-gustavo@noronha.dev.br> Signed-off-by:
Akihiko Odaki <akihiko.odaki@gmail.com> Message-Id: <20220306121119.45631-3-akihiko.odaki@gmail.com> Reviewed-by:
Will Cohen <wwcohen@gmail.com> Signed-off-by:
Philippe Mathieu-Daudé <f4bug@amsat.org>
-
Gustavo Noronha Silva authored
Applications such as Gnome may use Alt-Tab and Super-Tab for different purposes, some use Ctrl-arrows so we want to allow qemu to handle everything when it captures the mouse/keyboard. However, Mac OS handles some combos like Command-Tab and Ctrl-arrows at an earlier part of the event handling chain, not letting qemu see it. We add a global Event Tap that allows qemu to see all events when the mouse is grabbed. Note that this requires additional permissions. See: https://developer.apple.com/documentation/coregraphics/1454426-cgeventtapcreate?language=objc#discussion https://support.apple.com/en-in/guide/mac-help/mh32356/mac Acked-by:
Markus Armbruster <armbru@redhat.com> Signed-off-by:
Gustavo Noronha Silva <gustavo@noronha.dev.br> Message-Id: <20210713213200.2547-2-gustavo@noronha.dev.br> Signed-off-by:
Akihiko Odaki <akihiko.odaki@gmail.com> Message-Id: <20220306121119.45631-2-akihiko.odaki@gmail.com> Reviewed-by:
Will Cohen <wwcohen@gmail.com> Signed-off-by:
Philippe Mathieu-Daudé <f4bug@amsat.org>
-
Carwyn Ellis authored
This resolves an issue where using command-tab to switch between QEMU and other windows on the host can leave the mouse pointer visible. By releasing the mouse when the user switches away, the user must left click on the QEMU window when switching back in order to hide the pointer and return control to the guest. This appraoch ensures that the calls to NSCursor hide and unhide are always balanced and thus work correctly when invoked. Signed-off-by:
Carwyn Ellis <carwynellis@gmail.com> Reviewed-by:
Akihiko Odaki <akihiko.odaki@gmail.com> Signed-off-by:
Philippe Mathieu-Daudé <f4bug@amsat.org>
-