diff options
| author | Stefan Monnier | 2007-10-17 16:22:27 +0000 |
|---|---|---|
| committer | Stefan Monnier | 2007-10-17 16:22:27 +0000 |
| commit | 17f3909f6154ba5473cd5d76fc2b87fab48d79a2 (patch) | |
| tree | 8cd183a2f652ea2c088c5850ee031f1238994b55 | |
| parent | bc3512d03f4d7baa2118b0f4361297249463bb5a (diff) | |
| download | emacs-17f3909f6154ba5473cd5d76fc2b87fab48d79a2.tar.gz emacs-17f3909f6154ba5473cd5d76fc2b87fab48d79a2.zip | |
(vc-diff-sentinel, vc-diff-internal): Revert some changes in the
behavior unrelated to filesets.
| -rw-r--r-- | lisp/ChangeLog | 13 | ||||
| -rw-r--r-- | lisp/vc.el | 56 |
2 files changed, 36 insertions, 33 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e8e4280b713..3259a58a839 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,9 +1,14 @@ | |||
| 1 | 2007-10-17 Stefan Monnier <monnier@iro.umontreal.ca> | ||
| 2 | |||
| 3 | * vc.el (vc-diff-sentinel, vc-diff-internal): Revert some change in the | ||
| 4 | behavior unrelated to filesets. | ||
| 5 | |||
| 1 | 2007-10-17 Chong Yidong <cyd@stupidchicken.com> | 6 | 2007-10-17 Chong Yidong <cyd@stupidchicken.com> |
| 2 | 7 | ||
| 3 | * longlines.el (longlines-wrap-follows-window-size): Integer value | 8 | * longlines.el (longlines-wrap-follows-window-size): Integer value |
| 4 | specifies wrapping margin. | 9 | specifies wrapping margin. |
| 5 | (longlines-mode, longlines-window-change-function): Set | 10 | (longlines-mode, longlines-window-change-function): |
| 6 | window-specific wrapping margin based on the above. | 11 | Set window-specific wrapping margin based on the above. |
| 7 | 12 | ||
| 8 | 2007-10-17 John Wiegley <johnw@newartisans.com> | 13 | 2007-10-17 John Wiegley <johnw@newartisans.com> |
| 9 | 14 | ||
| @@ -16,8 +21,8 @@ | |||
| 16 | 21 | ||
| 17 | 2007-10-17 Glenn Morris <rgm@gnu.org> | 22 | 2007-10-17 Glenn Morris <rgm@gnu.org> |
| 18 | 23 | ||
| 19 | * progmodes/cc-menus.el (cc-imenu-c++-generic-expression): Tweak | 24 | * progmodes/cc-menus.el (cc-imenu-c++-generic-expression): |
| 20 | regexp to avoid stack overflow. | 25 | Tweak regexp to avoid stack overflow. |
| 21 | 26 | ||
| 22 | 2007-10-16 Stefan Monnier <monnier@iro.umontreal.ca> | 27 | 2007-10-16 Stefan Monnier <monnier@iro.umontreal.ca> |
| 23 | 28 | ||
diff --git a/lisp/vc.el b/lisp/vc.el index a0db56ce6d7..0cf800c2ddd 100644 --- a/lisp/vc.el +++ b/lisp/vc.el | |||
| @@ -1873,24 +1873,17 @@ The meaning of REV1 and REV2 is the same as for `vc-revision-diff'." | |||
| 1873 | (make-obsolete 'vc-diff-switches-list 'vc-switches "22.1") | 1873 | (make-obsolete 'vc-diff-switches-list 'vc-switches "22.1") |
| 1874 | 1874 | ||
| 1875 | (defun vc-diff-sentinel (verbose rev1-name rev2-name) | 1875 | (defun vc-diff-sentinel (verbose rev1-name rev2-name) |
| 1876 | ;; Did changes get generated into the buffer? | 1876 | ;; The empty sync output case has already been handled, so the only |
| 1877 | (if (not (zerop (buffer-size (get-buffer "*vc-diff*")))) | 1877 | ;; possibility of an empty output is for an async process, in which case |
| 1878 | (progn | 1878 | ;; it's important to insert the "diffs end here" message in the buffer |
| 1879 | (pop-to-buffer "*vc-diff*") | 1879 | ;; since the user may miss a message in the echo area. |
| 1880 | ;; Gnus-5.8.5 sets up an autoload for diff-mode, even if it's | 1880 | (when verbose |
| 1881 | ;; not available. Work around that. | 1881 | (let ((inhibit-read-only t)) |
| 1882 | (if (require 'diff-mode nil t) (diff-mode)) | 1882 | (if (eq (buffer-size) 0) |
| 1883 | (when verbose | 1883 | (insert "No differences found.\n") |
| 1884 | (let (buffer-read-only) | 1884 | (insert (format "\n\nDiffs between %s and %s end here." rev1-name rev2-name))))) |
| 1885 | (goto-char (point-max)) | 1885 | (goto-char (point-min)) |
| 1886 | (insert (format "\n\nDiffs between %s and %s end here." rev1-name rev2-name)) | 1886 | (shrink-window-if-larger-than-buffer)) |
| 1887 | (goto-char (point-min)) | ||
| 1888 | (insert (format "Diffs between %s and %s:\n\n" rev1-name rev2-name)))) | ||
| 1889 | (shrink-window-if-larger-than-buffer) | ||
| 1890 | t) | ||
| 1891 | (progn | ||
| 1892 | (message "No changes between %s and %s" rev1-name rev2-name) | ||
| 1893 | nil))) | ||
| 1894 | 1887 | ||
| 1895 | (defun vc-diff-internal (backend async files rev1 rev2 &optional verbose) | 1888 | (defun vc-diff-internal (backend async files rev1 rev2 &optional verbose) |
| 1896 | "Report diffs between two revisions of a fileset. | 1889 | "Report diffs between two revisions of a fileset. |
| @@ -1927,12 +1920,20 @@ returns t if the buffer had changes, nil otherwise." | |||
| 1927 | (let ((vc-disable-async-diff (not async))) | 1920 | (let ((vc-disable-async-diff (not async))) |
| 1928 | (vc-call-backend backend 'diff filtered rev1 rev2 "*vc-diff*"))) | 1921 | (vc-call-backend backend 'diff filtered rev1 rev2 "*vc-diff*"))) |
| 1929 | (set-buffer "*vc-diff*") | 1922 | (set-buffer "*vc-diff*") |
| 1930 | ;; This odd-looking code is because in the non-async case we | 1923 | (if (and (zerop (buffer-size)) |
| 1931 | ;; actually want to pass the return value from vc-diff-sentinel | 1924 | (not (get-buffer-process (current-buffer)))) |
| 1932 | ;; back to the caller. | 1925 | ;; Treat this case specially so as not to pop the buffer. |
| 1933 | (if async | 1926 | (progn |
| 1934 | (vc-exec-after `(vc-diff-sentinel ,verbose ,rev1-name ,rev2-name)) | 1927 | (message "No changes between %s and %s" rev1-name rev2-name) |
| 1935 | (vc-diff-sentinel verbose rev1-name rev2-name)))) | 1928 | nil) |
| 1929 | (pop-to-buffer (current-buffer)) | ||
| 1930 | ;; Gnus-5.8.5 sets up an autoload for diff-mode, even if it's | ||
| 1931 | ;; not available. Work around that. | ||
| 1932 | (if (require 'diff-mode nil t) (diff-mode)) | ||
| 1933 | (vc-exec-after `(vc-diff-sentinel ,verbose ,rev1-name ,rev2-name)) | ||
| 1934 | ;; In the async case, we return t even if there are no differences | ||
| 1935 | ;; because we don't know that yet. | ||
| 1936 | t))) | ||
| 1936 | 1937 | ||
| 1937 | ;;;###autoload | 1938 | ;;;###autoload |
| 1938 | (defun vc-history-diff (backend files rev1 rev2) | 1939 | (defun vc-history-diff (backend files rev1 rev2) |
| @@ -3031,10 +3032,7 @@ to provide the `find-revision' operation instead." | |||
| 3031 | (vc-register))) | 3032 | (vc-register))) |
| 3032 | 3033 | ||
| 3033 | (defalias 'vc-default-logentry-check 'ignore) | 3034 | (defalias 'vc-default-logentry-check 'ignore) |
| 3034 | 3035 | (defalias 'vc-default-check-headers 'ignore) | |
| 3035 | (defun vc-default-check-headers (backend) | ||
| 3036 | "Default implementation of check-headers; always returns nil." | ||
| 3037 | nil) | ||
| 3038 | 3036 | ||
| 3039 | (defun vc-default-log-view-mode (backend) (log-view-mode)) | 3037 | (defun vc-default-log-view-mode (backend) (log-view-mode)) |
| 3040 | 3038 | ||
| @@ -3116,7 +3114,7 @@ to provide the `find-revision' operation instead." | |||
| 3116 | (and (not vc-make-backup-files) (delete-file backup-name)))))) | 3114 | (and (not vc-make-backup-files) (delete-file backup-name)))))) |
| 3117 | (message "Checking out %s...done" file)))) | 3115 | (message "Checking out %s...done" file)))) |
| 3118 | 3116 | ||
| 3119 | (defun vc-default-revision-completion-table (backend file) nil) | 3117 | (defalias 'vc-default-revision-completion-table 'ignore) |
| 3120 | 3118 | ||
| 3121 | (defun vc-check-headers () | 3119 | (defun vc-check-headers () |
| 3122 | "Check if the current file has any headers in it." | 3120 | "Check if the current file has any headers in it." |