From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 02 13:22:58 2022 Received: (at submit) by debbugs.gnu.org; 2 Oct 2022 17:22:58 +0000 Received: from localhost ([127.0.0.1]:47952 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1of2g5-0002Ky-SV for submit@debbugs.gnu.org; Sun, 02 Oct 2022 13:22:58 -0400 Received: from lists.gnu.org ([209.51.188.17]:52822) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1of2g4-0002Kr-Os for submit@debbugs.gnu.org; Sun, 02 Oct 2022 13:22:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:51164) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1of2g4-0004I5-Jj for bug-gnu-emacs@gnu.org; Sun, 02 Oct 2022 13:22:56 -0400 Received: from smtp2-g21.free.fr ([212.27.42.2]:50284) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1of2g2-0004qb-4u for bug-gnu-emacs@gnu.org; Sun, 02 Oct 2022 13:22:55 -0400 Received: from server.a16n.net (unknown [82.65.98.121]) by smtp2-g21.free.fr (Postfix) with ESMTPS id 512B12003DE for ; Sun, 2 Oct 2022 19:22:49 +0200 (CEST) Received: from ws.localdomain (lfbn-ren-1-357-130.w2-10.abo.wanadoo.fr [2.10.189.130]) by server.a16n.net (Postfix) with ESMTPSA id B068A800491 for ; Sun, 2 Oct 2022 19:22:48 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=a16n.net; s=a16n; t=1664731368; bh=lfCU1GMYedvKCnzpw4ybnVl8Gy84cAWdMJiqcwN58e8=; h=From:To:Subject:Date; b=pVCyPy5p2QvyGECY3guAwqpjM8UhqXTIuH31qS00rVEk4hAy37gs7/qOCW7XCgzgx B391iCmnR1TU9e72vuaUsngVIn/jhxxnGE3HbP9iIuLs4a7pSwfXa3qZpMgcHL1NpB y+jRYjQ8zHw+D6sAHFBBvPfbvzBZnLEcb+vmfPx/GtayKCXIV5Ok22RP3IVuTjUmyk XGbpj6+nMn2+zI7JKwXYdkBcRwxXEU7thGQHVuKwgJMTB0NUTigMWNgPZb9uP/CfaF YU84DngZvx5yqNSBS8S/vdmWZ3CoaKli31vJ/y+2jiKhEt4byNbgDLOHENcacmEK1Y Ur8dYafFqACZA== Received: by ws.localdomain (Postfix, from userid 1000) id F202D205FB; Sun, 2 Oct 2022 19:22:47 +0200 (CEST) From: =?utf-8?Q?Peter_M=C3=BCnster?= To: Emacs Bugs Subject: 29.0.50; don't remove thumbnails in image-dired-do-flagged-delete until confirmation Date: Sun, 02 Oct 2022 19:22:47 +0200 Message-ID: <87tu4mxhqw.fsf@a16n.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" Received-SPF: pass client-ip=212.27.42.2; envelope-from=pm@a16n.net; helo=smtp2-g21.free.fr 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, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) --==-=-= Content-Type: multipart/mixed; boundary="=-=-=" --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable Hi, As suggested by Stefan Kangas, please find here attached a patch, that changes image-dired-do-flagged-delete, so that thumbnails are removed only, when images are actually deleted in the dired buffer. Kind regards, =2D-=20 Peter --=-=-= Content-Type: text/x-patch; charset=utf-8 Content-Disposition: attachment; filename=my-patch.diff Content-Transfer-Encoding: quoted-printable commit 5d117180ae038fde0732a96451bb588433a3ad38 Author: Peter M=C3=BCnster Date: Sun Oct 2 19:17:51 2022 +0200 Don't remove thumbnails in image-dired-do-flagged-delete until confirma= tion =20=20=20=20 * lisp/image/image-dired.el (image-dired-do-flagged-delete): Delete thumbnails only when original images disappear. diff --git a/lisp/image/image-dired.el b/lisp/image/image-dired.el index 8fb89d4502..33f7149dec 100644 =2D-- a/lisp/image/image-dired.el +++ b/lisp/image/image-dired.el @@ -1347,17 +1347,21 @@ image-dired-do-flagged-delete (interactive nil image-dired-thumbnail-mode) (unless (derived-mode-p 'image-dired-thumbnail-mode) (user-error "Not in `image-dired-thumbnail-mode'")) =2D (let ((inhibit-read-only t)) =2D (goto-char (point-min)) =2D (while (not (eobp)) =2D (if (image-dired-thumb-file-flagged-p) =2D (progn =2D (delete-char 1) =2D (forward-char)) =2D (forward-char 2)))) =2D (image-dired--line-up-with-method) =2D (image-dired--on-file-in-dired-buffer =2D (dired-do-flagged-delete))) + (image-dired--with-dired-buffer + (dired-do-flagged-delete)) + (let ((deletions)) + (save-excursion + (let ((inhibit-read-only t)) + (goto-char (point-min)) + (while (not (eobp)) + (let ((file-name (image-dired-original-file-name))) + (if (image-dired--with-dired-buffer (dired-goto-file file-name= )) + (forward-char 2) + (delete-char 1) + (forward-char) + (setq deletions t)))))) + (if deletions + (image-dired--line-up-with-method)))) =20 (defun image-dired--thumb-update-mark-at-point () (with-silent-modifications --=-=-=-- --==-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iGoEARECACoWIQS/5hHRBUjla4uZVXU6jitvQ7HLaAUCYznI5wwccG1AYTE2bi5u ZXQACgkQOo4rb0Oxy2g6TQCgmPN7Sd7X0lnnyunfRcVvXttcIVsAoNd0W7JJdCMx GJeiHZw4uzFknB11 =J9B9 -----END PGP SIGNATURE----- --==-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 02 14:27:07 2022 Received: (at 58255) by debbugs.gnu.org; 2 Oct 2022 18:27:07 +0000 Received: from localhost ([127.0.0.1]:48030 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1of3gA-0003xt-Oj for submit@debbugs.gnu.org; Sun, 02 Oct 2022 14:27:07 -0400 Received: from mail-oa1-f53.google.com ([209.85.160.53]:34726) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1of3g8-0003xI-4b for 58255@debbugs.gnu.org; Sun, 02 Oct 2022 14:27:04 -0400 Received: by mail-oa1-f53.google.com with SMTP id 586e51a60fabf-1321a1e94b3so5089192fac.1 for <58255@debbugs.gnu.org>; Sun, 02 Oct 2022 11:27:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:to:subject:message-id:date:mime-version :references:in-reply-to:from:from:to:cc:subject:date; bh=AJkq9u3V0/BNTtLbk9R6vxH2j8af5I7rVHXANOIUKA0=; b=nPTRUelYzTgL7zax+CyrFZu4r1bDicK15iTpK5JHnmS+0KiovYGCOrZtrqc2x3d2CP FDj5jjmMXp3Or3CyuSzRh0RqG33jub5LSplRQr3AE2BWXSZv92vGKRY0iPo6mbSUJYVr Wn1ShFNRQ/BTvaGcEVlHTaC8T7L/qtshofwhDMJdN48CYFfFFxwstEsSocih05QV9y7b ncWSfioBMUWEVomM2qFGCFUJs+xrqpn7DFmpmPna2+b1V3Do9/KafkZ74jDPsjI72bKb yTtyyR+T8ZKiKdxIbSVyhArZX7Invy5nCx7iI2RmXz+cTU1DwvAud09M8p8uppoMVkJc 9JMQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:to:subject:message-id:date:mime-version :references:in-reply-to:from:x-gm-message-state:from:to:cc:subject :date; bh=AJkq9u3V0/BNTtLbk9R6vxH2j8af5I7rVHXANOIUKA0=; b=JUmnHUv2vtpQrUgBIIaNuVuHRiNtDFBwvVGrX25I73pJF8xz7KRJtwchp7B6ts2awl eTi2RhRq3UghaXLB/2V9CagSFP7AWNMsOeNOOhj52MKAQxNXJWvNxrrs9NyHLE3nG7Q3 dss5iEgS/F5GsTriKXUox2wlgwxbDCV6HioyC8ipl28P/k/6TsxwdkLy3MKf3C9wyAfK qhJgnbqGecqbRUa/+Ccml1Ufr/BAr18DyVwpl3FLMa7WmI88u5xYrbvzoc74of0NBNZq mMFYkgf6gbrKEvgclguFMomfCjsZhx5zWJI7o2zrC6WjeUQ6d5fYbcgrSm7dh23vQG3h KT+w== X-Gm-Message-State: ACrzQf1kWMAq1AxxrYW+CHe6FdMx2ZG6UXZT6ovg6bEA6z0H0lVA3GTY SWzahFf9Nf9JP3QHVZ4fTsekO7o2jqUiDRkv7YY= X-Google-Smtp-Source: AMsMyM5+zvGwvZL2vyMCKutX6A5TVFeL7sUaqThvP8LMYBhoe5CiyuzOrG/XRdt0qrxTk/TiQFGoHbdBhNIeBiUvqPo= X-Received: by 2002:a05:6870:46a6:b0:12d:130c:2fd5 with SMTP id a38-20020a05687046a600b0012d130c2fd5mr3545307oap.92.1664735218357; Sun, 02 Oct 2022 11:26:58 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Sun, 2 Oct 2022 20:26:58 +0200 From: Stefan Kangas In-Reply-To: <87tu4mxhqw.fsf@a16n.net> References: <87tu4mxhqw.fsf@a16n.net> X-Hashcash: 1:20:221002:58255@debbugs.gnu.org::oyFzqW4RhuDC8zX1:2WNc MIME-Version: 1.0 Date: Sun, 2 Oct 2022 20:26:57 +0200 Message-ID: Subject: Re: bug#58255: 29.0.50; don't remove thumbnails in image-dired-do-flagged-delete until confirmation To: =?UTF-8?Q?Peter_M=C3=BCnster?= , 58255@debbugs.gnu.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 58255 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) tags 58255 + patch close 58255 29.1 thanks Peter M=C3=BCnster writes: > As suggested by Stefan Kangas, please find here attached a patch, that > changes image-dired-do-flagged-delete, so that thumbnails are removed > only, when images are actually deleted in the dired buffer. Thanks for the patch! It looks good to me, so I've installed it on master. In the future, please use `git format-patch -1 HEAD' to produce the patch, as that makes it easier to install. From debbugs-submit-bounces@debbugs.gnu.org Sun Oct 02 15:36:14 2022 Received: (at 58255) by debbugs.gnu.org; 2 Oct 2022 19:36:14 +0000 Received: from localhost ([127.0.0.1]:48097 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1of4l3-0003t4-Ue for submit@debbugs.gnu.org; Sun, 02 Oct 2022 15:36:14 -0400 Received: from smtp2-g21.free.fr ([212.27.42.2]:25154) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1of4l0-0003sv-TT for 58255@debbugs.gnu.org; Sun, 02 Oct 2022 15:36:12 -0400 Received: from server.a16n.net (unknown [82.65.98.121]) by smtp2-g21.free.fr (Postfix) with ESMTPS id 80C712003CC; Sun, 2 Oct 2022 21:36:08 +0200 (CEST) Received: from ws.localdomain (lfbn-ren-1-357-130.w2-10.abo.wanadoo.fr [2.10.189.130]) by server.a16n.net (Postfix) with ESMTPSA id D18EE800491; Sun, 2 Oct 2022 21:36:07 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=a16n.net; s=a16n; t=1664739367; bh=B9A9ZAn4Gd2pMQQZtTSUMKnYT2Z+9ZxG1W4wQoEgvBw=; h=From:To:Cc:Subject:In-Reply-To:References:Date; b=IZsoRHnqloR1/u3EFY1IyEZuaMk7mNd3hKanSreJRjKa9u/Go9hkDiSsmD0SBq5ec /t7Q7U5ePdCYo5hihJBAXT96YsfBer6/7a7v8TOOhcdAIW97PfzdevRrofGZHaprYq sUPKiksKm0aLdhNF+WkFX4EFXEEzFfDef4SUNvGCKUFNpmVrmWBD5c5iSt2kfvXzdw Phz0ekOuaY4UMu9AUqMw8hTHr73BfRD47fdRH+1txRd0U+zdnnQeTbgwlutySz4kF3 VZyB3pgTwkcun40S5FOilEIE2z7zW764GZaFbnQPF4mIjIR8lYnaaoeFL3iPLI0GBz JThd5FAHuXqmQ== Received: by ws.localdomain (Postfix, from userid 1000) id 4D495205FB; Sun, 2 Oct 2022 21:36:07 +0200 (CEST) From: =?utf-8?Q?Peter_M=C3=BCnster?= To: Stefan Kangas Subject: Re: bug#58255: 29.0.50; don't remove thumbnails in image-dired-do-flagged-delete until confirmation In-Reply-To: (Stefan Kangas's message of "Sun, 2 Oct 2022 20:26:57 +0200") References: <87tu4mxhqw.fsf@a16n.net> Date: Sun, 02 Oct 2022 21:36:06 +0200 Message-ID: <87edvqm315.fsf@a16n.net> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha1; protocol="application/pgp-signature" X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 58255 Cc: 58255@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On Sun, Oct 02 2022, Stefan Kangas wrote: > In the future, please use `git format-patch -1 HEAD' Sorry. Yes, I'll do that next time. =2D-=20 Peter --=-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iGoEARECACoWIQS/5hHRBUjla4uZVXU6jitvQ7HLaAUCYznoJgwccG1AYTE2bi5u ZXQACgkQOo4rb0Oxy2jKegCguqLCKYuHX96IXfn7Lbxu6SMoeoUAn1X3e4MChIuB XKvCK5yhanD2kXqs =JlYB -----END PGP SIGNATURE----- --=-=-=-- From unknown Sun Aug 17 22:07:13 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Mon, 31 Oct 2022 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator