Index: openacs-4/packages/xowiki/www/prototypes/news.page =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/www/prototypes/news.page,v diff -u -r1.3 -r1.4 --- openacs-4/packages/xowiki/www/prototypes/news.page 19 Nov 2007 12:41:02 -0000 1.3 +++ openacs-4/packages/xowiki/www/prototypes/news.page 21 Nov 2007 10:23:11 -0000 1.4 @@ -13,13 +13,14 @@ {-ptag ""} {-entries_of en:news-item} } - - # The name filter is not the most efficient way of selecting - # autonamed entries. However, most times the number of news items - # is not overwhelming, so we can live with that for the time being. - # TODO: more efficient selection of autonamed entries # + # Don't add the footer (with tags, general comments, etc.) to the + # aggregated page, since this can be confusing.. + # + [my info parent] set __no_footer 1 + + # # The following definition is the default rendering per # news entry. This is executed in the context of every displayed page. # @@ -48,11 +49,11 @@ } # - # The following definition is the renderer for the full weblog. + # The following definition is the renderer for the aggregated content. # This is executed in the context of the whole weblog object # Class create NewsRenderer -instproc render {} { - my instvar filter_msg link name prev_page_link next_page_link title + my instvar filter_msg link name prev_page_link next_page_link title package_id set filter "" set prev "" @@ -71,10 +72,21 @@ Next Page" } + # + # Include the RSS Button + # set page [my set __page] - set rss [$page include \ - "rss-button -title {[$page title]} -entries_of [my entries_of]"] - #set rss [list [self] [lsort [my info vars]]] + set rss [$page include "rss-button -title {[$page title]} -entries_of [my entries_of] -decoration none"] + # + # If the user has creation rights (on the first form), include the RSS Bookmarklet button + # + if {[my exists form_items]} { + set can_create_news_item [$package_id make_link [lindex [my set form_items] 0] create-new return_url] + if {$can_create_news_item ne ""} { + append rss "Bookmarklet: " [$page include "bookmarklet-button -label {[$page title]}"] + } + } + return "
$filter [next] $prev $next
$rss
" }