mirror of https://codeberg.org/cage/tinmop/
- [gui] disabled gempub menu if there is no support for zip files (zip/unzip executables not found);
- [gui] added to history also local paths.
This commit is contained in:
parent
f7cb9a1a20
commit
d507278f67
|
@ -247,7 +247,7 @@
|
|||
(tour (gui:make-menu bar (_ "Tour")))
|
||||
(bookmarks (gui:make-menu bar (_ "Bookmarks")))
|
||||
(gemlogs (gui:make-menu bar (_ "Gemlogs")))
|
||||
(gempub (gui:make-menu bar (_ "Books")))
|
||||
#+gempub-support (gempub (gui:make-menu bar (_ "Books")))
|
||||
(help (gui:make-menu bar (_ "Help"))))
|
||||
(gui:make-menubutton tools
|
||||
(_ "Certificates")
|
||||
|
@ -265,6 +265,7 @@
|
|||
(_ "View source")
|
||||
(menu:show-page-source-clsr main-window)
|
||||
:accelerator (client-configuration:get-keybinding :view-source))
|
||||
#+gempub-support
|
||||
(gui:make-menubutton gempub
|
||||
(_ "Search gempub library")
|
||||
(menu:search-gempub-library-clsr main-window)
|
||||
|
@ -273,6 +274,7 @@
|
|||
(gui:make-menubutton gempub
|
||||
(_ "Make gempub file")
|
||||
(menu:make-gempub-clsr main-window))
|
||||
#+gempub-support
|
||||
(gui:make-menubutton gempub
|
||||
(_ "Import gempub file")
|
||||
(menu:install-gempub-clsr main-window))
|
||||
|
@ -1030,6 +1032,7 @@ local file paths."
|
|||
ev:+standard-event-priority+
|
||||
path)))
|
||||
(ev:with-enqueued-process-and-unblock ()
|
||||
(comm:make-request :gemini-push-url-to-history 1 path)
|
||||
(clear-gemtext main-window)
|
||||
(collect-ir-lines path gui-goodies:*main-frame* parsed-lines)
|
||||
(render-toc main-window path)))
|
||||
|
@ -1038,9 +1041,17 @@ local file paths."
|
|||
1
|
||||
ev:+standard-event-priority+
|
||||
path)))
|
||||
(cev:enqueue-request-and-wait-results :gemini-push-url-to-history
|
||||
1
|
||||
ev:+standard-event-priority+
|
||||
path)
|
||||
(render-monospaced-text main-window lines))
|
||||
(client-os-utils:open-resource-with-external-program main-window path))))
|
||||
((fs:directory-exists-p path)
|
||||
(cev:enqueue-request-and-wait-results :gemini-push-url-to-history
|
||||
1
|
||||
ev:+standard-event-priority+
|
||||
path)
|
||||
(open-local-path (gui:get-open-file :initial-dir path
|
||||
:parent main-window)
|
||||
main-window))
|
||||
|
|
|
@ -82,5 +82,9 @@
|
|||
(defun gemini-pop-url-from-history ()
|
||||
(gw:pop-url-from-history *gemini-window*))
|
||||
|
||||
(defun gemini-push-url-to-history (iri)
|
||||
(gw:push-url-to-history *gemini-window* iri)
|
||||
t)
|
||||
|
||||
(defun iri-to-parent-path (iri)
|
||||
(iri:iri-to-parent-path iri))
|
||||
|
|
|
@ -136,7 +136,7 @@
|
|||
(cond
|
||||
((gemini-client:gemini-file-stream-p meta)
|
||||
(debug-gemini-gui "response is a gemini document stream")
|
||||
(gemini-viewer:push-url-to-history *gemini-window* actual-iri)
|
||||
(gemini-push-url-to-history actual-iri)
|
||||
(make-text-based-stream t)
|
||||
(make-gemini-response (gemini-client:code gemini-client:+success+)
|
||||
(gemini-client:description gemini-client:+success+)
|
||||
|
@ -280,7 +280,7 @@
|
|||
(if cached-stream
|
||||
(progn
|
||||
(debug-gemini-gui "caching found for ~a" actual-iri)
|
||||
(gemini-viewer:push-url-to-history *gemini-window* actual-iri)
|
||||
(gemini-push-url-to-history actual-iri)
|
||||
(make-gemini-response (gw:status-code cached-stream)
|
||||
(gw:status-code-description cached-stream)
|
||||
(gw:meta cached-stream)
|
||||
|
|
|
@ -78,6 +78,9 @@
|
|||
"iri" 0)
|
||||
(gen-rpc "gemini-current-url" 'gemini-current-url)
|
||||
(gen-rpc "gemini-pop-url-from-history" 'gemini-pop-url-from-history)
|
||||
(gen-rpc "gemini-push-url-to-history"
|
||||
'gemini-push-url-to-history
|
||||
"iri" 0)
|
||||
(gen-rpc "gemini-save-url-db-history"
|
||||
'gemini-save-url-db-history
|
||||
"iri" 0)
|
||||
|
|
Loading…
Reference in New Issue