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 11:14:26 +0300 Message-ID: <83wn13s9lp.fsf@gnu.org> References: <87o7mf3em6.fsf.ref@yahoo.com> <87o7mf3em6.fsf@yahoo.com> <83y1ljsg03.fsf@gnu.org> <87jzx33487.fsf@yahoo.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="4173"; 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 10:14:48 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 1q0Hjj-0000wU-FW for ged-emacs-devel@m.gmane-mx.org; Sat, 20 May 2023 10:14:47 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1q0Hj9-0002Os-5M; Sat, 20 May 2023 04:14:11 -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 1q0Hj8-0002Og-7m for emacs-devel@gnu.org; Sat, 20 May 2023 04:14:10 -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 1q0Hj7-0000Oq-St; Sat, 20 May 2023 04:14:09 -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=pdFKFwtUAR45jumkzODR5ObC6IaZc93vr5aY9Ph0Acg=; b=pYOspocvi/SS bYknHuGLVTY/7JSkLP1+S4dhMXuSwmmPd+cJWdOKTHRkbo+BVinyxcidjhvuzyO+P6GrX5r2S1D32 oESnbfZQR27C/9l4T82ixdbd2nugQTn8r3fmSPNyfi/EvAxbKLzjNS9MFN/Vz4AcX7GufowPpvfgv HFDRhSx9D+PSKFJxBUiOrJvaoHUK2pKNC14i3vHU6rpIo5KZxmwU6ny6p80JmDA2PPgcrk0UQN5tq u4kC3gmbMnYlN7RB5NMMNfGnRK9rXoe6OBUkyuknnYcC8xEkZQx7OMoN0YeSL1xwng+BdbcnqxISz PhuGdqsNTqh2tdOjCr0a/w==; 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 1q0Hj7-0006Ro-0X; Sat, 20 May 2023 04:14:09 -0400 In-Reply-To: <87jzx33487.fsf@yahoo.com> (message from Po Lu on Sat, 20 May 2023 14:29:44 +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:306227 Archived-At: > From: Po Lu > Cc: emacs-devel@gnu.org > Date: Sat, 20 May 2023 14:29:44 +0800 > > Eli Zaretskii writes: > > > 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? > > Precisely this one: immediately after start up. I don't understand why > it's not correct to show a dialog box in that situation; in many cases, > it's much easier to use the dialog box than to use the keyboard. Can you show a specific recipe where this happens? Otherwise it is hard to reason about the issue. AFAIR, without that change, just invoking y-or-n-p after startup would show a GUI dialog, and that doesn't sound right to me. IME, showing GUI dialogs by default is not TRT, because Emacs generally defaults to keyboard input via the minibuffer, and only shows the GUI dialog when the command was invoked via a mouse or from a menu. In other cases we don't force users to use the mouse for Emacs interaction.