Fix two bugs from introducing the item abstraction.

* magit.el (magit-unstage-item): It's magit-diff-or-hunk-item-file,
not magit-diffor-hunk-item-file, stupid.
(magit-visit-item): magit-diff-item-position does not exist, use nil
instead.
This commit is contained in:
Marius Vollmer 2008-08-21 22:58:33 +03:00
parent 52abed7629
commit ea626dbb0e
2 changed files with 3 additions and 2 deletions

View file

@ -727,7 +727,7 @@ Please see the manual for a complete description of Magit.
(magit-run "git" "apply" "--cached" "--reverse" ".git/magit-tmp"))
((diff)
(magit-run "git" "reset" "HEAD"
(magit-diffor-hunk-item-file item)))))))
(magit-diff-or-hunk-item-file item)))))))
(defun magit-stage-all ()
(interactive)
@ -1084,7 +1084,7 @@ Please see the manual for a complete description of Magit.
(let ((file (magit-diff-or-hunk-item-file item))
(line (if (eq (magit-item-type item) 'hunk)
(magit-hunk-item-target-line item)
(magit-diff-item-position item))))
nil)))
(find-file file)
(if line
(goto-line line))))

View file

@ -29,6 +29,7 @@ as an extension to Emacs.
@menu
* Introduction::
* Acknowledgments::
* Status::
* History::
* Diffing::