From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Tak Kunihiro Newsgroups: gmane.emacs.bugs Subject: bug#50067: Context menus Date: Tue, 24 Aug 2021 19:12:59 +0900 (JST) Message-ID: <20210824.191259.1858282353329289005.tkk@misasa.okayama-u.ac.jp> References: <87lf4tews5.fsf@mail.linkov.net> <00A9BE5A-D661-42AF-A65B-3B80C7428121@misasa.okayama-u.ac.jp> <87wnociu41.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="37356"; mail-complaints-to="usenet@ciao.gmane.io" Cc: mattiase@acm.org, alan@idiocy.org, 50067@debbugs.gnu.org, larsi@gnus.org, tkk@misasa.okayama-u.ac.jp To: juri@linkov.net Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Aug 24 12:14:15 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1mITRe-0009WL-Aq for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 24 Aug 2021 12:14:14 +0200 Original-Received: from localhost ([::1]:59218 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mITRc-0006bo-JF for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 24 Aug 2021 06:14:12 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:51722) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mITRS-0006Va-SI for bug-gnu-emacs@gnu.org; Tue, 24 Aug 2021 06:14:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:60003) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mITRS-000430-Kl for bug-gnu-emacs@gnu.org; Tue, 24 Aug 2021 06:14:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mITRS-0001zS-Go for bug-gnu-emacs@gnu.org; Tue, 24 Aug 2021 06:14:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Tak Kunihiro Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 24 Aug 2021 10:14:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 50067 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: fixed Original-Received: via spool by 50067-submit@debbugs.gnu.org id=B50067.16298000087589 (code B ref 50067); Tue, 24 Aug 2021 10:14:02 +0000 Original-Received: (at 50067) by debbugs.gnu.org; 24 Aug 2021 10:13:28 +0000 Original-Received: from localhost ([127.0.0.1]:43314 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mITQu-0001yL-Kt for submit@debbugs.gnu.org; Tue, 24 Aug 2021 06:13:28 -0400 Original-Received: from mx0a-00602c01.pphosted.com ([205.220.162.67]:54290) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mITQp-0001y7-NY for 50067@debbugs.gnu.org; Tue, 24 Aug 2021 06:13:27 -0400 Original-Received: from pps.filterd (m0238148.ppops.net [127.0.0.1]) by mx0a-00602c01.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 17NLq9em020720; Tue, 24 Aug 2021 19:13:09 +0900 Original-Received: from mlsec.cc.okayama-u.ac.jp (mlsec.cc.okayama-u.ac.jp [150.46.12.254]) by mx0a-00602c01.pphosted.com with ESMTP id 3amfqjruqk-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 24 Aug 2021 19:13:09 +0900 Original-Received: from jlsv301.okayama-u.ac.jp (unknown [150.46.12.5]) by mlsec.cc.okayama-u.ac.jp with smtp id 66b6_38da_1cbcafff_7825_4b36_a13a_62884b81feb1; Tue, 24 Aug 2021 19:13:00 +0900 Original-Received: from localhost (vesta.misasa.okayama-u.ac.jp [150.46.48.154]) by jlsv301.okayama-u.ac.jp (Postfix) with ESMTPSA id DA0017600C8; Tue, 24 Aug 2021 19:13:00 +0900 (JST) In-Reply-To: <87wnociu41.fsf@mail.linkov.net> X-Mailer: Mew version 6.8 on Emacs 26.3 X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 11 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 4 Rules triggered EDT_SA_AU_PASS=0, EDT_SA_DN_PASS=0, EDT_SA_TS_PASS=0, RV6963=0 X-NAI-Spam-Version: 2.3.0.9418 : core <6963> : inlines <7226> : streams <1899714> : uri <3310564> X-Proofpoint-ORIG-GUID: P8jjqr1mKDn2E5QMs4HzyPe5D4v7ZsQ7 X-Proofpoint-GUID: P8jjqr1mKDn2E5QMs4HzyPe5D4v7ZsQ7 X-Proofpoint-Virus-Version: vendor=nai engine=6300 definitions=10085 signatures=668682 X-Proofpoint-Spam-Details: rule=outbound_spam_notspam policy=outbound_spam score=0 phishscore=0 impostorscore=0 malwarescore=0 priorityscore=1501 mlxlogscore=841 adultscore=0 lowpriorityscore=0 clxscore=1015 mlxscore=0 spamscore=0 bulkscore=0 suspectscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2107140000 definitions=main-2108240068 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:212531 Archived-At: I started to understand the system. A plug-in to list frames would be something like this. I think it is good to have interface to basic utilities such for recentf and bookmarks. (defun context-menu-frame (menu) "Add MENU a list of frames." (let (frame-map) (dolist (frame (visible-frame-list)) (let ((nickname (cdr (assoc 'name (frame-parameters frame)))) (cmd `(lambda nil (interactive) (funcall 'menu-bar-select-frame ,frame)))) (push (vector nickname cmd :active (not (equal frame (selected-frame)))) frame-map))) (push ["--" ignore] frame-map) (push ["New" make-frame-command] frame-map) (setq frame-map (reverse frame-map)) (push "Frames" frame-map) (easy-menu-add-item menu nil frame-map) menu))