All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: "Leonardo Soares Müller" <leozinho29_eu@hotmail.com>,
	"Gerd Hoffmann" <kraxel@redhat.com>
Cc: "qemu-devel@nongnu.org" <qemu-devel@nongnu.org>
Subject: Re: [Qemu-devel] Key repeat is no longer working on TTY and grub menu
Date: Tue, 12 Feb 2019 13:11:36 +0000	[thread overview]
Message-ID: <20190212131136.GH9386@redhat.com> (raw)
In-Reply-To: <RO1P152MB1483088A66FD63B63FD7279A97650@RO1P152MB1483.LAMP152.PROD.OUTLOOK.COM>

On Tue, Feb 12, 2019 at 01:02:42PM +0000, Leonardo Soares Müller wrote:
> I noticed that the key inputs are no longer repeating when using default
> setting on QEMU. For example, if I press "a" and keep it pressed it will
> print only one "a" instead of repeating them. Another example is when
> deleting text: instead of holding backspace pressed and the text is
> deleted, it's needed to press backspace once for each character.
> 
> As this makes many tasks much slower, requiring many key presses for
> tasks that were done in a single press, I did a bisect to see when this
> change happened. The result is:
> 
> 0c0d42737dfdcea872a987ecba6ef55047df8881 is the first bad commit
> commit 0c0d42737dfdcea872a987ecba6ef55047df8881
> Author: Gerd Hoffmann <kraxel@redhat.com>
> Date:   Tue Jan 22 10:28:11 2019 +0100
> 
>     kbd-state: use state tracker for gtk
> 
>     Use the new keyboard state tracked for gtk.  Allows to drop the
>     gtk-specific modifier state tracking code.
> 
>     Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
>     Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
>     Message-id: 20190122092814.14919-6-kraxel@redhat.com
> 
> :040000 040000 e882f144bafca90257a4604b5e62486a1ca038b2
> 0139afe1aee24256c3f711c080b0230ab104074a M	include
> :040000 040000 c258efc06107b944b0627792b9f2377600033118
> 4fd01a25a3e0d1fccca72c35ec58b205aa4fd882 M	ui
> 
> I'm using the GTK interface and all guests without a Graphical User
> Interface (GUI) are affected by this. This happens on grub menu and on
> TTY of multiple Linux guests.

Yes, this is another regression accidentally introduced by the keyboard
state tracker.

When GTK does key repeat it omits the Up event for repeated keys.

IOW, you get

    Press (a)
    Press (a)
    Press (a)
    Release (a)

Not

    Press (a)
    Release (a)
    Press (a)
    Release (a)
    Press (a)
    Release (a)

The keyboard state tracker doesn't take this into account, so it is
surpressing all except the first Press event.

This might affect other frontends too if they use the same trick for
key repeat

Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|

  reply	other threads:[~2019-02-12 13:12 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-12 13:02 [Qemu-devel] Key repeat is no longer working on TTY and grub menu Leonardo Soares Müller
2019-02-12 13:11 ` Daniel P. Berrangé [this message]
2019-02-13  6:01   ` Markus Armbruster
2019-02-19  8:19     ` Gerd Hoffmann

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190212131136.GH9386@redhat.com \
    --to=berrange@redhat.com \
    --cc=kraxel@redhat.com \
    --cc=leozinho29_eu@hotmail.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.