From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Aaron Jensen Newsgroups: gmane.emacs.devel Subject: Re: input-pending-p after make-frame-visible Date: Sun, 26 Sep 2021 19:55:33 -0400 Message-ID: References: <786eca99-bb42-c744-af26-b0435a745a81@gmx.at> <1d7cee7a-6137-609c-1400-f161dc8c860e@gmx.at> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="31102"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: martin rudalics Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Mon Sep 27 01:56:36 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mUe0a-0007v5-7Z for ged-emacs-devel@m.gmane-mx.org; Mon, 27 Sep 2021 01:56:36 +0200 Original-Received: from localhost ([::1]:49736 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mUe0Y-0001XS-AW for ged-emacs-devel@m.gmane-mx.org; Sun, 26 Sep 2021 19:56:34 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:39938) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mUdzq-0000cG-GR for emacs-devel@gnu.org; Sun, 26 Sep 2021 19:55:52 -0400 Original-Received: from mail-pg1-x536.google.com ([2607:f8b0:4864:20::536]:36821) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mUdzn-00011X-W0 for emacs-devel@gnu.org; Sun, 26 Sep 2021 19:55:50 -0400 Original-Received: by mail-pg1-x536.google.com with SMTP id t1so16093956pgv.3 for ; Sun, 26 Sep 2021 16:55:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=r9HHHYDQaqCfpufQyOzRDdjMXKaU/Sh60ytDwyjnMtc=; b=XqDnFTJIj1CgsVbOTLiO0XiSF+BLe+wTK8hDgZizm4dCuNyjkvbNQ0Uwee7ikiXYDI QqKdDDW1fB156h1gHfBcpBX8TjqyCdnFri2cqExnUbt7qd+1zu+L+xnqocl/WRXw8gLf i72Q74IirIkd5QtXZzilsgufEIQzJfVPhe2i+FVrHs+rAJaLn0g6CUwEOkQETtTBqxEM buRpI5jbGvKBlZM+R/z7DZYK+L6SInH0+s64uclJqhERFJkApc8g+jlI86NdQaF06sgy uea/bbYGle7y7Hj9q6VLJCgseWRltwx70ghipE62bzTbcOVdD2qBMOJzG5o9a68wkH2l rVAQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=r9HHHYDQaqCfpufQyOzRDdjMXKaU/Sh60ytDwyjnMtc=; b=fCdOe9Px8Fg8JqB49vRUGFT1ZCNAoO11qlkBFCBpkusauB7l7LeYMUN8w2HFTPBESm Xt0dYYLQTSuY7t+guE8eLAonMF9mL3Ii1/Ws/F1nVGL8P2UWptnATYuX0oe1y45/kfnI 3AFPzh/2sdl/X7fQpgxwNWybCLvVct5qyxO6Ic8j7b06I6SMdbgOQi0bzwa24PeJfnOz I2X2IMsnXBfqqzJ7sPJMH8hyYqny8sLNbdmMvPcyJavPzEGtXzl124GU/oROnTkW/81y QUbEnjW5f2KaBEUVWF3ZFAxJwEZSZ7q08u25KOYeNyvqTUK9fVqLUhc5u4LyVTQDY4jr WngA== X-Gm-Message-State: AOAM5307COc+CebAhbmaEu6s6osh3iykZQfqPoZp/PH8jqwOnjGC6lj6 GsA1mG/Ogp4/kZ3gyvecnGdv6cnNlgkTDNDR5rcH9MQ6 X-Google-Smtp-Source: ABdhPJybletXqlSnIHkuROs82yNYjXyPwP7RT0+jHmPGj+x73RmF3lYk/RAiAZ7srDpOV2UtxkUJyBmFZAcFi1qLzmk= X-Received: by 2002:a05:6a00:1a4c:b0:44b:1fa6:532c with SMTP id h12-20020a056a001a4c00b0044b1fa6532cmr20942126pfv.64.1632700544681; Sun, 26 Sep 2021 16:55:44 -0700 (PDT) In-Reply-To: <1d7cee7a-6137-609c-1400-f161dc8c860e@gmx.at> Received-SPF: pass client-ip=2607:f8b0:4864:20::536; envelope-from=aaronjensen@gmail.com; helo=mail-pg1-x536.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:275548 Archived-At: On Sun, Sep 26, 2021 at 1:51 PM martin rudalics wrote: > > > I'll give the patch a shot. Does it filter events out for > > input-pending-p as well? From the thread, it seems like that is the > > idea, but I wanted to confirm that this particular patch intends to do > > that because vertico uses both while-no-input and input-pending-p. > > > > I don't know what else I have to offer on that thread over what is > > discussed. Is there a way for me to tell what is triggering > > input-pending-p to be t while I am in Emacs? > > Maybe > > (progn > (while (not (input-pending-p)) > (sit-for 1)) > (message "%s" last-input-event)) > > can reveal something. With emacs -Q do C-x 5 2 and put that form in > *scratch*. In the first frame show *Messages* so you don't miss any > output. Have a window from some other process ready that you can give > focus to since otherwise you might get a `switch-frame-event' that > intervenes - the "first" frame should _never_ get focus by the window > manager. Now eval the form in the second frame via C-x C-e and try to > lower the second frame via the window manager and raise it again. There > should be no message. > > I cannot do that here because for some reason I don't see your problem. > But I can reproduce it when dragging the second frame with the mouse. I only see my problem sometimes. It doesn't reproduce if I restart Emacs until it does (some random amount of time later) When I do the above, if I focus away from the 2nd frame and back I see nothing. If I minimize it (I'm on macOS, so not sure if that is the closest thing to lowering) then I either get a focus-out-event or switch-frame-event because it ends up giving the focus to the 1st frame, that's just how macOS works. Maybe I can find a place to put last-input-event if it reproduces again. I'm using your patch now, so I can let you know if it happens again. Thanks, Aaron