From patchwork Tue Jan 22 09:28:06 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gerd Hoffmann X-Patchwork-Id: 10775311 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 9919D17F0 for ; Tue, 22 Jan 2019 10:18:17 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 88FE72A26E for ; Tue, 22 Jan 2019 10:18:17 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 7D8E62A337; Tue, 22 Jan 2019 10:18:17 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI autolearn=ham version=3.3.1 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 261222A26E for ; Tue, 22 Jan 2019 10:18:17 +0000 (UTC) Received: from localhost ([127.0.0.1]:42197 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1glt8K-0004Gy-Cl for patchwork-qemu-devel@patchwork.kernel.org; Tue, 22 Jan 2019 05:18:16 -0500 Received: from eggs.gnu.org ([209.51.188.92]:59350) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1glsVw-0006M9-NA for qemu-devel@nongnu.org; Tue, 22 Jan 2019 04:38:37 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1glsM0-0003OM-Ql for qemu-devel@nongnu.org; Tue, 22 Jan 2019 04:28:21 -0500 Received: from mx1.redhat.com ([209.132.183.28]:34272) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1glsM0-0003MQ-Jy for qemu-devel@nongnu.org; Tue, 22 Jan 2019 04:28:20 -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 mx1.redhat.com (Postfix) with ESMTPS id 83D5680F91 for ; Tue, 22 Jan 2019 09:28:19 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-116-38.ams2.redhat.com [10.36.116.38]) by smtp.corp.redhat.com (Postfix) with ESMTP id D185017D1A; Tue, 22 Jan 2019 09:28:15 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 0378216E03; Tue, 22 Jan 2019 10:28:15 +0100 (CET) From: Gerd Hoffmann To: qemu-devel@nongnu.org Date: Tue, 22 Jan 2019 10:28:06 +0100 Message-Id: <20190122092814.14919-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Tue, 22 Jan 2019 09:28:19 +0000 (UTC) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [RFC PATCH v3 0/8] ui: add generic keyboard state tracker, fix keymap X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Gerd Hoffmann Errors-To: qemu-devel-bounces+patchwork-qemu-devel=patchwork.kernel.org@nongnu.org Sender: "Qemu-devel" X-Virus-Scanned: ClamAV using ClamSMTP v3: - s/kbd/qkbd/ to avoid collisons. - add api docs. - misc minor fixes. Gerd Hoffmann (8): kbd-state: add keyboard state tracker sdl2: remove sdl2_reset_keys() function kbd-state: use state tracker for sdl2 sdl2: use only QKeyCode in sdl2_process_key() kbd-state: use state tracker for gtk kbd-state: use state tracker for vnc keymap: pass full keyboard state to keysym2scancode keymap: fix keyup mappings include/ui/gtk.h | 2 + include/ui/kbd-state.h | 96 +++++++++++++++++++++++++++++++++++++ include/ui/sdl2.h | 3 +- ui/keymaps.h | 3 +- ui/vnc.h | 5 +- ui/curses.c | 2 +- ui/gtk.c | 38 +++------------ ui/kbd-state.c | 125 +++++++++++++++++++++++++++++++++++++++++++++++++ ui/keymaps.c | 55 +++++++++++++--------- ui/sdl2-input.c | 50 ++------------------ ui/sdl2.c | 12 ++--- ui/vnc.c | 119 ++++++++++++---------------------------------- ui/Makefile.objs | 2 +- 13 files changed, 310 insertions(+), 202 deletions(-) create mode 100644 include/ui/kbd-state.h create mode 100644 ui/kbd-state.c