changeset 100492:afc7ba4fff7a

newsticker: fixed problem with missing group definition
author Ulf Jasper <ulf.jasper@web.de>
date Thu, 18 Dec 2008 10:54:21 +0000
parents 4133b0eeae68
children 49ff78cafea2
files lisp/ChangeLog lisp/net/newst-backend.el lisp/net/newst-treeview.el
diffstat 3 files changed, 28 insertions(+), 15 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Thu Dec 18 10:39:11 2008 +0000
+++ b/lisp/ChangeLog	Thu Dec 18 10:54:21 2008 +0000
@@ -1,3 +1,12 @@
+2008-12-18  Ulf Jasper  <ulf.jasper@web.de>
+
+	* net/newst-treeview.el (newsticker-groups-filename): Made obsolete.
+	(newsticker-treeview-quit): Call `newsticker-treeview-save'.
+	(newsticker--treeview-load): Check whether groups file exists.
+
+	* net/newst-backend.el (newsticker-cache-filename): Made obsolete.
+	(newsticker-dir): Use `locate-user-emacs-file'.
+
 2008-12-18  Martin Rudalics  <rudalics@gmx.at>
 
 	* emulation/cua-base.el (cmd): Add beginning-of-visual-line and
@@ -703,7 +712,7 @@
 	* calendar/appt.el (appt-disp-window): Do a set-buffer when the
 	frame can't be split.
 
-2008-11-24  Ulf Jasper  <ulf@web.de>
+2008-11-24  Ulf Jasper  <ulf.jasper@web.de>
 
 	* net/newst-treeview.el (newsticker--treeview-current-feed): Docstring.
 	(newsticker--treeview-item-show): Rename arg FEED to FEED-NAME-SYMBOL.
@@ -2404,7 +2413,7 @@
 	* kmacro.el (kmacro-edit-lossage): Ditto.
 	* edmacro.el (edit-kbd-macro): Ditto.
 
-2008-10-11  Ulf Jasper  <ulf@web.de>
+2008-10-11  Ulf Jasper  <ulf.jasper@web.de>
 
 	* net/newst-treeview.el (newsticker--treeview-list-sort-by-column):
 	Fix variable names.
@@ -3748,7 +3757,7 @@
 	(facemenu-keymap): Bind "\es" to `center-line' and "\eS" to
 	`center-paragraph'.
 
-2008-08-25  Ulf Jasper  <ulf@web.de>
+2008-08-25  Ulf Jasper  <ulf.jasper@web.de>
 
 	* net/newst-treeview.el (newsticker-treeview-own-frame): Doc fixed.
 	(newsticker-treeview-treewindow-width): New.
@@ -5311,7 +5320,7 @@
 	* net/browse-url.el (browse-url-default-browser):
 	Fix argument list in lambda.
 
-2008-07-07  Ulf Jasper  <ulf@web.de>
+2008-07-07  Ulf Jasper  <ulf.jasper@web.de>
 
 	* net/newst-backend.el (newsticker--get-news-by-url): Catch errors
 	from url-retrieve.
@@ -6012,7 +6021,7 @@
 	(COMPILE_FIRST): List the elc files rather than the el files.
 	(ELCFILES): Update.
 
-2008-06-21  Ulf Jasper  <ulf@web.de>
+2008-06-21  Ulf Jasper  <ulf.jasper@web.de>
 
 	* net/newst-treeview.el: Remove dead code.
 	(newsticker--window-config): Remove.
@@ -6098,7 +6107,7 @@
 	* emacs-lisp/checkdoc.el (checkdoc-start-section, checkdoc-error):
 	Bind inhibit-read-only since the buffer is always read-only.
 
-2008-06-20  Ulf Jasper  <ulf@web.de>
+2008-06-20  Ulf Jasper  <ulf.jasper@web.de>
 
 	* net/newst-treeview.el (newsticker-treeview-own-frame):
 	Change default value to nil.
@@ -6351,7 +6360,7 @@
 	* net/tramp-cmds.el (tramp-cleanup-all-connections):
 	Reset `tramp-locked'.
 
-2008-06-15  Ulf Jasper  <ulf@web.de>
+2008-06-15  Ulf Jasper  <ulf.jasper@web.de>
 
 	* net/newst-treeview.el (newsticker--treeview-list-update)
 	(newsticker--treeview-item-update)
@@ -6370,7 +6379,7 @@
 
 	* wdired.el (wdired-search-and-rename): Fix undocumented change.
 
-2008-06-15  Ulf Jasper  <ulf@web.de>
+2008-06-15  Ulf Jasper  <ulf.jasper@web.de>
 
 	* net/newst-plainview.el (newsticker-faces, newsticker-feed-face)
 	(newsticker-extra-face, newsticker-enclosure-face): Moved to
--- a/lisp/net/newst-backend.el	Thu Dec 18 10:39:11 2008 +0000
+++ b/lisp/net/newst-backend.el	Thu Dec 18 10:54:21 2008 +0000
@@ -7,7 +7,7 @@
 ;; Filename:    newst-backend.el
 ;; URL:         http://www.nongnu.org/newsticker
 ;; Keywords:    News, RSS, Atom
-;; Time-stamp:  "24. November 2008, 19:39:24 (ulf)"
+;; Time-stamp:  "28. November 2008, 19:55:34 (ulf)"
 
 ;; ======================================================================
 
@@ -423,11 +423,12 @@
   "Name of the newsticker cache file."
   :type 'string
   :group 'newsticker-miscellaneous)
+(make-obsolete 'newsticker-cache-filename 'newsticker-dir)
 
 (defcustom newsticker-dir
-  "~/.newsticker"
-  "Name of the directory where newsticker saves cached data."
-  :type 'string
+  (locate-user-emacs-file "newsticker/" ".newsticker/")
+  "Directory where newsticker saves data."
+  :type 'directory
   :group 'newsticker-miscellaneous)
 
 ;; debugging
--- a/lisp/net/newst-treeview.el	Thu Dec 18 10:39:11 2008 +0000
+++ b/lisp/net/newst-treeview.el	Thu Dec 18 10:54:21 2008 +0000
@@ -7,7 +7,7 @@
 ;; URL:         http://www.nongnu.org/newsticker
 ;; Created:     2007
 ;; Keywords:    News, RSS, Atom
-;; Time-stamp:  "24. November 2008, 19:49:20 (ulf)"
+;; Time-stamp:  "18. Dezember 2008, 11:26:54 (ulf)"
 
 ;; ======================================================================
 
@@ -143,6 +143,7 @@
   "Name of the newsticker groups settings file."
   :type 'string
   :group 'newsticker-treeview)
+(make-obsolete 'newsticker-groups-filename 'newsticker-dir)
 
 ;; ======================================================================
 ;;; internal variables
@@ -1230,7 +1231,8 @@
   (when newsticker--frame
     (if (frame-live-p newsticker--frame)
       (delete-frame newsticker--frame))
-    (setq newsticker--frame nil)))
+    (setq newsticker--frame nil))
+  (newsticker-treeview-save))
 
 (defun newsticker-treeview-save ()
   "Save newsticker data including treeview settings."
@@ -1256,7 +1258,8 @@
                             newsticker-groups-filename))
                    newsticker-groups-filename)
               (concat newsticker-dir "/groups")))
-         (buf (find-file-noselect filename)))
+         (buf (and (file-exists-p filename)
+                   (find-file-noselect filename))))
     (when buf
       (set-buffer buf)
       (goto-char (point-min))