From: Chris Hanson Date: Sat, 20 May 2000 19:37:03 +0000 (+0000) Subject: Change URL completion so that completion stops after completing a X-Git-Tag: 20090517-FFI~3770 X-Git-Url: https://birchwood-abbey.net/git?a=commitdiff_plain;h=811b52f7d34717e2532e18930c2f4dc249ca2b09;p=mit-scheme.git Change URL completion so that completion stops after completing a protocol name, rather than continuing to complete the body. --- diff --git a/v7/src/imail/imail-core.scm b/v7/src/imail/imail-core.scm index 4ace5a7a6..45310a6e1 100644 --- a/v7/src/imail/imail-core.scm +++ b/v7/src/imail/imail-core.scm @@ -1,6 +1,6 @@ ;;; -*-Scheme-*- ;;; -;;; $Id: imail-core.scm,v 1.77 2000/05/20 03:22:41 cph Exp $ +;;; $Id: imail-core.scm,v 1.78 2000/05/20 19:37:03 cph Exp $ ;;; ;;; Copyright (c) 1999-2000 Massachusetts Institute of Technology ;;; @@ -124,56 +124,53 @@ ;; called with no arguments. (define (url-complete-string url-string if-unique if-not-unique if-not-found) - (let ((colon (string-find-next-char url-string #\:)) - (have-protocol - (lambda (name body) - (let ((prepend (lambda (string) (string-append name ":" string)))) - (let ((completer (get-url-protocol-completer name))) - (if completer - (completer - body - (lambda (string) - (if-unique (prepend string))) - (lambda (prefix get-completions) - (if-not-unique - (prepend prefix) - (lambda () (map prepend (get-completions))))) - if-not-found) - (if-not-found))))))) + (let ((colon (string-find-next-char url-string #\:))) (if colon - (have-protocol (string-head url-string colon) - (string-tail url-string (fix:+ colon 1))) - ((ordered-string-vector-completer - (hash-table/ordered-key-vector url-protocols stringlist - ((ordered-string-vector-matches - (hash-table/ordered-key-vector url-protocols stringlist + ((ordered-string-vector-matches + (hash-table/ordered-key-vector url-protocols string