Skip to content

Commit

Permalink
remove last new line from message
Browse files Browse the repository at this point in the history
continuous message disables cursor-sensor-mode
  • Loading branch information
yuya373 committed Apr 8, 2018
1 parent 17ace51 commit 7fc9b27
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 8 deletions.
4 changes: 3 additions & 1 deletion slack-buffer.el
Expand Up @@ -144,7 +144,9 @@
(slack-message-to-string message team)
'not-tracked-p not-tracked-p
'ts (slack-ts message)
'slack-last-ts lui-time-stamp-last)))
'slack-last-ts lui-time-stamp-last)
(lui-insert "" t)
))

(defmethod slack-buffer-insert-load-more ((this slack-buffer))
(let ((str (propertize "(load more)\n"
Expand Down
5 changes: 4 additions & 1 deletion slack-file-info-buffer.el
Expand Up @@ -110,12 +110,15 @@
'file-id (oref file id)
'ts (slack-ts file))

(lui-insert "" t)

(let ((comments (slack-file-comments-to-string file team)))
(mapc #'(lambda (comment)
(lui-insert-with-text-properties
(slack-message-to-string comment team)
'file-comment-id (oref comment id)
'ts (slack-ts comment)))
'ts (slack-ts comment))
(lui-insert "" t))
(oref file comments)))))

(defmethod slack-buffer-send-message ((this slack-file-info-buffer) message)
Expand Down
7 changes: 3 additions & 4 deletions slack-message-formatter.el
Expand Up @@ -119,10 +119,9 @@

(defun slack-format-message (&rest args)
(let ((messages args))
(concat (mapconcat #'identity
(cl-remove-if #'(lambda (e) (< (length e) 1)) messages)
"\n")
"\n")))
(mapconcat #'identity
(cl-remove-if #'(lambda (e) (< (length e) 1)) messages)
"\n")))

(defmethod slack-message-profile-image ((m slack-message) team)
(slack-user-image (slack-user-find m team) team))
Expand Down
3 changes: 2 additions & 1 deletion slack-search-result-buffer.el
Expand Up @@ -60,7 +60,8 @@
(let* ((time (slack-ts-to-time (slack-ts match)))
(lui-time-stamp-time time)
(lui-time-stamp-format "[%Y-%m-%d %H:%M:%S]"))
(lui-insert (slack-message-to-string match team) t))))
(lui-insert (slack-message-to-string match team) t)
(lui-insert "" t))))

(defmethod slack-buffer-has-next-page-p ((this slack-search-result-buffer))
(with-slots (search-result) this
Expand Down
3 changes: 2 additions & 1 deletion slack-stars-buffer.el
Expand Up @@ -54,7 +54,8 @@
(lui-insert-with-text-properties
(slack-to-string item (oref this team))
'ts (slack-ts item)
'not-tracked-p not-tracked-p)))
'not-tracked-p not-tracked-p)
(lui-insert "" t)))

(defmethod slack-buffer-has-next-page-p ((this slack-stars-buffer))
(with-slots (team) this
Expand Down

0 comments on commit 7fc9b27

Please sign in to comment.