emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/dslide 53ab5eb653 101/230: convert image action fullscreen


From: ELPA Syncer
Subject: [nongnu] elpa/dslide 53ab5eb653 101/230: convert image action fullscreen into an option
Date: Sun, 7 Jul 2024 19:00:20 -0400 (EDT)

branch: elpa/dslide
commit 53ab5eb6537dac8e2e0918d06cac416ebaf484db
Author: Psionik K <73710933+psionic-k@users.noreply.github.com>
Commit: Psionik K <73710933+psionic-k@users.noreply.github.com>

    convert image action fullscreen into an option
    
    the more common workflow will be to display the presentation itself full 
frame
    when full frame images are desired.
    
    for the development case, starting with it disabled is a little bit less 
jarring
    when flipping through slides
    
    Signed-off-by: Psionik K <73710933+psionic-k@users.noreply.github.com>
---
 macro-slides.el | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

diff --git a/macro-slides.el b/macro-slides.el
index e07b1e4313..e507b6dd20 100644
--- a/macro-slides.el
+++ b/macro-slides.el
@@ -1458,6 +1458,10 @@ stateful-sequence class methods.  METHOD-NAME is a 
string."
     :initform t
     :initarg :include-linked
     :documentation "Loads linked images.  See `org-display-inline-images'.")
+   (fullscreen
+    :initform nil
+    :initarg :fullscreen
+    :documentation "Switch to full frame during display.")
    (refresh
     :initform nil
     :initarg :refresh
@@ -1477,10 +1481,10 @@ stateful-sequence class methods.  METHOD-NAME is a 
string."
 (cl-defmethod ms-step-forward ((obj ms-action-image))
   (when-let ((link (ms-section-next obj 'link)))
     (ms-push-window-config nil)
-
     ;; TODO success detection
     (let ((org-link-frame-setup '((file . find-file)))
-          (display-buffer-overriding-action '(display-buffer-full-frame)))
+          (display-buffer-overriding-action (when (oref obj fullscreen)
+                                              '(display-buffer-full-frame))))
       (org-link-open link))
 
     (when (eq (buffer-local-value 'major-mode (current-buffer))
@@ -1498,10 +1502,10 @@ stateful-sequence class methods.  METHOD-NAME is a 
string."
 (cl-defmethod ms-step-backward ((obj ms-action-image))
   (when-let ((link (ms-section-previous obj 'link)))
     (ms-push-window-config nil)
-
     ;; TODO success detection
     (let ((org-link-frame-setup '((file . find-file)))
-          (display-buffer-overriding-action '(display-buffer-full-frame)))
+          (display-buffer-overriding-action (when (oref obj fullscreen)
+                                              '(display-buffer-full-frame))))
       (org-link-open link))
 
     (when (eq (buffer-local-value 'major-mode (current-buffer))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]