mirror of
https://codeberg.org/cage/tinmop/
synced 2024-12-20 23:34:40 +01:00
- [gemini] expand 'pwd' when printing the directory's contents;
- [gemini] forced displaying of director with tinmop.
This commit is contained in:
parent
ad21da5957
commit
02ea992ca8
@ -73,7 +73,8 @@
|
|||||||
(defun open-message-link (url enqueue)
|
(defun open-message-link (url enqueue)
|
||||||
(let* ((parsed (iri:iri-parse url))
|
(let* ((parsed (iri:iri-parse url))
|
||||||
(scheme (uri:scheme parsed)))
|
(scheme (uri:scheme parsed)))
|
||||||
(if (string= gemini-constants:+gemini-scheme+ scheme)
|
(cond
|
||||||
|
((string= gemini-constants:+gemini-scheme+ scheme)
|
||||||
(let ((program-events:*process-events-immediately* t)
|
(let ((program-events:*process-events-immediately* t)
|
||||||
(event (make-instance 'program-events:gemini-push-behind-downloading-event
|
(event (make-instance 'program-events:gemini-push-behind-downloading-event
|
||||||
:priority program-events:+maximum-event-priority+)))
|
:priority program-events:+maximum-event-priority+)))
|
||||||
@ -82,8 +83,15 @@
|
|||||||
(gemini-viewer:ensure-just-one-stream-rendering)
|
(gemini-viewer:ensure-just-one-stream-rendering)
|
||||||
(program-events:push-event event)
|
(program-events:push-event event)
|
||||||
(gemini-viewer:request url :enqueue enqueue
|
(gemini-viewer:request url :enqueue enqueue
|
||||||
:use-cached-file-if-exists t))
|
:use-cached-file-if-exists t)))
|
||||||
(os-utils:open-resource-with-external-program url nil))))
|
((fs:dirp url)
|
||||||
|
(let ((program-events:*process-events-immediately* t)
|
||||||
|
(event (make-instance 'program-events:gemini-push-behind-downloading-event
|
||||||
|
:priority program-events:+maximum-event-priority+)))
|
||||||
|
(program-events:push-event event)
|
||||||
|
(gemini-viewer:load-gemini-url url :give-focus-to-message-window nil)))
|
||||||
|
(t
|
||||||
|
(os-utils:open-resource-with-external-program url nil)))))
|
||||||
|
|
||||||
(defclass open-links-window ()
|
(defclass open-links-window ()
|
||||||
((links
|
((links
|
||||||
|
@ -1017,12 +1017,13 @@
|
|||||||
((gemini-client:absolute-gemini-url-p url)
|
((gemini-client:absolute-gemini-url-p url)
|
||||||
(gemini-viewer:request url :use-cached-file-if-exists use-cached-file-if-exists))
|
(gemini-viewer:request url :use-cached-file-if-exists use-cached-file-if-exists))
|
||||||
((fs:dirp url)
|
((fs:dirp url)
|
||||||
(let* ((all-paths (fs:prepend-pwd (fs:collect-children url)))
|
(let* ((index-path (fs:prepend-pwd url))
|
||||||
|
(all-paths (fs:collect-children index-path))
|
||||||
(raw-text (with-output-to-string (stream)
|
(raw-text (with-output-to-string (stream)
|
||||||
(write-sequence (gemini-parser:geminize-h1
|
(write-sequence (gemini-parser:geminize-h1
|
||||||
(format nil
|
(format nil
|
||||||
(_ "Index of local directory ~a~2%")
|
(_ "Index of local directory ~a~2%")
|
||||||
url))
|
index-path))
|
||||||
stream)
|
stream)
|
||||||
(loop for path in all-paths do
|
(loop for path in all-paths do
|
||||||
(let* ((dirp (fs:dirp path))
|
(let* ((dirp (fs:dirp path))
|
||||||
@ -1043,7 +1044,7 @@
|
|||||||
(text (gemini-parser:sexp->text parsed
|
(text (gemini-parser:sexp->text parsed
|
||||||
gemini-client:*gemini-page-theme*)))
|
gemini-client:*gemini-page-theme*)))
|
||||||
(gemini-viewer:maybe-initialize-metadata window)
|
(gemini-viewer:maybe-initialize-metadata window)
|
||||||
(gemini-viewer:add-url-to-history window url)
|
(gemini-viewer:add-url-to-history window index-path)
|
||||||
(refresh-gemini-message-window links raw-text text nil)
|
(refresh-gemini-message-window links raw-text text nil)
|
||||||
(windows:draw window)))
|
(windows:draw window)))
|
||||||
(t
|
(t
|
||||||
|
Loading…
Reference in New Issue
Block a user