From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: Change to `use-dialog-box-p' Date: Sat, 20 May 2023 08:56:12 +0300 Message-ID: <83y1ljsg03.fsf@gnu.org> References: <87o7mf3em6.fsf.ref@yahoo.com> <87o7mf3em6.fsf@yahoo.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3756"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Po Lu Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat May 20 07:56:45 2023 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 1q0Fa8-0000oL-US for ged-emacs-devel@m.gmane-mx.org; Sat, 20 May 2023 07:56:45 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q0FZO-0003fW-L7; Sat, 20 May 2023 01:55:58 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q0FZM-0003fN-Dz for emacs-devel@gnu.org; Sat, 20 May 2023 01:55:56 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q0FZM-00019w-3Z; Sat, 20 May 2023 01:55:56 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=1NEey6K1tzeDedMtxBtR+ON10mZ2vU9l3UWaDH+3Zoc=; b=Y+HULXcOYRF2 sUysagiphZ5GszbQIJX25atigIK3+UjSHeXKQCDrToybcAjH9g1FMF9TD5RoqLyl4lTFWLDmnjEfP lXP/1WHmETBcaWweMf+wbxfMvWycWUwZvwg6nNz0WLdIErJ6OqkFi0Ma3tBS3uP1bvRDqFMs1rv5O tg6Wu0bBxFZgdz40UUj7VHfm/uBJ+kv5VgaKijwE4zB5o/ZXNNo4EEk8ivA+5JmIJaAAgkrJJ54jc wdICn+PYp4p33vSequlhDNxEStR5+AQvusi5ydRu/RgppwfCbzpv0uExfpoWBzyko6JJcbBn1XDbn hC57jcEdIX+sw9CHojzl8g==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1q0FZL-0004S5-EG; Sat, 20 May 2023 01:55:55 -0400 In-Reply-To: <87o7mf3em6.fsf@yahoo.com> (message from Po Lu on Sat, 20 May 2023 10:45:21 +0800) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:306225 Archived-At: > From: Po Lu > Date: Sat, 20 May 2023 10:45:21 +0800 > > After: > > 2023-04-02 Eli Zaretskii > > * lisp/subr.el (use-dialog-box-p): Fix conditions for GUI dialogs. > > dialog boxes will no longer be used when there is no last input event at > all, i.e. when `last-nonmenu-event' is nil. > > Previously, `use-dialog-box-p' would only return nil if > `last-nonmenu-event' was a key event, which is the correct behavior; > `Fyes_or_no_p' still uses the correct test. > > Why was that change made? Because last-nonmenu-event being nil happens in too many cases where showing the GUI dialog is not TRT. Immediately after startup, for example. What is the situation where you need to show a GUI dialog even though last-nonmenu-event is nil?