emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] Changes to emacs/lisp/term/x-win.el


From: Juanma Barranquero
Subject: [Emacs-diffs] Changes to emacs/lisp/term/x-win.el
Date: Tue, 04 Feb 2003 08:28:08 -0500

Index: emacs/lisp/term/x-win.el
diff -c emacs/lisp/term/x-win.el:1.159 emacs/lisp/term/x-win.el:1.160
*** emacs/lisp/term/x-win.el:1.159      Fri Jan 17 03:14:14 2003
--- emacs/lisp/term/x-win.el    Tue Feb  4 08:28:06 2003
***************
*** 68,74 ****
  
  (if (not (eq window-system 'x))
      (error "%s: Loading x-win.el but not compiled for X" (invocation-name)))
!        
  (require 'frame)
  (require 'mouse)
  (require 'scroll-bar)
--- 68,74 ----
  
  (if (not (eq window-system 'x))
      (error "%s: Loading x-win.el but not compiled for X" (invocation-name)))
! 
  (require 'frame)
  (require 'mouse)
  (require 'scroll-bar)
***************
*** 259,265 ****
      (expand-file-name (if (file-directory-p emacs-dir)
                          (concat emacs-dir basename)
                        (concat "~/.emacs-" basename)))))
!       
  (defun emacs-session-save ()
    "This function is called when the window system is shutting down.
  If this function returns non-nil, the window system shutdown is cancelled.
--- 259,265 ----
      (expand-file-name (if (file-directory-p emacs-dir)
                          (concat emacs-dir basename)
                        (concat "~/.emacs-" basename)))))
! 
  (defun emacs-session-save ()
    "This function is called when the window system is shutting down.
  If this function returns non-nil, the window system shutdown is cancelled.
***************
*** 282,288 ****
      (with-current-buffer buf
        (let ((cancel-shutdown (condition-case nil
                                 ;; A return of t means cancel the shutdown.
!                                (run-hook-with-args-until-success 
                                  'emacs-save-session-functions)
                               (error t))))
        (unless cancel-shutdown
--- 282,288 ----
      (with-current-buffer buf
        (let ((cancel-shutdown (condition-case nil
                                 ;; A return of t means cancel the shutdown.
!                                (run-hook-with-args-until-success
                                  'emacs-save-session-functions)
                               (error t))))
        (unless cancel-shutdown
***************
*** 300,307 ****
        (delete-file filename)
        (message "Restored session data"))))
  
!  
!   
  
  ;;
  ;; Standard X cursor shapes, courtesy of Mr. Fox, who wanted ALL of them.
--- 300,307 ----
        (delete-file filename)
        (message "Restored session data"))))
  
! 
! 
  
  ;;
  ;; Standard X cursor shapes, courtesy of Mr. Fox, who wanted ALL of them.
***************
*** 2127,2133 ****
    (cond ((>= (length text) x-cut-buffer-max)
         (x-set-cut-buffer "" push)
         (setq x-last-selected-text-cut ""))
!       (t 
        (x-set-cut-buffer text push)
         (setq x-last-selected-text-cut text)))
    (x-set-selection 'PRIMARY text)
--- 2127,2133 ----
    (cond ((>= (length text) x-cut-buffer-max)
         (x-set-cut-buffer "" push)
         (setq x-last-selected-text-cut ""))
!       (t
        (x-set-cut-buffer text push)
         (setq x-last-selected-text-cut text)))
    (x-set-selection 'PRIMARY text)
***************
*** 2147,2157 ****
    (let (clip-text primary-text cut-text)
      (when x-select-enable-clipboard
        ;; Don't die if x-get-selection signals an error.
!       (if (null clip-text) 
          (condition-case c
              (setq clip-text (x-get-selection 'CLIPBOARD 'COMPOUND_TEXT))
            (error nil)))
!       (if (null clip-text) 
          (condition-case c
              (setq clip-text (x-get-selection 'CLIPBOARD 'STRING))
            (error nil)))
--- 2147,2157 ----
    (let (clip-text primary-text cut-text)
      (when x-select-enable-clipboard
        ;; Don't die if x-get-selection signals an error.
!       (if (null clip-text)
          (condition-case c
              (setq clip-text (x-get-selection 'CLIPBOARD 'COMPOUND_TEXT))
            (error nil)))
!       (if (null clip-text)
          (condition-case c
              (setq clip-text (x-get-selection 'CLIPBOARD 'STRING))
            (error nil)))
***************
*** 2160,2172 ****
        ;; Check the CLIPBOARD selection for 'newness', is it different
        ;; from what we remebered them to be last time we did a
        ;; cut/paste operation.
!       (setq clip-text 
            (cond;; check clipboard
             ((or (not clip-text) (string= clip-text ""))
              (setq x-last-selected-text-clipboard nil))
             ((eq      clip-text x-last-selected-text-clipboard) nil)
             ((string= clip-text x-last-selected-text-clipboard)
!             ;; Record the newer string, 
              ;; so subsequent calls can use the `eq' test.
              (setq x-last-selected-text-clipboard clip-text)
              nil)
--- 2160,2172 ----
        ;; Check the CLIPBOARD selection for 'newness', is it different
        ;; from what we remebered them to be last time we did a
        ;; cut/paste operation.
!       (setq clip-text
            (cond;; check clipboard
             ((or (not clip-text) (string= clip-text ""))
              (setq x-last-selected-text-clipboard nil))
             ((eq      clip-text x-last-selected-text-clipboard) nil)
             ((string= clip-text x-last-selected-text-clipboard)
!             ;; Record the newer string,
              ;; so subsequent calls can use the `eq' test.
              (setq x-last-selected-text-clipboard clip-text)
              nil)
***************
*** 2175,2198 ****
        )
  
      ;; Don't die if x-get-selection signals an error.
!     (if (null primary-text) 
        (condition-case c
            (setq primary-text (x-get-selection 'PRIMARY 'COMPOUND_TEXT))
          (error nil)))
!     (if (null primary-text) 
        (condition-case c
            (setq primary-text (x-get-selection 'PRIMARY 'STRING))
          (error nil)))
      ;; Check the PRIMARY selection for 'newness', is it different
      ;; from what we remebered them to be last time we did a
      ;; cut/paste operation.
!     (setq primary-text 
          (cond;; check primary selection
           ((or (not primary-text) (string= primary-text ""))
            (setq x-last-selected-text-primary nil))
           ((eq      primary-text x-last-selected-text-primary) nil)
           ((string= primary-text x-last-selected-text-primary)
!           ;; Record the newer string, 
            ;; so subsequent calls can use the `eq' test.
            (setq x-last-selected-text-primary primary-text)
            nil)
--- 2175,2198 ----
        )
  
      ;; Don't die if x-get-selection signals an error.
!     (if (null primary-text)
        (condition-case c
            (setq primary-text (x-get-selection 'PRIMARY 'COMPOUND_TEXT))
          (error nil)))
!     (if (null primary-text)
        (condition-case c
            (setq primary-text (x-get-selection 'PRIMARY 'STRING))
          (error nil)))
      ;; Check the PRIMARY selection for 'newness', is it different
      ;; from what we remebered them to be last time we did a
      ;; cut/paste operation.
!     (setq primary-text
          (cond;; check primary selection
           ((or (not primary-text) (string= primary-text ""))
            (setq x-last-selected-text-primary nil))
           ((eq      primary-text x-last-selected-text-primary) nil)
           ((string= primary-text x-last-selected-text-primary)
!           ;; Record the newer string,
            ;; so subsequent calls can use the `eq' test.
            (setq x-last-selected-text-primary primary-text)
            nil)
***************
*** 2204,2216 ****
      ;; Check the x cut buffer for 'newness', is it different
      ;; from what we remebered them to be last time we did a
      ;; cut/paste operation.
!     (setq cut-text 
          (cond;; check primary selection
           ((or (not cut-text) (string= cut-text ""))
            (setq x-last-selected-text-cut nil))
           ((eq      cut-text x-last-selected-text-cut) nil)
           ((string= cut-text x-last-selected-text-cut)
!           ;; Record the newer string, 
            ;; so subsequent calls can use the `eq' test.
            (setq x-last-selected-text-cut cut-text)
        nil)
--- 2204,2216 ----
      ;; Check the x cut buffer for 'newness', is it different
      ;; from what we remebered them to be last time we did a
      ;; cut/paste operation.
!     (setq cut-text
          (cond;; check primary selection
           ((or (not cut-text) (string= cut-text ""))
            (setq x-last-selected-text-cut nil))
           ((eq      cut-text x-last-selected-text-cut) nil)
           ((string= cut-text x-last-selected-text-cut)
!           ;; Record the newer string,
            ;; so subsequent calls can use the `eq' test.
            (setq x-last-selected-text-cut cut-text)
        nil)
***************
*** 2231,2237 ****
      ;; timestamps there is no way to know what the 'correct' value to
      ;; return is.  The nice thing to do would be to tell the user we
      ;; saw multiple possible selections and ask the user which was the
!     ;; one they wanted.  
      ;; This code is still a big improvement because now the user can
      ;; futz with the current selection and get emacs to pay attention
      ;; to the cut buffer again (previously as soon as clipboard or
--- 2231,2237 ----
      ;; timestamps there is no way to know what the 'correct' value to
      ;; return is.  The nice thing to do would be to tell the user we
      ;; saw multiple possible selections and ask the user which was the
!     ;; one they wanted.
      ;; This code is still a big improvement because now the user can
      ;; futz with the current selection and get emacs to pay attention
      ;; to the cut buffer again (previously as soon as clipboard or




reply via email to

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