[Top][All Lists]

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

[elpa] externals/clipboard-collector ff6c25c 22/31: Depend on emacs 25 a

From: Stefan Monnier
Subject: [elpa] externals/clipboard-collector ff6c25c 22/31: Depend on emacs 25 and linux
Date: Sun, 6 Jan 2019 17:16:22 -0500 (EST)

branch: externals/clipboard-collector
commit ff6c25cb078a46cf07b9af9a2fb92a53d57a64d6
Author: Clemens Radermacher <address@hidden>
Commit: Clemens Radermacher <address@hidden>

    Depend on emacs 25 and linux
 README.org             | 2 +-
 clipboard-collector.el | 9 ++++++++-
 2 files changed, 9 insertions(+), 2 deletions(-)

diff --git a/README.org b/README.org
index 2325c00..a1f1f4f 100644
--- a/README.org
+++ b/README.org
@@ -5,7 +5,7 @@ stay at one place to copy things and later insert them all at 
once at another
 place. Emacs has =append-next-kill= but it only works inside Emacs and it only
 applies to the very next command. Further it would be great if Emacs could
 detect specific clipboard entries and transform them to a different format
-automatically. =clipboard-collector= provides you with those features.
+automatically. =clipboard-collector= provides you with those features on Linux.
 You can use it to simply collect multiple entries by binding
 =clipboard-collector-mode= to a key:
diff --git a/clipboard-collector.el b/clipboard-collector.el
index 94efc08..7c7cf4e 100644
--- a/clipboard-collector.el
+++ b/clipboard-collector.el
@@ -5,7 +5,7 @@
 ;; Author: clemera <address@hidden>
 ;; URL: https://github.com/clemera/clipboard-collector
 ;; Version: 0.1
-;; Package-Requires: ((emacs "24.5"))
+;; Package-Requires: ((emacs "25"))
 ;; Keywords: convenience
 ;; This program is free software; you can redistribute it and/or modify
@@ -47,6 +47,9 @@ Rules used are defined in `clipboard-collector--rules'."
   :global t
   (if clipboard-collector-mode
+        (setq cliboard-collector--enable-primary
+              select-enable-primary)
+        (setq select-enable-primary t)
         ;; set defaults
         (setq clipboard-collector--finish-function
@@ -59,11 +62,15 @@ Rules used are defined in `clipboard-collector--rules'."
               (run-at-time 0 0.2 #'clipboard-collector--try-collect))
         (message "Start collecting, finish with %s."
                  (substitute-command-keys "\\[clipboard-collector-finish]")))
+    (setq select-enable-primary cliboard-collector--enable-primary)
     (when clipboard-collector--timer
       (cancel-timer clipboard-collector--timer))
     (setq clipboard-collector--timer nil)))
+(defvar cliboard-collector--enable-primary nil
+  "Save user setting for `select-enable-primary'.")
 (defvar clipboard-collector--last-clip nil
   "Save last clipboard entry.")

reply via email to

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