From 29e813e36505254b44c1038ae085e47eab13b71c Mon Sep 17 00:00:00 2001 From: Chris Hanson Date: Fri, 31 Mar 2000 19:35:00 +0000 Subject: [PATCH] Allow DIRED-THIS-FILE to take buffer in place of mark. --- v7/src/edwin/dired.scm | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/v7/src/edwin/dired.scm b/v7/src/edwin/dired.scm index 3c5cdf6c3..ba510433b 100644 --- a/v7/src/edwin/dired.scm +++ b/v7/src/edwin/dired.scm @@ -1,6 +1,6 @@ ;;; -*-Scheme-*- ;;; -;;; $Id: dired.scm,v 1.174 2000/03/31 19:33:30 cph Exp $ +;;; $Id: dired.scm,v 1.175 2000/03/31 19:35:00 cph Exp $ ;;; ;;; Copyright (c) 1986, 1989-2000 Massachusetts Institute of Technology ;;; @@ -920,9 +920,13 @@ Actions controlled by variables list-directory-brief-switches (define (dired-this-file #!optional mark) (let ((mark - (if (or (default-object? mark) (not mark)) - (current-point) - mark))) + (cond ((or (default-object? mark) (not mark)) + (current-point)) + ((buffer? mark) + (if (selected-buffer? mark) + (current-point) + (buffer-point mark))) + (else mark)))) (let ((start (line-start mark 0))) (and (dired-filename-start start) (cons (dired-pathname start) start))))) -- 2.25.1