From e100775b03beef74cccf8b0340359967571d0133 Mon Sep 17 00:00:00 2001 From: Satoshi Yatagawa Date: Thu, 11 Mar 2010 23:41:07 +0900 Subject: [PATCH] (twittering-default-show-replied-tweets): new defvar. (twittering-render-timeline): use it instead of 'twittering-show-replied-tweets'. (twittering-toggle-show-replied-statuses): pass 'twittering-show-replied-tweets' into 'twittering-show-replied-statuses'. (twittering-show-replied-tweets): add a docstring. --- ChangeLog | 9 +++++++++ twittering-mode.el | 20 +++++++++++++++----- 2 files changed, 24 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7620fe35..71c2a9de 100644 --- a/ChangeLog +++ b/ChangeLog @@ -31,6 +31,15 @@ * twittering-mode.el (twittering-hide-replied-statuses): Go to the head of parent status before hiding replied statuses. + * twittering-mode.el (twittering-default-show-replied-tweets): New + defvar. + (twittering-render-timeline): Use it instead of + `twittering-show-replied-tweets'. + (twittering-toggle-show-replied-statuses): Pass + `twittering-show-replied-tweets' into + `twittering-show-replied-statuses'. + (twittering-show-replied-tweets): Add a docstring. + 2010-03-11 Tadashi MATSUO * twittering-mode.el (twittering-lookup-http-start-function): diff --git a/twittering-mode.el b/twittering-mode.el index 22897f6f..ded6c9a7 100644 --- a/twittering-mode.el +++ b/twittering-mode.el @@ -220,8 +220,18 @@ Items: %% - % ") -(defvar twittering-show-replied-tweets 0 - "*The number of replied tweets which will be showed in one tweet.") +(defvar twittering-show-replied-tweets t + "*The number of replied tweets which will be showed in one tweet. + +If the value is not a number and is non-nil, show all replied tweets +which is already fetched. +If the value is nil, doesn't show replied tweets.") + +(defvar twittering-default-show-replied-tweets nil + "*The number of default replied tweets which will be showed in one tweet. +This value will be used only when showing new tweets. + +See `twittering-show-replied-tweets' for more details.") (defvar twittering-use-show-minibuffer-length t "*Show current length of minibuffer if this variable is non-nil. @@ -2574,9 +2584,9 @@ If INTERRUPT is non-nil, the iteration is stopped if FUNC returns nil." ;; It must be moved to the current point ;; in order to skip the status inserted just now. (setq pos (point)) - (when twittering-show-replied-tweets + (when twittering-default-show-replied-tweets (twittering-show-replied-statuses - twittering-show-replied-tweets)))))) + twittering-default-show-replied-tweets)))))) timeline-data))) (if (and twittering-image-stack window-system) (clear-image-cache)) @@ -2706,7 +2716,7 @@ If INTERRUPT is non-nil, the iteration is stopped if FUNC returns nil." (interactive) (if (twittering-replied-statuses-visible-p) (twittering-hide-replied-statuses (interactive-p)) - (twittering-show-replied-statuses t ;; show all fetched statuses. + (twittering-show-replied-statuses twittering-show-replied-tweets (interactive-p)))) (defun twittering-make-display-spec-for-icon (image-url)