From nobody Fri Apr 26 05:01:42 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.120 as permitted sender) client-ip=207.211.31.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [207.211.31.120]) by mx.zohomail.com with SMTPS id 1581524340012114.2200725881928; Wed, 12 Feb 2020 08:19:00 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-365-hXCjPzXsN6Gdoxxy3keMIQ-1; Wed, 12 Feb 2020 11:18:55 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id E222518CA243; Wed, 12 Feb 2020 16:18:49 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 2017B61069; Wed, 12 Feb 2020 16:18:49 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 28618866C1; Wed, 12 Feb 2020 16:18:44 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01CGIhb5030123 for ; Wed, 12 Feb 2020 11:18:43 -0500 Received: by smtp.corp.redhat.com (Postfix) id 7AD5F5C54A; Wed, 12 Feb 2020 16:18:43 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-117-39.ams2.redhat.com [10.36.117.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id A5E9E5C240; Wed, 12 Feb 2020 16:18:36 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id D11669D1F; Wed, 12 Feb 2020 17:18:35 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581524338; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=1KIHTt1+MMh3tS0Tz2tXta1bnVaXy/hfgKs9ZpWu9zg=; b=Zy8lN2NjCQlEtPECadsfVINKMyWEdLzmnQJFPGjgLTlUT7WpiERVBCGdMJXfxmpwt270WN JSRV8QCloNMP+k6Ru2j8pl0sP6dOcOmlaZE2WqsoCBXv9gAhRxXjP/VUCjXedZU9Lv/KcA rKQCri1wafCClM5SW6yhc5nJ3Tp6CXU= From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 01/10] ui/gtk: Update gd_refresh_rate_millihz() to handle VirtualConsole Date: Wed, 12 Feb 2020 17:18:26 +0100 Message-Id: <20200212161835.28576-2-kraxel@redhat.com> In-Reply-To: <20200212161835.28576-1-kraxel@redhat.com> References: <20200212161835.28576-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com Cc: Peter Maydell , libvir-list@redhat.com, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Gerd Hoffmann , Paolo Bonzini X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-MC-Unique: hXCjPzXsN6Gdoxxy3keMIQ-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" From: Philippe Mathieu-Daud=C3=A9 Signed-off-by: Philippe Mathieu-Daud=C3=A9 Tested-by: Jan Kiszka Message-id: 20200208161048.11311-2-f4bug@amsat.org Signed-off-by: Gerd Hoffmann --- ui/gtk.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/ui/gtk.c b/ui/gtk.c index d18892d1de61..c59297ff4d2e 100644 --- a/ui/gtk.c +++ b/ui/gtk.c @@ -1965,11 +1965,11 @@ static GtkWidget *gd_create_menu_machine(GtkDisplay= State *s) * If available, return the refresh rate of the display in milli-Hertz, * else return 0. */ -static int gd_refresh_rate_millihz(GtkDisplayState *s) +static int gd_refresh_rate_millihz(GtkWidget *window) { #ifdef GDK_VERSION_3_22 - GdkDisplay *dpy =3D gtk_widget_get_display(s->window); - GdkWindow *win =3D gtk_widget_get_window(s->window); + GdkDisplay *dpy =3D gtk_widget_get_display(window); + GdkWindow *win =3D gtk_widget_get_window(window); GdkMonitor *monitor =3D gdk_display_get_monitor_at_window(dpy, win); =20 return gdk_monitor_get_refresh_rate(monitor); @@ -2045,7 +2045,8 @@ static GSList *gd_vc_gfx_init(GtkDisplayState *s, Vir= tualConsole *vc, vc->gfx.kbd =3D qkbd_state_init(con); vc->gfx.dcl.con =3D con; =20 - refresh_rate_millihz =3D gd_refresh_rate_millihz(s); + refresh_rate_millihz =3D gd_refresh_rate_millihz(vc->window ? + vc->window : s->window); if (refresh_rate_millihz) { vc->gfx.dcl.update_interval =3D MILLISEC_PER_SEC / refresh_rate_mi= llihz; } --=20 2.18.2 From nobody Fri Apr 26 05:01:42 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-2.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 1581524407044980.4301911695894; Wed, 12 Feb 2020 08:20:07 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-371-vP_UrpmbN7uv9gGZEMwKeg-1; Wed, 12 Feb 2020 11:19:28 -0500 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 60A368010F2; Wed, 12 Feb 2020 16:19:21 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 2BB475DA88; Wed, 12 Feb 2020 16:19:21 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id C248D8B2B0; Wed, 12 Feb 2020 16:19:20 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01CGIm7A030186 for ; Wed, 12 Feb 2020 11:18:48 -0500 Received: by smtp.corp.redhat.com (Postfix) id 0511D60F8A; Wed, 12 Feb 2020 16:18:48 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-117-39.ams2.redhat.com [10.36.117.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id 9F89360FC1; Wed, 12 Feb 2020 16:18:36 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id D976F9CA7; Wed, 12 Feb 2020 17:18:35 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581524405; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=31dz9GiRQ4PDE/nDhDuPz2Klvu3+qgLjkLjr4ChUaCs=; b=IT8VXPv2H7w2OeIGzQOYbBALba1Se4dzIBKPccV+Cj2IF25fUxovKv4bxsnO+DaGE+Stj3 kWbU70XG7c506g5V5UUd+WxX+uzuFRGbVpgHNCS6QcQBJAVr0PxoNLsHUqRBiCyrp7dD1f UfAdK7+19H9mKhQLQPkSJ5i2L7bgt/U= From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 02/10] ui/gtk: Fix gd_refresh_rate_millihz() when widget window is not realized Date: Wed, 12 Feb 2020 17:18:27 +0100 Message-Id: <20200212161835.28576-3-kraxel@redhat.com> In-Reply-To: <20200212161835.28576-1-kraxel@redhat.com> References: <20200212161835.28576-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-loop: libvir-list@redhat.com Cc: Peter Maydell , libvir-list@redhat.com, =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= , Gerd Hoffmann , Paolo Bonzini X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-MC-Unique: vP_UrpmbN7uv9gGZEMwKeg-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" From: Philippe Mathieu-Daud=C3=A9 gtk_widget_get_window() returns NULL if the widget's window is not realized, and QEMU crashes. Example under gtk 3.22.30 (mate 1.20.1): qemu-system-x86_64: Gdk: gdk_window_get_origin: assertion 'GDK_IS_WINDOW = (window)' failed (gdb) bt #0 0x00007ffff496cf70 in gdk_window_get_origin () from /usr/lib64/libgdk= -3.so.0 #1 0x00007ffff49582a0 in gdk_display_get_monitor_at_window () from /usr/= lib64/libgdk-3.so.0 #2 0x0000555555bb73e2 in gd_refresh_rate_millihz (window=3D0x5555579d628= 0) at ui/gtk.c:1973 #3 gd_vc_gfx_init (view_menu=3D0x5555579f0590, group=3D0x0, idx=3D0, con= =3D, vc=3D0x5555579d4a90, s=3D0x5555579d49f0) at ui/gtk.c:20= 48 #4 gd_create_menu_view (s=3D0x5555579d49f0) at ui/gtk.c:2149 #5 gd_create_menus (s=3D0x5555579d49f0) at ui/gtk.c:2188 #6 gtk_display_init (ds=3D, opts=3D0x55555661ed80 ) = at ui/gtk.c:2256 #7 0x000055555583d5a0 in main (argc=3D, argv=3D, envp=3D) at vl.c:4358 Fixes: c4c00922cc and 28b58f19d2 (display/gtk: get proper refreshrate) Reported-by: Jan Kiszka Signed-off-by: Philippe Mathieu-Daud=C3=A9 Tested-by: Jan Kiszka Message-id: 20200208161048.11311-3-f4bug@amsat.org Signed-off-by: Gerd Hoffmann --- ui/gtk.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/ui/gtk.c b/ui/gtk.c index c59297ff4d2e..850c49bee02a 100644 --- a/ui/gtk.c +++ b/ui/gtk.c @@ -1968,14 +1968,16 @@ static GtkWidget *gd_create_menu_machine(GtkDisplay= State *s) static int gd_refresh_rate_millihz(GtkWidget *window) { #ifdef GDK_VERSION_3_22 - GdkDisplay *dpy =3D gtk_widget_get_display(window); GdkWindow *win =3D gtk_widget_get_window(window); - GdkMonitor *monitor =3D gdk_display_get_monitor_at_window(dpy, win); =20 - return gdk_monitor_get_refresh_rate(monitor); -#else + if (win) { + GdkDisplay *dpy =3D gtk_widget_get_display(window); + GdkMonitor *monitor =3D gdk_display_get_monitor_at_window(dpy, win= ); + + return gdk_monitor_get_refresh_rate(monitor); + } +#endif return 0; -#endif } =20 static GSList *gd_vc_gfx_init(GtkDisplayState *s, VirtualConsole *vc, --=20 2.18.2 From nobody Fri Apr 26 05:01:42 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1581524340915473.229273355989; Wed, 12 Feb 2020 08:19:00 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-228-mQd2LKl8OC2oRwSeP1y1tA-1; Wed, 12 Feb 2020 11:18:56 -0500 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id D69F7133656C; Wed, 12 Feb 2020 16:18:49 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A7C2A1001B23; Wed, 12 Feb 2020 16:18:49 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 285BA866BE; Wed, 12 Feb 2020 16:18:44 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01CGIhNI030126 for ; Wed, 12 Feb 2020 11:18:43 -0500 Received: by smtp.corp.redhat.com (Postfix) id 852855C54A; Wed, 12 Feb 2020 16:18:43 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-117-39.ams2.redhat.com [10.36.117.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id 91F565C1B2; Wed, 12 Feb 2020 16:18:36 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id E1D5C1FCF2; Wed, 12 Feb 2020 17:18:35 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581524339; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=WwAdZkFTA+k84+vbH3AhktyI2fkZKZ5DVj945SvB/nA=; b=AV1CY6oUPiZ3BjQKk0KUNzNyYYTKMsjTNtZJCJv2fY0/1mJBqUWTXmpYkf22rI6sBhL3VF 8lodl1jloYoxkIJXHw3G9VBvN1qOGxRhipOE5Omdbk2tXNPXNtXe1pVA06qip+DnqMG2Wd ZdtelLFENuaLol6StbGg09DivwAvY/E= From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 03/10] ui: add show-cursor option Date: Wed, 12 Feb 2020 17:18:28 +0100 Message-Id: <20200212161835.28576-4-kraxel@redhat.com> In-Reply-To: <20200212161835.28576-1-kraxel@redhat.com> References: <20200212161835.28576-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com Cc: Peter Maydell , libvir-list@redhat.com, Gerd Hoffmann , Paolo Bonzini X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-MC-Unique: mQd2LKl8OC2oRwSeP1y1tA-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" When enabled, this forces showing the mouse cursor, i.e. do not hide the pointer on mouse grabs. Defaults to off. Signed-off-by: Gerd Hoffmann Reviewed-by: Markus Armbruster Reviewed-by: J=C3=A1n Tomko --- qapi/ui.json | 3 +++ 1 file changed, 3 insertions(+) diff --git a/qapi/ui.json b/qapi/ui.json index e04525d8b44b..f8c803fe4328 100644 --- a/qapi/ui.json +++ b/qapi/ui.json @@ -1144,6 +1144,8 @@ # @type: Which DisplayType qemu should use. # @full-screen: Start user interface in fullscreen mode (default: off). # @window-close: Allow to quit qemu with window close button (default: on= ). +# @show-cursor: Force showing the mouse cursor (default: off). +# (since: 5.0) # @gl: Enable OpenGL support (default: off). # # Since: 2.12 @@ -1153,6 +1155,7 @@ 'base' : { 'type' : 'DisplayType', '*full-screen' : 'bool', '*window-close' : 'bool', + '*show-cursor' : 'bool', '*gl' : 'DisplayGLMode' }, 'discriminator' : 'type', 'data' : { 'gtk' : 'DisplayGTK', --=20 2.18.2 From nobody Fri Apr 26 05:01:42 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-2.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 15815243616531017.8378157224072; Wed, 12 Feb 2020 08:19:21 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-347-6vhXax1ZM5yJoCf0haRoZQ-1; Wed, 12 Feb 2020 11:19:16 -0500 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id D7C50801E6C; Wed, 12 Feb 2020 16:19:09 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A468290500; Wed, 12 Feb 2020 16:19:09 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 1C3EA8B2AF; Wed, 12 Feb 2020 16:19:09 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01CGIjHd030144 for ; Wed, 12 Feb 2020 11:18:45 -0500 Received: by smtp.corp.redhat.com (Postfix) id 4F0531059104; Wed, 12 Feb 2020 16:18:45 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-117-39.ams2.redhat.com [10.36.117.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id 9CCD81001B23; Wed, 12 Feb 2020 16:18:36 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id EA29A31E2A; Wed, 12 Feb 2020 17:18:35 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581524360; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=/qaXWGpEbo8t359CPj+Qy/LhybbhjGK3zYbDG2fnAAU=; b=bMnjsB0PyLzWOgyMaBAUDZ9L2Uh13rakgXqyzSB3eJznlRZh/uJpfnlSBKZvQ7OPlc2SeL 0K9V/pwqwMukwzVnBjbsMKo4QqIbSLDifmJWE6F8nIWEy1rkXgjtEhz++2tbUxOKmc2mqp GqYdomruVc80jido017EViv6KbUXQ4c= From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 04/10] ui: wire up legacy -show-cursor option Date: Wed, 12 Feb 2020 17:18:29 +0100 Message-Id: <20200212161835.28576-5-kraxel@redhat.com> In-Reply-To: <20200212161835.28576-1-kraxel@redhat.com> References: <20200212161835.28576-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-loop: libvir-list@redhat.com Cc: Peter Maydell , libvir-list@redhat.com, Gerd Hoffmann , Paolo Bonzini X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-MC-Unique: 6vhXax1ZM5yJoCf0haRoZQ-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Set new show-cursor display option when legacy -show-cursor is specified on the command line. Signed-off-by: Gerd Hoffmann Reviewed-by: J=C3=A1n Tomko --- vl.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/vl.c b/vl.c index 7dcb0879c497..5419b3d68200 100644 --- a/vl.c +++ b/vl.c @@ -3554,6 +3554,8 @@ int main(int argc, char **argv, char **envp) break; case QEMU_OPTION_show_cursor: cursor_hide =3D 0; + dpy.has_show_cursor =3D true; + dpy.show_cursor =3D true; break; case QEMU_OPTION_uuid: if (qemu_uuid_parse(optarg, &qemu_uuid) < 0) { --=20 2.18.2 From nobody Fri Apr 26 05:01:42 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1581524361199872.1209866387424; Wed, 12 Feb 2020 08:19:21 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-410-Q__iGqD1MHazFZt69k1hwQ-1; Wed, 12 Feb 2020 11:19:17 -0500 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 84D14DBB9; Wed, 12 Feb 2020 16:19:10 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 59EEA5DA85; Wed, 12 Feb 2020 16:19:10 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 1B6508B2AE; Wed, 12 Feb 2020 16:19:09 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01CGIjhn030151 for ; Wed, 12 Feb 2020 11:18:45 -0500 Received: by smtp.corp.redhat.com (Postfix) id 734F15C541; Wed, 12 Feb 2020 16:18:45 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-117-39.ams2.redhat.com [10.36.117.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id 55B3F5C1C3; Wed, 12 Feb 2020 16:18:44 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id F41DD31E30; Wed, 12 Feb 2020 17:18:35 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581524359; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=44B7xvdFL9drjnEYHmM0Jft6hxwGiV7s0cphZbAJGac=; b=YVaXU9AGiHP2/9rKmrW79Y3deRMxJS0A/eZTM2DnnvejxeO5nn1NzRCDXszvfJUuA23UvA 95uK8YoLXjCJg71wCpYk7rDJf1YaTFLgVmnHDvhpaRv7WqiJX0D/8gNdYUyvwHFYhFJ9X0 DjIAFI03Id72AoT2ZqNtI+WG7nARLEk= From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 05/10] ui/sdl: switch to new show-cursor option Date: Wed, 12 Feb 2020 17:18:30 +0100 Message-Id: <20200212161835.28576-6-kraxel@redhat.com> In-Reply-To: <20200212161835.28576-1-kraxel@redhat.com> References: <20200212161835.28576-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com Cc: Peter Maydell , libvir-list@redhat.com, Gerd Hoffmann , Paolo Bonzini X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-MC-Unique: Q__iGqD1MHazFZt69k1hwQ-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Use DisplayOpts settings instead of cursor_hide global variable. Also make "-display sdl,show-cursor=3Don" work. Signed-off-by: Gerd Hoffmann Reviewed-by: J=C3=A1n Tomko --- ui/sdl2.c | 16 ++++++++-------- vl.c | 10 ++++++++++ 2 files changed, 18 insertions(+), 8 deletions(-) diff --git a/ui/sdl2.c b/ui/sdl2.c index 9030f1c42efb..3c9424eb42c3 100644 --- a/ui/sdl2.c +++ b/ui/sdl2.c @@ -161,9 +161,9 @@ static void sdl_update_caption(struct sdl2_console *sco= n) } } =20 -static void sdl_hide_cursor(void) +static void sdl_hide_cursor(struct sdl2_console *scon) { - if (!cursor_hide) { + if (scon->opts->has_show_cursor && scon->opts->show_cursor) { return; } =20 @@ -175,9 +175,9 @@ static void sdl_hide_cursor(void) } } =20 -static void sdl_show_cursor(void) +static void sdl_show_cursor(struct sdl2_console *scon) { - if (!cursor_hide) { + if (scon->opts->has_show_cursor && scon->opts->show_cursor) { return; } =20 @@ -216,7 +216,7 @@ static void sdl_grab_start(struct sdl2_console *scon) SDL_WarpMouseInWindow(scon->real_window, guest_x, guest_y); } } else { - sdl_hide_cursor(); + sdl_hide_cursor(scon); } SDL_SetWindowGrab(scon->real_window, SDL_TRUE); gui_grab =3D 1; @@ -227,7 +227,7 @@ static void sdl_grab_end(struct sdl2_console *scon) { SDL_SetWindowGrab(scon->real_window, SDL_FALSE); gui_grab =3D 0; - sdl_show_cursor(); + sdl_show_cursor(scon); sdl_update_caption(scon); } =20 @@ -658,7 +658,7 @@ static void sdl_mouse_warp(DisplayChangeListener *dcl, =20 if (on) { if (!guest_cursor) { - sdl_show_cursor(); + sdl_show_cursor(scon); } if (gui_grab || qemu_input_is_absolute() || absolute_enabled) { SDL_SetCursor(guest_sprite); @@ -667,7 +667,7 @@ static void sdl_mouse_warp(DisplayChangeListener *dcl, } } } else if (gui_grab) { - sdl_hide_cursor(); + sdl_hide_cursor(scon); } guest_cursor =3D on; guest_x =3D x, guest_y =3D y; diff --git a/vl.c b/vl.c index 5419b3d68200..0a13cf2b1724 100644 --- a/vl.c +++ b/vl.c @@ -1931,6 +1931,16 @@ static void parse_display(const char *p) } else { goto invalid_sdl_args; } + } else if (strstart(opts, ",show-cursor=3D", &nextopt)) { + opts =3D nextopt; + dpy.has_show_cursor =3D true; + if (strstart(opts, "on", &nextopt)) { + dpy.show_cursor =3D true; + } else if (strstart(opts, "off", &nextopt)) { + dpy.show_cursor =3D false; + } else { + goto invalid_sdl_args; + } } else if (strstart(opts, ",gl=3D", &nextopt)) { opts =3D nextopt; dpy.has_gl =3D true; --=20 2.18.2 From nobody Fri Apr 26 05:01:42 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) client-ip=207.211.31.81; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 207.211.31.81 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-1.mimecast.com [207.211.31.81]) by mx.zohomail.com with SMTPS id 1581524367703469.65484416252684; Wed, 12 Feb 2020 08:19:27 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-15-O_knqsGvOY2iTwKnoCu4HA-1; Wed, 12 Feb 2020 11:19:24 -0500 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 07100107ACCC; Wed, 12 Feb 2020 16:19:15 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id D20A226FDD; Wed, 12 Feb 2020 16:19:14 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 87C5718089D8; Wed, 12 Feb 2020 16:19:14 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01CGIjW3030153 for ; Wed, 12 Feb 2020 11:18:45 -0500 Received: by smtp.corp.redhat.com (Postfix) id 7A5305C578; Wed, 12 Feb 2020 16:18:45 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-117-39.ams2.redhat.com [10.36.117.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id 527245C1B2; Wed, 12 Feb 2020 16:18:44 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 0865931E32; Wed, 12 Feb 2020 17:18:36 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581524366; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=PfQTOmWOlDzI/+7N6tPThzcwKfX1cEBhIh686otkctY=; b=ffX8YCrf7Dq/7XW/+rFMgKnZ0OgQtlipDc1dAXfDi7bI0DIPh/l+xBg4AvDdY/jviGpPh3 qGAaP0lpIqr3eLrHIdqKDHjyh/po+wy9DBXBrheOIQVl/G51qaveRIM0XXAOv49EiondKd dXvUocxFo9FMJgh9QimCK2Yp47BonfY= From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 06/10] ui/cocoa: switch to new show-cursor option Date: Wed, 12 Feb 2020 17:18:31 +0100 Message-Id: <20200212161835.28576-7-kraxel@redhat.com> In-Reply-To: <20200212161835.28576-1-kraxel@redhat.com> References: <20200212161835.28576-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com Cc: Peter Maydell , libvir-list@redhat.com, Gerd Hoffmann , Paolo Bonzini X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-MC-Unique: O_knqsGvOY2iTwKnoCu4HA-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Use DisplayOpts settings to set the new file-global cursor_hide variable, stop using the qemu-global cursor_hide variable. Signed-off-by: Gerd Hoffmann Reviewed-by: J=C3=A1n Tomko --- ui/cocoa.m | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ui/cocoa.m b/ui/cocoa.m index fbb5b1b45f81..f7b323044582 100644 --- a/ui/cocoa.m +++ b/ui/cocoa.m @@ -125,6 +125,7 @@ typedef struct { NSWindow *normalWindow, *about_window; static DisplayChangeListener *dcl; static int last_buttons; +static int cursor_hide =3D 1; =20 int gArgc; char **gArgv; @@ -1918,6 +1919,9 @@ static void cocoa_display_init(DisplayState *ds, Disp= layOptions *opts) [(QemuCocoaAppController *)[[NSApplication sharedApplication] = delegate] toggleFullScreen: nil]; }); } + if (opts->has_show_cursor && opts->show_cursor) { + cursor_hide =3D 0; + } =20 dcl =3D g_malloc0(sizeof(DisplayChangeListener)); =20 --=20 2.18.2 From nobody Fri Apr 26 05:01:42 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1581524407083533.5922290593909; Wed, 12 Feb 2020 08:20:07 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-56-NGsBD-Q3MbqZAxaoC7m91Q-1; Wed, 12 Feb 2020 11:19:30 -0500 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 5718AA0CCC; Wed, 12 Feb 2020 16:19:25 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 2427D19C7F; Wed, 12 Feb 2020 16:19:25 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id CDC428B2B3; Wed, 12 Feb 2020 16:19:24 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01CGIsqu030224 for ; Wed, 12 Feb 2020 11:18:54 -0500 Received: by smtp.corp.redhat.com (Postfix) id 62A6026FB6; Wed, 12 Feb 2020 16:18:54 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-117-39.ams2.redhat.com [10.36.117.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id 686D227063; Wed, 12 Feb 2020 16:18:44 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 10C6D31EA0; Wed, 12 Feb 2020 17:18:36 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581524405; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=0UieOV73AiBm51CMiies0SzIbjpyynbNGnm+Kn4I9e0=; b=BCRWmiTW9MNTb8wedmbO4SWSPaDRzbsVC8he35rq1xu+cOAkTkXVgZdYa8/SwD+3fFqCFC owcwzhuPUBwuknKBhwyI1uvhWYxx96T2EJJIk3KNhtw9JwpxPRJMXlF4XuhFXAVQFVMMdf vofIuO8xR1Ygg2JO11DvFnInAm74exc= From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 07/10] ui/gtk: implement show-cursor option Date: Wed, 12 Feb 2020 17:18:32 +0100 Message-Id: <20200212161835.28576-8-kraxel@redhat.com> In-Reply-To: <20200212161835.28576-1-kraxel@redhat.com> References: <20200212161835.28576-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-loop: libvir-list@redhat.com Cc: Peter Maydell , libvir-list@redhat.com, Gerd Hoffmann , Paolo Bonzini X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-MC-Unique: NGsBD-Q3MbqZAxaoC7m91Q-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" When specified just set null_cursor to NULL so we get the default pointer instead of a blank pointer. Signed-off-by: Gerd Hoffmann Reviewed-by: J=C3=A1n Tomko --- ui/gtk.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/ui/gtk.c b/ui/gtk.c index 850c49bee02a..f3f0af8921d9 100644 --- a/ui/gtk.c +++ b/ui/gtk.c @@ -2246,8 +2246,12 @@ static void gtk_display_init(DisplayState *ds, Displ= ayOptions *opts) textdomain("qemu"); =20 window_display =3D gtk_widget_get_display(s->window); - s->null_cursor =3D gdk_cursor_new_for_display(window_display, - GDK_BLANK_CURSOR); + if (s->opts->has_show_cursor && s->opts->show_cursor) { + s->null_cursor =3D NULL; /* default pointer */ + } else { + s->null_cursor =3D gdk_cursor_new_for_display(window_display, + GDK_BLANK_CURSOR); + } =20 s->mouse_mode_notifier.notify =3D gd_mouse_mode_change; qemu_add_mouse_mode_change_notifier(&s->mouse_mode_notifier); --=20 2.18.2 From nobody Fri Apr 26 05:01:42 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) client-ip=205.139.110.61; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.61 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-delivery-1.mimecast.com (us-smtp-1.mimecast.com [205.139.110.61]) by mx.zohomail.com with SMTPS id 1581524363138732.1938721336516; Wed, 12 Feb 2020 08:19:23 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-200-l5QEevM2OSazEzZV4RjFsw-1; Wed, 12 Feb 2020 11:19:18 -0500 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 83927100551C; Wed, 12 Feb 2020 16:19:10 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 58F615C1B0; Wed, 12 Feb 2020 16:19:10 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 4A4B218089C8; Wed, 12 Feb 2020 16:19:09 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01CGIj6Y030158 for ; Wed, 12 Feb 2020 11:18:45 -0500 Received: by smtp.corp.redhat.com (Postfix) id 851DF5C1C3; Wed, 12 Feb 2020 16:18:45 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-117-39.ams2.redhat.com [10.36.117.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id 6D7EB5C240; Wed, 12 Feb 2020 16:18:44 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 1A79431EAC; Wed, 12 Feb 2020 17:18:36 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581524361; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=Ak/voRnhR3d72Uq0dBWSMVREL7Pd4pmT11kFE03lmhk=; b=CuQO8pyudFUF3VdNJa8XVdKD7ka88jRKcu7ufkQEJ31T173/iyx2cGxWi/1Yl+YxwPLq1b 7npPEeOFrAqlaOzVtOAFjBRmvUSUqVutVxwPHA8VzM2x5rLVhb2XN5/nGy6pyJnvtJMvKu gGQPgpc7DxV0ez8wKMwJN9629v/21Ik= From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 08/10] ui: drop curor_hide global variable. Date: Wed, 12 Feb 2020 17:18:33 +0100 Message-Id: <20200212161835.28576-9-kraxel@redhat.com> In-Reply-To: <20200212161835.28576-1-kraxel@redhat.com> References: <20200212161835.28576-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com Cc: Peter Maydell , libvir-list@redhat.com, Gerd Hoffmann , Paolo Bonzini X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-MC-Unique: l5QEevM2OSazEzZV4RjFsw-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" No users left. Signed-off-by: Gerd Hoffmann Reviewed-by: J=C3=A1n Tomko --- include/sysemu/sysemu.h | 1 - vl.c | 2 -- 2 files changed, 3 deletions(-) diff --git a/include/sysemu/sysemu.h b/include/sysemu/sysemu.h index 6358a324a711..7956e9054ade 100644 --- a/include/sysemu/sysemu.h +++ b/include/sysemu/sysemu.h @@ -41,7 +41,6 @@ extern const char *keyboard_layout; extern int win2k_install_hack; extern int alt_grab; extern int ctrl_grab; -extern int cursor_hide; extern int graphic_rotate; extern int no_shutdown; extern int old_param; diff --git a/vl.c b/vl.c index 0a13cf2b1724..62efcd15c0bf 100644 --- a/vl.c +++ b/vl.c @@ -168,7 +168,6 @@ int no_hpet =3D 0; int fd_bootchk =3D 1; static int no_reboot; int no_shutdown =3D 0; -int cursor_hide =3D 1; int graphic_rotate =3D 0; const char *watchdog; QEMUOptionRom option_rom[MAX_OPTION_ROMS]; @@ -3563,7 +3562,6 @@ int main(int argc, char **argv, char **envp) no_shutdown =3D 1; break; case QEMU_OPTION_show_cursor: - cursor_hide =3D 0; dpy.has_show_cursor =3D true; dpy.show_cursor =3D true; break; --=20 2.18.2 From nobody Fri Apr 26 05:01:42 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 1581524372571311.7889464684697; Wed, 12 Feb 2020 08:19:32 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-242--tXyNJhLM1CmjlpGG6xwYA-1; Wed, 12 Feb 2020 11:19:22 -0500 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id EEF6D106BB8B; Wed, 12 Feb 2020 16:19:14 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id C4CA660E1C; Wed, 12 Feb 2020 16:19:14 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 7AEF418089D6; Wed, 12 Feb 2020 16:19:14 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01CGIo9r030209 for ; Wed, 12 Feb 2020 11:18:50 -0500 Received: by smtp.corp.redhat.com (Postfix) id DDEE890095; Wed, 12 Feb 2020 16:18:50 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-117-39.ams2.redhat.com [10.36.117.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id 999E490761; Wed, 12 Feb 2020 16:18:44 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 243C431EB6; Wed, 12 Feb 2020 17:18:36 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581524371; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=4em2DWXVVe2v8rApkmWa0UnHCuFrOGU+HzyQvRV6mpo=; b=OY7UhB/S4TYTzotlc6ddhLUXnhJaXZsYs5dXeYvow5arGgw3I3A7/pkkwOlcgGu/ysTGM+ lXBpGkC3Y4A4Ism6LOQhbbMmkTbIVUMzoan+p/x5K1WEpuIUvD+bQte71HgHIqKnLD/lcI L7lNN7daqOcurSBp58UZb2INMLo4rPc= From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 09/10] ui: deprecate legacy -show-cursor option Date: Wed, 12 Feb 2020 17:18:34 +0100 Message-Id: <20200212161835.28576-10-kraxel@redhat.com> In-Reply-To: <20200212161835.28576-1-kraxel@redhat.com> References: <20200212161835.28576-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-loop: libvir-list@redhat.com Cc: Peter Maydell , libvir-list@redhat.com, Gerd Hoffmann , Paolo Bonzini X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-MC-Unique: -tXyNJhLM1CmjlpGG6xwYA-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Signed-off-by: Gerd Hoffmann Reviewed-by: J=C3=A1n Tomko --- vl.c | 2 ++ qemu-deprecated.texi | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/vl.c b/vl.c index 62efcd15c0bf..001be469c2e9 100644 --- a/vl.c +++ b/vl.c @@ -3562,6 +3562,8 @@ int main(int argc, char **argv, char **envp) no_shutdown =3D 1; break; case QEMU_OPTION_show_cursor: + warn_report("The -show-cursor option is deprecated, " + "use -display {sdl,gtk},show-cursor=3Don inste= ad"); dpy.has_show_cursor =3D true; dpy.show_cursor =3D true; break; diff --git a/qemu-deprecated.texi b/qemu-deprecated.texi index 017b750ca8e2..0671c26c806e 100644 --- a/qemu-deprecated.texi +++ b/qemu-deprecated.texi @@ -148,6 +148,11 @@ QEMU 5.0 introduced an alternative syntax to specify t= he size of the translation block cache, @option{-accel tcg,tb-size=3D}. The new syntax deprecates the previously available @option{-tb-size} option. =20 +@subsection -show-cursor option (since 5.0) + +Use @option{-display sdl,show-cursor=3Don} or + @option{-display gtk,show-cursor=3Don} instead. + @section QEMU Machine Protocol (QMP) commands =20 @subsection change (since 2.5.0) --=20 2.18.2 From nobody Fri Apr 26 05:01:42 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 1581524367332758.4040005685404; Wed, 12 Feb 2020 08:19:27 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-242-lTktAzQfNU67ALNgQMNowA-1; Wed, 12 Feb 2020 11:19:21 -0500 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id B7DB41005513; Wed, 12 Feb 2020 16:19:14 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 8C06B5DA85; Wed, 12 Feb 2020 16:19:14 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 4484318089D0; Wed, 12 Feb 2020 16:19:14 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 01CGIkKs030171 for ; Wed, 12 Feb 2020 11:18:46 -0500 Received: by smtp.corp.redhat.com (Postfix) id 04BE65C541; Wed, 12 Feb 2020 16:18:46 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-117-39.ams2.redhat.com [10.36.117.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id 9F9E65C3F8; Wed, 12 Feb 2020 16:18:44 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 2CE7A31EEA; Wed, 12 Feb 2020 17:18:36 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1581524366; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=RsaMdrjcS7LqXtKeEfDdHdZ8jJXJz/XwFMk+kk69oL8=; b=GjriLMACcqjgixeRRjY/FNzaz5IOq46JSklS2jsgSAPYoV4EQIeeBH5wOdHZfWqkUJ/BRV 79/7j0vVrkxB7Bk3IH4PY5qNl6aOoXydBLQAXHM0Np7fh32+l9jmy/xdGqd7PyugsaUNwb SWKmy3nV8E7VfR/UrvdIW9XR2aWQr8I= From: Gerd Hoffmann To: qemu-devel@nongnu.org Subject: [PULL 10/10] ui/cocoa: Drop workarounds for pre-10.12 OSX Date: Wed, 12 Feb 2020 17:18:35 +0100 Message-Id: <20200212161835.28576-11-kraxel@redhat.com> In-Reply-To: <20200212161835.28576-1-kraxel@redhat.com> References: <20200212161835.28576-1-kraxel@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com Cc: Peter Maydell , libvir-list@redhat.com, Gerd Hoffmann , Paolo Bonzini X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-MC-Unique: lTktAzQfNU67ALNgQMNowA-1 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" From: Peter Maydell Our official OSX support policy covers the last two released versions. Currently that is 10.14 and 10.15. We also may work on older versions, but don't guarantee it. In commit 50290c002c045280f8d in mid-2019 we introduced some uses of CLOCK_MONOTONIC which incidentally broke compilation for pre-10.12 OSX versions (see LP:1861551). We don't intend to fix that, so we might as well drop the code in ui/cocoa.m which caters for pre-10.12 versions as well. (For reference, 10.11 fell out of Apple extended security support in September 2018.) Signed-off-by: Peter Maydell Message-Id: <20200201170534.22123-1-peter.maydell@linaro.org> Signed-off-by: Gerd Hoffmann --- ui/cocoa.m | 59 ------------------------------------------------------ 1 file changed, 59 deletions(-) diff --git a/ui/cocoa.m b/ui/cocoa.m index f7b323044582..747a70839af8 100644 --- a/ui/cocoa.m +++ b/ui/cocoa.m @@ -42,60 +42,10 @@ #include #include "hw/core/cpu.h" =20 -#ifndef MAC_OS_X_VERSION_10_5 -#define MAC_OS_X_VERSION_10_5 1050 -#endif -#ifndef MAC_OS_X_VERSION_10_6 -#define MAC_OS_X_VERSION_10_6 1060 -#endif -#ifndef MAC_OS_X_VERSION_10_9 -#define MAC_OS_X_VERSION_10_9 1090 -#endif -#ifndef MAC_OS_X_VERSION_10_10 -#define MAC_OS_X_VERSION_10_10 101000 -#endif -#ifndef MAC_OS_X_VERSION_10_12 -#define MAC_OS_X_VERSION_10_12 101200 -#endif #ifndef MAC_OS_X_VERSION_10_13 #define MAC_OS_X_VERSION_10_13 101300 #endif =20 -/* macOS 10.12 deprecated many constants, #define the new names for older = SDKs */ -#if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_12 -#define NSEventMaskAny NSAnyEventMask -#define NSEventModifierFlagCapsLock NSAlphaShiftKeyMask -#define NSEventModifierFlagShift NSShiftKeyMask -#define NSEventModifierFlagCommand NSCommandKeyMask -#define NSEventModifierFlagControl NSControlKeyMask -#define NSEventModifierFlagOption NSAlternateKeyMask -#define NSEventTypeFlagsChanged NSFlagsChanged -#define NSEventTypeKeyUp NSKeyUp -#define NSEventTypeKeyDown NSKeyDown -#define NSEventTypeMouseMoved NSMouseMoved -#define NSEventTypeLeftMouseDown NSLeftMouseDown -#define NSEventTypeRightMouseDown NSRightMouseDown -#define NSEventTypeOtherMouseDown NSOtherMouseDown -#define NSEventTypeLeftMouseDragged NSLeftMouseDragged -#define NSEventTypeRightMouseDragged NSRightMouseDragged -#define NSEventTypeOtherMouseDragged NSOtherMouseDragged -#define NSEventTypeLeftMouseUp NSLeftMouseUp -#define NSEventTypeRightMouseUp NSRightMouseUp -#define NSEventTypeOtherMouseUp NSOtherMouseUp -#define NSEventTypeScrollWheel NSScrollWheel -#define NSTextAlignmentCenter NSCenterTextAlignment -#define NSWindowStyleMaskBorderless NSBorderlessWindowMask -#define NSWindowStyleMaskClosable NSClosableWindowMask -#define NSWindowStyleMaskMiniaturizable NSMiniaturizableWindowMask -#define NSWindowStyleMaskTitled NSTitledWindowMask -#endif -/* 10.13 deprecates NSFileHandlingPanelOKButton in favour of - * NSModalResponseOK, which was introduced in 10.9. Define - * it for older versions. - */ -#if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_9 -#define NSModalResponseOK NSFileHandlingPanelOKButton -#endif /* 10.14 deprecates NSOnState and NSOffState in favor of * NSControlStateValueOn/Off, which were introduced in 10.13. * Define for older versions @@ -466,11 +416,7 @@ QemuCocoaView *cocoaView; COCOA_DEBUG("QemuCocoaView: drawRect\n"); =20 // get CoreGraphic context -#if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_10 - CGContextRef viewContextRef =3D [[NSGraphicsContext currentContext] gr= aphicsPort]; -#else CGContextRef viewContextRef =3D [[NSGraphicsContext currentContext] CG= Context]; -#endif =20 CGContextSetInterpolationQuality (viewContextRef, kCGInterpolationNone= ); CGContextSetShouldAntialias (viewContextRef, NO); @@ -1076,9 +1022,7 @@ QemuCocoaView *cocoaView; ------------------------------------------------------ */ @interface QemuCocoaAppController : NSObject -#if (MAC_OS_X_VERSION_MAX_ALLOWED >=3D MAC_OS_X_VERSION_10_6) -#endif { } - (void)doToggleFullScreen:(id)sender; @@ -1127,9 +1071,6 @@ QemuCocoaView *cocoaView; [normalWindow setAcceptsMouseMovedEvents:YES]; [normalWindow setTitle:@"QEMU"]; [normalWindow setContentView:cocoaView]; -#if (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_10) - [normalWindow useOptimizedDrawing:YES]; -#endif [normalWindow makeKeyAndOrderFront:self]; [normalWindow center]; [normalWindow setDelegate: self]; --=20 2.18.2