mirror of
https://codeberg.org/cage/tinmop/
synced 2025-01-19 03:00:08 +01:00
- [TUI] supported gemini proxy;
- improved debugging of croatoan events.
This commit is contained in:
parent
82529df61a
commit
39963e00b1
@ -115,7 +115,8 @@
|
||||
(swconf:close-link-window-after-select-p))
|
||||
(ui:close-open-message-link-window))
|
||||
(cond
|
||||
((gemini-client:absolute-gemini-or-titan-url-p url)
|
||||
((or (gemini-client:absolute-gemini-or-titan-url-p url)
|
||||
(gemini-client:url-needs-proxy-p url))
|
||||
(db:insert-in-history (ui:open-url-prompt) url)
|
||||
(db:gemlog-mark-as-seen url)
|
||||
(gemini-viewer:ensure-just-one-stream-rendering)
|
||||
|
@ -1377,7 +1377,8 @@
|
||||
(cond
|
||||
((text-utils:string-empty-p url)
|
||||
(ui:error-message (_ "Empty address")))
|
||||
((gemini-client:absolute-gemini-or-titan-url-p url)
|
||||
((or (gemini-client:absolute-gemini-or-titan-url-p url)
|
||||
(gemini-client:url-needs-proxy-p url))
|
||||
(gemini-viewer:bury-download-stream)
|
||||
(gemini-viewer:ensure-just-one-stream-rendering)
|
||||
(gemini-viewer:request url
|
||||
|
@ -95,6 +95,23 @@
|
||||
as argument `complex-string'."
|
||||
(length (complex-char-array complex-string)))
|
||||
|
||||
(defgeneric debug-event (object decoded-event))
|
||||
|
||||
(defmethod debug-event ((object croatoan:event) decoded-event)
|
||||
(let ((key (croatoan:event-key object)))
|
||||
(debug-event key decoded-event)))
|
||||
|
||||
(defmethod debug-event ((object croatoan:key) decoded-event)
|
||||
(misc:dbg "event name: ~s alt: ~a :ctrl: ~a shift: ~a-> ~s"
|
||||
(croatoan:key-name object)
|
||||
(croatoan:key-alt object)
|
||||
(croatoan:key-ctrl object)
|
||||
(croatoan:key-shift object)
|
||||
decoded-event))
|
||||
|
||||
(defmethod debug-event ((object t) decoded-event)
|
||||
(misc:dbg "event ~a ~s -> ~s" (type-of object) object decoded-event))
|
||||
|
||||
(defun decode-key-event (event &key (convert-symbol-to-string t))
|
||||
(labels ((decode-event (key)
|
||||
(cond
|
||||
@ -111,7 +128,7 @@ as argument `complex-string'."
|
||||
|
||||
(let* ((key (croatoan:event-key event))
|
||||
(decoded-event (decode-event key)))
|
||||
#+debug-croatoan-events (misc:dbg "event ~s" decoded-event)
|
||||
#+debug-croatoan-events (debug-event event decoded-event)
|
||||
(values decoded-event key))))
|
||||
|
||||
(defun colorize-tree-element (color-map annotated-element)
|
||||
|
Loading…
Reference in New Issue
Block a user