[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] master da721ab 33/36: Fixed compile warnings
From: |
Alexey Veretennikov |
Subject: |
[elpa] master da721ab 33/36: Fixed compile warnings |
Date: |
Wed, 27 Jan 2016 23:50:59 +0000 |
branch: master
commit da721ab7540174801c1cbef759e09dc202f8b699
Author: Alexey Veretennikov <address@hidden>
Commit: Alexey Veretennikov <address@hidden>
Fixed compile warnings
---
ztree-diff.el | 4 ++--
ztree-view.el | 24 +++++++++++-------------
2 files changed, 13 insertions(+), 15 deletions(-)
diff --git a/ztree-diff.el b/ztree-diff.el
index 006d7cf..3793cbb 100644
--- a/ztree-diff.el
+++ b/ztree-diff.el
@@ -445,8 +445,8 @@ COPY-TO-RIGHT specifies which side of the NODE to update."
(if delete-from-left
#'ztree-diff-node-set-left-path
#'ztree-diff-node-set-right-path)))
- (mapcar (lambda (x) (funcall update-fun x nil))
- (cons node (ztree-diff-node-children node))))
+ (mapc (lambda (x) (funcall update-fun x nil))
+ (cons node (ztree-diff-node-children node))))
;; and update diff status
;; if was ignored keep the old status
(unless (eql (ztree-diff-node-different node) 'ignore)
diff --git a/ztree-view.el b/ztree-view.el
index d1aa586..9e8920d 100644
--- a/ztree-view.el
+++ b/ztree-view.el
@@ -163,7 +163,9 @@ the buffer is split to 2 trees")
(define-derived-mode ztree-mode special-mode "Ztree"
"A major mode for displaying the directory tree in text mode."
;; only spaces
- (setq indent-tabs-mode nil))
+ (setq indent-tabs-mode nil)
+ (setq buffer-read-only t))
+
(defun ztree-find-node-in-line (line)
"Return the node for the LINE specified.
@@ -570,8 +572,7 @@ Optional argument FACE face to write text with."
(delete-region (point) (line-end-position))
;; every indentation level is 4 characters
(when (> depth 0)
- (dotimes (i depth)
- (insert-char ?\s 4))) ; insert 4 spaces
+ (insert-char ?\s (* 4 depth))) ; insert 4 spaces
(when (> (length short-name) 0)
(let ((start-pos (point)))
(if expandable
@@ -606,13 +607,12 @@ Optional argument LINE scroll to the line given."
;; used in 2-side tree mode
(when ztree-node-side-fun
(setq ztree-line-tree-properties (make-hash-table)))
- (toggle-read-only)
- (erase-buffer)
- (funcall ztree-tree-header-fun)
- (setq ztree-start-line (line-number-at-pos (point)))
- (ztree-insert-node-contents ztree-start-node)
- (scroll-to-line (if line line ztree-start-line))
- (toggle-read-only)))
+ (let ((buffer-read-only nil))
+ (erase-buffer)
+ (funcall ztree-tree-header-fun)
+ (setq ztree-start-line (line-number-at-pos (point)))
+ (ztree-insert-node-contents ztree-start-node)
+ (scroll-to-line (if line line ztree-start-line)))))
(defun ztree-view (
@@ -628,7 +628,6 @@ Optional argument LINE scroll to the line given."
action-fun
&optional
node-side-fun
- post-create-hook
)
"Create a ztree view buffer configured with parameters given.
Argument BUFFER-NAME Name of the buffer created.
@@ -643,8 +642,7 @@ Argument EQUAL-FUN An equality function for nodes.
Argument CHILDREN-FUN Function to get children from the node.
Argument FACE-FUN Function to determine face of the node.
Argument ACTION-FUN an action to perform when the Return is pressed.
-Optional argument NODE-SIDE-FUN Determines the side of the node.
-Optional argument POST-CREATE-FUN"
+Optional argument NODE-SIDE-FUN Determines the side of the node."
(let ((buf (get-buffer-create buffer-name)))
(switch-to-buffer buf)
(ztree-mode)
- [elpa] master 45dda44 14/36: Started updating diff logic to include ignored files, (continued)
- [elpa] master 45dda44 14/36: Started updating diff logic to include ignored files, Alexey Veretennikov, 2016/01/27
- [elpa] master 2dc412f 15/36: Added debug output and some other changes, Alexey Veretennikov, 2016/01/27
- [elpa] master 9408ca1 17/36: Fixed ztree-node-is-visible, Alexey Veretennikov, 2016/01/27
- [elpa] master eea3c2b 19/36: added comments, Alexey Veretennikov, 2016/01/27
- [elpa] master cef7d95 20/36: Functions with errors still:, Alexey Veretennikov, 2016/01/27
- [elpa] master 653a7f1 21/36: Fixed ignored files, Alexey Veretennikov, 2016/01/27
- [elpa] master a27dbbd 22/36: Started to fix issues with delete file, Alexey Veretennikov, 2016/01/27
- [elpa] master c3144bd 16/36: Updated model - ignored files still not handled, Alexey Veretennikov, 2016/01/27
- [elpa] master bc6a12a 18/36: Traverse function now supports ignored, Alexey Veretennikov, 2016/01/27
- [elpa] master b021697 29/36: Added comment to not to forget to update copy procedure., Alexey Veretennikov, 2016/01/27
- [elpa] master da721ab 33/36: Fixed compile warnings,
Alexey Veretennikov <=
- [elpa] master be4e000 24/36: Fix typo in value of Created header keyword, Alexey Veretennikov, 2016/01/27
- [elpa] master b5b2d02 32/36: removed test files, Alexey Veretennikov, 2016/01/27
- [elpa] master 74899aa 30/36: Merge branch 'master' of github.com:fourier/ztree, Alexey Veretennikov, 2016/01/27
- [elpa] master 6d7ce1f 28/36: Fixed Delete method, Alexey Veretennikov, 2016/01/27
- [elpa] master 3d70aef 25/36: Merge pull request #30 from tarsius/fix-typo, Alexey Veretennikov, 2016/01/27
- [elpa] master 159ddbd 26/36: Fixed partial update, Alexey Veretennikov, 2016/01/27
- [elpa] master a7c5489 35/36: Upgraded version number, Alexey Veretennikov, 2016/01/27
- [elpa] master 7b5dfce 23/36: Use defvar-local instead of combo defvar && make-variable-buffer-local, Alexey Veretennikov, 2016/01/27
- [elpa] master e143f66 27/36: Fixed copy of the files; added 'R' for full rescan, Alexey Veretennikov, 2016/01/27
- [elpa] master dbf9539 31/36: Fixed issue #27, Alexey Veretennikov, 2016/01/27