[seam-commits] Seam SVN: r7176 - in trunk/examples/wiki: src/main/org/jboss/seam/wiki/core/action/prefs and 5 other directories.
seam-commits at lists.jboss.org
seam-commits at lists.jboss.org
Tue Jan 22 01:46:49 EST 2008
Author: christian.bauer at jboss.com
Date: 2008-01-22 01:46:48 -0500 (Tue, 22 Jan 2008)
New Revision: 7176
Modified:
trunk/examples/wiki/src/etc/messages_en.properties
trunk/examples/wiki/src/main/org/jboss/seam/wiki/core/action/prefs/WikiPreferences.java
trunk/examples/wiki/src/test/org/jboss/seam/wiki/test/WikiBaseData.dbunit.xml
trunk/examples/wiki/view/plugins/feedAggregator/plugin.xhtml
trunk/examples/wiki/view/themes/default/template.xhtml
trunk/examples/wiki/view/themes/sfwkorg/css/mainMenu.css
trunk/examples/wiki/view/themes/sfwkorg/template.xhtml
Log:
Configuration switch for site feed in main menu
Modified: trunk/examples/wiki/src/etc/messages_en.properties
===================================================================
--- trunk/examples/wiki/src/etc/messages_en.properties 2008-01-22 05:30:17 UTC (rev 7175)
+++ trunk/examples/wiki/src/etc/messages_en.properties 2008-01-22 06:46:48 UTC (rev 7176)
@@ -666,6 +666,7 @@
lacewiki.preferences.wiki.MainMenuShowAdminOnly=Main menu includes only directories owned by system administrator
lacewiki.preferences.wiki.ShowDocumentCreatorHistory=Show document creator/edit history in document footer
lacewiki.preferences.wiki.ShowTags=Show document tags in document footer
+lacewiki.preferences.wiki.ShowSiteFeedInMenu=Show global site feed in main menu
lacewiki.preferences.userManagement.Name=Core: User Management
lacewiki.preferences.userManagement.ActivationCodeSalt=Secret salt used to generate activation codes
Modified: trunk/examples/wiki/src/main/org/jboss/seam/wiki/core/action/prefs/WikiPreferences.java
===================================================================
--- trunk/examples/wiki/src/main/org/jboss/seam/wiki/core/action/prefs/WikiPreferences.java 2008-01-22 05:30:17 UTC (rev 7175)
+++ trunk/examples/wiki/src/main/org/jboss/seam/wiki/core/action/prefs/WikiPreferences.java 2008-01-22 06:46:48 UTC (rev 7176)
@@ -118,6 +118,12 @@
private Long purgeFeedEntriesAfterDays;
@PreferenceProperty(
+ description = "#{messages['lacewiki.preferences.wiki.ShowSiteFeedInMenu']}",
+ visibility = PreferenceVisibility.SYSTEM
+ )
+ private Boolean showSiteFeedInMenu;
+
+ @PreferenceProperty(
description = "#{messages['lacewiki.preferences.wiki.AtSymbolReplacement']}",
visibility = PreferenceVisibility.SYSTEM,
editorIncludeName = "AdaptiveTextInput"
@@ -212,6 +218,10 @@
return purgeFeedEntriesAfterDays;
}
+ public Boolean getShowSiteFeedInMenu() {
+ return showSiteFeedInMenu;
+ }
+
public String getAtSymbolReplacement() {
return atSymbolReplacement;
}
Modified: trunk/examples/wiki/src/test/org/jboss/seam/wiki/test/WikiBaseData.dbunit.xml
===================================================================
--- trunk/examples/wiki/src/test/org/jboss/seam/wiki/test/WikiBaseData.dbunit.xml 2008-01-22 05:30:17 UTC (rev 7175)
+++ trunk/examples/wiki/src/test/org/jboss/seam/wiki/test/WikiBaseData.dbunit.xml 2008-01-22 06:46:48 UTC (rev 7176)
@@ -20,6 +20,7 @@
<PREFERENCE PREF_ID = "16" OBJ_VERSION = "0" USER_ID = "[NULL]" ENTITY_NAME = "Wiki" PROPERTY_NAME = "showTags" STRING_VALUE = "[NULL]" LONG_VALUE = "[NULL]" BOOLEAN_VALUE = "true"/>
<PREFERENCE PREF_ID = "17" OBJ_VERSION = "0" USER_ID = "[NULL]" ENTITY_NAME = "Wiki" PROPERTY_NAME = "showEmailToLoggedInOnly" STRING_VALUE = "[NULL]" LONG_VALUE = "[NULL]" BOOLEAN_VALUE = "true"/>
<PREFERENCE PREF_ID = "18" OBJ_VERSION = "0" USER_ID = "[NULL]" ENTITY_NAME = "Wiki" PROPERTY_NAME = "trashArea" STRING_VALUE = "Trash" LONG_VALUE = "[NULL]" BOOLEAN_VALUE = "[NULL]"/>
+ <PREFERENCE PREF_ID = "19" OBJ_VERSION = "0" USER_ID = "[NULL]" ENTITY_NAME = "Wiki" PROPERTY_NAME = "showSiteFeedInMenu" STRING_VALUE = "[NULL]" LONG_VALUE = "[NULL]" BOOLEAN_VALUE = "true"/>
<PREFERENCE PREF_ID = "20" OBJ_VERSION = "0" USER_ID = "[NULL]" ENTITY_NAME = "DocEditor" PROPERTY_NAME = "minorRevisionEnabled" STRING_VALUE = "[NULL]" LONG_VALUE = "[NULL]" BOOLEAN_VALUE = "true"/>
<PREFERENCE PREF_ID = "21" OBJ_VERSION = "0" USER_ID = "[NULL]" ENTITY_NAME = "DocEditor" PROPERTY_NAME = "regularEditAreaRows" STRING_VALUE = "[NULL]" LONG_VALUE = "15" BOOLEAN_VALUE = "[NULL]"/>
Modified: trunk/examples/wiki/view/plugins/feedAggregator/plugin.xhtml
===================================================================
--- trunk/examples/wiki/view/plugins/feedAggregator/plugin.xhtml 2008-01-22 05:30:17 UTC (rev 7175)
+++ trunk/examples/wiki/view/plugins/feedAggregator/plugin.xhtml 2008-01-22 06:46:48 UTC (rev 7176)
@@ -34,7 +34,7 @@
<s:span styleClass="undecoratedLink"
rendered="#{not preferences.get('FeedAggregator', currentMacro).hideAuthor}">
<h:outputText value=", #{messages['feedAggregator.label.By']} "/>
- <h:outputText styleClass="feedEntryAuthor" value="#{feDTO.feedEntry.author}"/>
+ <h:outputText styleClass="feedEntryAuthor" value="#{wiki:escapeAtSymbol(feDTO.feedEntry.author)}"/>
</s:span>
<s:span styleClass="undecoratedLink"
@@ -49,13 +49,13 @@
<s:div styleClass="feedEntryTitle undecoratedLink"
rendered="#{not preferences.get('FeedAggregator', currentMacro).hideTitle}">
<h:outputLink target="_top" value="#{feDTO.feedEntry.link}">
- <h:outputText escape="false" value="#{feDTO.feedEntry.titleStripped}"/>
+ <h:outputText escape="false" value="#{wiki:escapeAtSymbol(feDTO.feedEntry.titleStripped)}"/>
</h:outputLink>
</s:div>
<s:div styleClass="feedEntryBody" rendered="#{not preferences.get('FeedAggregator', currentMacro).hideDescription}">
<h:outputText escape="false"
- value="#{wiki:truncateStringOnWordBoundary(feDTO.feedEntry.descriptionValueStrippedNoNewlines,
+ value="#{wiki:truncateStringOnWordBoundary(wiki:escapeAtSymbol(feDTO.feedEntry.descriptionValueStrippedNoNewlines),
preferences.get('FeedAggregator', currentMacro).truncateDescription)}"/>
<h:outputLink target="_top" styleClass="feedEntryBodyMoreLink"
Modified: trunk/examples/wiki/view/themes/default/template.xhtml
===================================================================
--- trunk/examples/wiki/view/themes/default/template.xhtml 2008-01-22 05:30:17 UTC (rev 7175)
+++ trunk/examples/wiki/view/themes/default/template.xhtml 2008-01-22 06:46:48 UTC (rev 7176)
@@ -329,7 +329,7 @@
<ui:include src="../../includes/searchControl.xhtml"/>
</ui:define>
<ui:define name="mainMenuFooter">
- <s:div styleClass="feeds">
+ <s:div styleClass="feeds" rendered="#{preferences.get('Wiki').showSiteFeedInMenu}">
<h:outputLink value="#{wiki:renderFeedURL(wikiRoot.feed, null, null)}">
<h:graphicImage value="/themes/#{preferences.get('Wiki').themeName}/img/icon.atom.gif" width="18" height="18"/>
<span class="feedText">#{messages['lacewiki.button.SiteFeed']}</span>
Modified: trunk/examples/wiki/view/themes/sfwkorg/css/mainMenu.css
===================================================================
--- trunk/examples/wiki/view/themes/sfwkorg/css/mainMenu.css 2008-01-22 05:30:17 UTC (rev 7175)
+++ trunk/examples/wiki/view/themes/sfwkorg/css/mainMenu.css 2008-01-22 06:46:48 UTC (rev 7176)
@@ -85,6 +85,7 @@
padding-top: 2px;
padding-bottom: 2px;
padding-left: 10px;
+ display: none;
}
#mainMenu .mainMenuFooter .feeds {
Modified: trunk/examples/wiki/view/themes/sfwkorg/template.xhtml
===================================================================
--- trunk/examples/wiki/view/themes/sfwkorg/template.xhtml 2008-01-22 05:30:17 UTC (rev 7175)
+++ trunk/examples/wiki/view/themes/sfwkorg/template.xhtml 2008-01-22 06:46:48 UTC (rev 7176)
@@ -309,7 +309,8 @@
<ui:define name="mainMenuHeader">
</ui:define>
<ui:define name="mainMenuFooter">
- <h:panelGrid columns="2" cellpadding="0" cellspacing="0" border="0" styleClass="feeds">
+ <h:panelGrid columns="2" cellpadding="0" cellspacing="0" border="0" styleClass="feeds"
+ rendered="#{preferences.get('Wiki').showSiteFeedInMenu}">
<h:outputLink styleClass="feedLink" value="#{wiki:renderFeedURL(wikiRoot.feed, null, null)}">
<h:graphicImage styleClass="feedIcon" value="/themes/#{preferences.get('Wiki').themeName}/img/icon.atom.onbrown.gif" width="18" height="18"/>
</h:outputLink>
More information about the seam-commits
mailing list