From: <fg...@us...> - 2009-01-31 22:25:08
|
Revision: 973 http://openutils.svn.sourceforge.net/openutils/?rev=973&view=rev Author: fgiust Date: 2009-01-31 21:46:57 +0000 (Sat, 31 Jan 2009) Log Message: ----------- minor cleanups Modified Paths: -------------- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/configuration/MessagesConfigurationManager.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/ExtractMessagesFromDialogsPage.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesEditPage.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesImpExpPage.java Added Paths: ----------- trunk/openutils-mgnlmessages/src/site/ trunk/openutils-mgnlmessages/src/site/apt/ trunk/openutils-mgnlmessages/src/site/apt/index.apt trunk/openutils-mgnlmessages/src/site/changes/ trunk/openutils-mgnlmessages/src/site/changes/changes.xml trunk/openutils-mgnlmessages/src/site/resources/ trunk/openutils-mgnlmessages/src/site/resources/images/ trunk/openutils-mgnlmessages/src/site/resources/images/gui.png trunk/openutils-mgnlmessages/src/site/site.xml Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/configuration/MessagesConfigurationManager.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/configuration/MessagesConfigurationManager.java 2009-01-31 20:56:29 UTC (rev 972) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/configuration/MessagesConfigurationManager.java 2009-01-31 21:46:57 UTC (rev 973) @@ -23,8 +23,6 @@ import net.sourceforge.openutils.mgnlmessages.lifecycle.MessagesModuleLifecycle; import org.apache.commons.lang.StringUtils; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; /** @@ -38,8 +36,6 @@ */ public static final ItemType FOLDER = ItemType.CONTENT; - private Logger log = LoggerFactory.getLogger(MessagesConfigurationManager.class); - private List<Locale> locales = new ArrayList<Locale>(); /** @@ -181,7 +177,7 @@ /** * Sets the languages. - * @param languages the languages to set + * @param locales the languages to set */ public void setLocales(List<Locale> locales) { Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java 2009-01-31 20:56:29 UTC (rev 972) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java 2009-01-31 21:46:57 UTC (rev 973) @@ -13,8 +13,8 @@ import java.util.ResourceBundle; import org.apache.commons.collections.IteratorUtils; +import org.apache.commons.io.IOUtils; import org.apache.commons.lang.StringUtils; -import org.apache.commons.io.IOUtils; /** @@ -115,6 +115,9 @@ return bundle; } + /** + * {@inheritDoc} + */ public void reload() throws Exception { this.bundle = null; @@ -122,6 +125,7 @@ /** * Iterate over the keys + * @return iterator */ @SuppressWarnings("unchecked") public Iterator keys() Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/ExtractMessagesFromDialogsPage.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/ExtractMessagesFromDialogsPage.java 2009-01-31 20:56:29 UTC (rev 972) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/ExtractMessagesFromDialogsPage.java 2009-01-31 21:46:57 UTC (rev 973) @@ -55,6 +55,7 @@ /** * {@inheritDoc} */ + @SuppressWarnings("unchecked") @Override public String show() { @@ -83,12 +84,16 @@ } catch (RepositoryException e) { - + // ignore } return super.show(); } + /** + * Extract messages keys + * @return view + */ public String extract() { HierarchyManager hmConfig = MgnlContext.getHierarchyManager(ContentRepository.CONFIG); @@ -96,7 +101,6 @@ HierarchyManager hm = MgnlContext.getHierarchyManager(MessagesModuleLifecycle.REPO); for (String dialogRoot : this.request.getParameterValues("dialogsRoots")) { - Query q; try { doExtraction(dialogRoot, "label", qm, hm, hmConfig); @@ -128,6 +132,7 @@ return this.show(); } + @SuppressWarnings("unchecked") private void doExtraction(String root, String property, QueryManager qm, HierarchyManager hmMessages, HierarchyManager hmConfig) throws RepositoryException { Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesEditPage.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesEditPage.java 2009-01-31 20:56:29 UTC (rev 972) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesEditPage.java 2009-01-31 21:46:57 UTC (rev 973) @@ -4,7 +4,6 @@ import info.magnolia.cms.core.HierarchyManager; import info.magnolia.cms.core.ItemType; import info.magnolia.cms.core.Path; -import info.magnolia.cms.exchange.ExchangeException; import info.magnolia.context.MgnlContext; import info.magnolia.module.admininterface.TemplatedMVCHandler; @@ -71,17 +70,16 @@ /** * {@inheritDoc} */ - @SuppressWarnings("unchecked") @Override public void init() { - super.init(); } /** * {@inheritDoc} */ + @SuppressWarnings("unchecked") @Override public void renderHtml(String view) throws IOException { @@ -210,8 +208,6 @@ * move a node (from AdminTreeMVCHandler copymoveNode) * @param source source node * @param destination destination folder - * @return new content - * @throws ExchangeException publication problem * @throws RepositoryException repository exception */ protected void moveNode(String source, String destination) throws RepositoryException Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesImpExpPage.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesImpExpPage.java 2009-01-31 20:56:29 UTC (rev 972) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesImpExpPage.java 2009-01-31 21:46:57 UTC (rev 973) @@ -52,7 +52,7 @@ */ private Logger log = LoggerFactory.getLogger(MessagesImpExpPage.class); - Document uploadFile; + private Document uploadFile; /** * @param name @@ -64,6 +64,10 @@ super(name, request, response); } + /** + * Export translations to an excel file + * @return view + */ @SuppressWarnings("unchecked") public String exportExcel() { @@ -90,7 +94,7 @@ Messages mc = new MessagesChain(new RepositoryMessagesImpl(MessagesManager.DEFAULT_BASENAME, locale)) .chain(new ModulePropertyMessagesImpl(locale)); - ; + for (String basename : MessagesConfigurationManager.getBaseNames()) { ((MessagesChain) mc).chain(new DefaultMessagesImpl(basename, locale)); @@ -150,6 +154,10 @@ return null; } + /** + * Import an excel file. + * @return view name + */ public String importExcel() { FileInputStream fis; Added: trunk/openutils-mgnlmessages/src/site/apt/index.apt =================================================================== --- trunk/openutils-mgnlmessages/src/site/apt/index.apt (rev 0) +++ trunk/openutils-mgnlmessages/src/site/apt/index.apt 2009-01-31 21:46:57 UTC (rev 973) @@ -0,0 +1,35 @@ + -------------------------- + openutils-mgnlmessages + -------------------------- + Fabrizio Giustina + -------------------------- + +About openutils-mgnlmessages + + openutils-mgnlmessages is a custom {{{http://www.magnolia.info}magnolia}} module which adds a GUI for translating messages + inside the magnolia admin interface. + + This is how the translation page looks: + +[images/gui.png] + + +Installation + + <<This module currently requires magnolia 3.6.x>> + + The module needs to be installed as usual, by declaring an additional dependency into your pom or by manually dropping the jar + into magnolia. + + Unfortunately, for Magnolia 3.6 this module requires also patching one of the magnolia core classes, info.magnolia.cms.i18n.MessagesManager, + since there was no way to cleanly extend/replace it. + You may do that by copying the patched java source (you can find it in the module sources) to your java source folder for + your webapp (the compiled class file must end up in WEB-INF/classes in order to override the one found in the magnolia jars) + + This limitation will be removed after the module will be updated to magnolia 4.0, which allows the configuration of a + custom message manager. + + +Released versions + + {{{http://www.mvnrepository.com/artifact/net.sourceforge.openutils/openutils-mgnlmessages}http://www.mvnrepository.com/artifact/net.sourceforge.openutils/openutils-mgnlmessages}} Property changes on: trunk/openutils-mgnlmessages/src/site/apt/index.apt ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Added: trunk/openutils-mgnlmessages/src/site/changes/changes.xml =================================================================== --- trunk/openutils-mgnlmessages/src/site/changes/changes.xml (rev 0) +++ trunk/openutils-mgnlmessages/src/site/changes/changes.xml 2009-01-31 21:46:57 UTC (rev 973) @@ -0,0 +1,18 @@ +<?xml version="1.0"?> + <!-- + "type" attribute can be: add, remove, update or fix. +--> +<document> + <properties> + <title>Changes</title> + <author email="fgiust(at)users.sourceforge.net">Fabrizio Giustina</author> + </properties> + <body> + <release version="1.1" date="2009-01-31" description=""> + <action type="fix" dev="fgiust">minor bugfixes and basic documentation added</action> + </release> + <release version="1.0" date="2008-12-03" description="first release"> + <action type="new" dev="fgiust">Initial public release.</action> + </release> + </body> +</document> \ No newline at end of file Property changes on: trunk/openutils-mgnlmessages/src/site/changes/changes.xml ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Added: trunk/openutils-mgnlmessages/src/site/resources/images/gui.png =================================================================== (Binary files differ) Property changes on: trunk/openutils-mgnlmessages/src/site/resources/images/gui.png ___________________________________________________________________ Added: svn:mime-type + image/png Added: trunk/openutils-mgnlmessages/src/site/site.xml =================================================================== --- trunk/openutils-mgnlmessages/src/site/site.xml (rev 0) +++ trunk/openutils-mgnlmessages/src/site/site.xml 2009-01-31 21:46:57 UTC (rev 973) @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="UTF-8"?> +<project name="Openutils mgnlmessages"> + <publishDate position="navigation-bottom" format="yyyy-MM-dd" /> + <version position="navigation-bottom" /> + <bannerRight> + <name>Openutils</name> + <src>http://openutils.sourceforge.net/images/openutils-logo.png + </src> + <href>http://openutils.sourceforge.net</href> + </bannerRight> + <bannerLeft> + <name>Sourceforge</name> + <src>http://sourceforge.net/sflogo.php?group_id=150467&amp;type=2</src> + <href>http://www.sourceforge.net/projects/openutils</href> + </bannerLeft> + <body> + <head> + <link rel="icon" href="images/favicon.ico" /> + </head> + <breadcrumbs> + <item name="openutils" href="http://openutils.sourceforge.net/" /> + <item name="openutils-mgnlmessages" href="http://openutils.sourceforge.net/openutils-mgnlmessages" /> + </breadcrumbs> + <menu name="openutils mgnlmessages"> + <item name="Intro" href="index.html"></item> + </menu> + <menu ref="modules" inherit="bottom" /> + <menu ref="reports" inherit="bottom" /> + </body> + <skin> + <groupId>net.sourceforge.openutils</groupId> + <artifactId>openutils-maven-skin</artifactId> + <version>1.1</version> + </skin> +</project> Property changes on: trunk/openutils-mgnlmessages/src/site/site.xml ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fg...@us...> - 2009-05-24 09:46:27
|
Revision: 1200 http://openutils.svn.sourceforge.net/openutils/?rev=1200&view=rev Author: fgiust Date: 2009-05-24 09:46:15 +0000 (Sun, 24 May 2009) Log Message: ----------- cleaned up Modified Paths: -------------- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/configuration/MessagesConfigurationManager.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/EmptyResourceBundle.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/ModulePropertyMessagesImpl.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/RepositoryMessagesImpl.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/lifecycle/MessagesModuleLifecycle.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/DefaultMessagesImpl.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/ExtractMessagesFromDialogsPage.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesEditPage.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesImpExpPage.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/setup/MessagesModuleVersionHandler.java trunk/openutils-mgnlmessages/src/site/apt/index.apt trunk/openutils-mgnlmessages/src/site/changes/changes.xml Added Paths: ----------- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/OpenutilsMessagesImpl.java trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/OpenutilsMgnlMessagesManager.java Removed Paths: ------------- trunk/openutils-mgnlmessages/src/main/java/info/ Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/configuration/MessagesConfigurationManager.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/configuration/MessagesConfigurationManager.java 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/configuration/MessagesConfigurationManager.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -1,3 +1,20 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ package net.sourceforge.openutils.mgnlmessages.configuration; import info.magnolia.cms.beans.config.ContentRepository; Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/EmptyResourceBundle.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/EmptyResourceBundle.java 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/EmptyResourceBundle.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -1,3 +1,20 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ package net.sourceforge.openutils.mgnlmessages.i18n; import java.util.Enumeration; Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/ModulePropertyMessagesImpl.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/ModulePropertyMessagesImpl.java 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/ModulePropertyMessagesImpl.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -1,3 +1,20 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ package net.sourceforge.openutils.mgnlmessages.i18n; import info.magnolia.cms.i18n.AbstractMessagesImpl; Added: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/OpenutilsMessagesImpl.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/OpenutilsMessagesImpl.java (rev 0) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/OpenutilsMessagesImpl.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -0,0 +1,42 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ +package net.sourceforge.openutils.mgnlmessages.i18n; + +import info.magnolia.cms.i18n.DefaultMessagesImpl; + +import java.util.Locale; + + +/** + * Needed just because DefaultMessagesImpl has a protected constructor. + * @author fgiust + * @version $Id$ + */ +public class OpenutilsMessagesImpl extends DefaultMessagesImpl +{ + + /** + * @param basename + * @param locale + */ + protected OpenutilsMessagesImpl(String basename, Locale locale) + { + super(basename, locale); + } + +} Property changes on: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/OpenutilsMessagesImpl.java ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Author Date Id Revision Added: svn:eol-style + native Copied: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/OpenutilsMgnlMessagesManager.java (from rev 1198, trunk/openutils-mgnlmessages/src/main/java/info/magnolia/cms/i18n/OpenutilsMgnlMessagesManager.java) =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/OpenutilsMgnlMessagesManager.java (rev 0) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/OpenutilsMgnlMessagesManager.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -0,0 +1,52 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ +package net.sourceforge.openutils.mgnlmessages.i18n; + +import info.magnolia.cms.i18n.DefaultMessagesManager; +import info.magnolia.cms.i18n.Messages; +import info.magnolia.cms.i18n.MessagesChain; +import info.magnolia.cms.i18n.MessagesManager; + + +/** + * @author molaschi + * @version $Id: $ + */ +public class OpenutilsMgnlMessagesManager extends DefaultMessagesManager +{ + + /** + * {@inheritDoc} + */ + @Override + protected Messages newMessages(MessagesID messagesID) + { + Messages msgs = new MessagesChain(new RepositoryMessagesImpl(messagesID.getBasename(), messagesID.getLocale())); + ((MessagesChain) msgs).chain(new ModulePropertyMessagesImpl(messagesID.getLocale())); + ((MessagesChain) msgs).chain(new OpenutilsMessagesImpl(messagesID.getBasename(), messagesID.getLocale())); + + if (!getDefaultLocale().equals(messagesID.getLocale())) + { + msgs = ((MessagesChain) msgs).chain(MessagesManager.getMessages( + messagesID.getBasename(), + getDefaultLocale())); + } + return msgs; + } + +} Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/RepositoryMessagesImpl.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/RepositoryMessagesImpl.java 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/RepositoryMessagesImpl.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -1,3 +1,20 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ package net.sourceforge.openutils.mgnlmessages.i18n; import info.magnolia.cms.core.Content; Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -1,3 +1,20 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ package net.sourceforge.openutils.mgnlmessages.i18n; import info.magnolia.cms.i18n.AbstractMessagesImpl; Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/lifecycle/MessagesModuleLifecycle.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/lifecycle/MessagesModuleLifecycle.java 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/lifecycle/MessagesModuleLifecycle.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -1,3 +1,20 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ package net.sourceforge.openutils.mgnlmessages.lifecycle; import info.magnolia.module.ModuleLifecycle; Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/DefaultMessagesImpl.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/DefaultMessagesImpl.java 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/DefaultMessagesImpl.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -1,3 +1,20 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ package net.sourceforge.openutils.mgnlmessages.pages; import info.magnolia.cms.util.ClasspathResourcesUtil; Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/ExtractMessagesFromDialogsPage.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/ExtractMessagesFromDialogsPage.java 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/ExtractMessagesFromDialogsPage.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -1,3 +1,20 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ package net.sourceforge.openutils.mgnlmessages.pages; import info.magnolia.cms.beans.config.ContentRepository; Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesEditPage.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesEditPage.java 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesEditPage.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -1,3 +1,20 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ package net.sourceforge.openutils.mgnlmessages.pages; import info.magnolia.cms.core.Content; Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesImpExpPage.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesImpExpPage.java 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/pages/MessagesImpExpPage.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -1,3 +1,20 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ package net.sourceforge.openutils.mgnlmessages.pages; import info.magnolia.cms.beans.runtime.Document; Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/setup/MessagesModuleVersionHandler.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/setup/MessagesModuleVersionHandler.java 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/setup/MessagesModuleVersionHandler.java 2009-05-24 09:46:15 UTC (rev 1200) @@ -1,3 +1,20 @@ +/** + * Copyright Openmind http://www.openmindonline.it + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see <http://www.gnu.org/licenses/>. + * + */ package net.sourceforge.openutils.mgnlmessages.setup; import it.openutils.mgnltasks.SimpleModuleVersionHandler; Modified: trunk/openutils-mgnlmessages/src/site/apt/index.apt =================================================================== --- trunk/openutils-mgnlmessages/src/site/apt/index.apt 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/site/apt/index.apt 2009-05-24 09:46:15 UTC (rev 1200) @@ -22,8 +22,11 @@ The module needs to be installed as usual, by declaring an additional dependency into your pom or by manually dropping the jar into magnolia. - + You also need to configure in magnolia.properties: + info.magnolia.cms.i18n.MessagesManager=net.sourceforge.openutils.mgnlmessages.i18n.OpenutilsMgnlMessagesManager + + Released versions {{{http://www.mvnrepository.com/artifact/net.sourceforge.openutils/openutils-mgnlmessages}http://www.mvnrepository.com/artifact/net.sourceforge.openutils/openutils-mgnlmessages}} Modified: trunk/openutils-mgnlmessages/src/site/changes/changes.xml =================================================================== --- trunk/openutils-mgnlmessages/src/site/changes/changes.xml 2009-05-24 09:36:15 UTC (rev 1199) +++ trunk/openutils-mgnlmessages/src/site/changes/changes.xml 2009-05-24 09:46:15 UTC (rev 1200) @@ -9,6 +9,10 @@ <author email="molaschi(at)users.sourceforge.net">Manuel Molaschi</author> </properties> <body> + <release version="4.0" date="2009-05-24" description=""> + <action type="update" dev="fgiust">Dependencies updated to magnolia 4.0.1, removed useless patches and classes with + the "info.magnolia" package</action> + </release> <release version="4.0-b3" date="2009-04-16" description=""> <action type="update" dev="fgiust">Stable release for Magnolia 4.x</action> </release> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <fg...@us...> - 2009-08-10 12:35:29
|
Revision: 1252 http://openutils.svn.sourceforge.net/openutils/?rev=1252&view=rev Author: fgiust Date: 2009-08-10 12:35:20 +0000 (Mon, 10 Aug 2009) Log Message: ----------- fix NPE for unloaded bundles Modified Paths: -------------- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java trunk/openutils-mgnlmessages/src/site/changes/changes.xml Modified: trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java =================================================================== --- trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java 2009-08-10 10:38:53 UTC (rev 1251) +++ trunk/openutils-mgnlmessages/src/main/java/net/sourceforge/openutils/mgnlmessages/i18n/SimpleMessagesImpl.java 2009-08-10 12:35:20 UTC (rev 1252) @@ -35,8 +35,8 @@ /** - * @author Philipp Bracher - * @version $Revision: 14052 $ ($Author: gjoseph $) + * @author fgiust + * @version $Id: $ */ public class SimpleMessagesImpl extends AbstractMessagesImpl { @@ -122,7 +122,10 @@ } catch (IOException e) { - log.error("can't load messages for " + basename); + log.error("can't load messages for " + basename, e); + + // bundle must never be null + bundle = new EmptyResourceBundle(); } finally { Modified: trunk/openutils-mgnlmessages/src/site/changes/changes.xml =================================================================== --- trunk/openutils-mgnlmessages/src/site/changes/changes.xml 2009-08-10 10:38:53 UTC (rev 1251) +++ trunk/openutils-mgnlmessages/src/site/changes/changes.xml 2009-08-10 12:35:20 UTC (rev 1252) @@ -9,6 +9,10 @@ <author email="molaschi(at)users.sourceforge.net">Manuel Molaschi</author> </properties> <body> + <release version="4.0.2" date="in svn" description=""> + <action type="fix" dev="fgiust">net.sourceforge.openutils.mgnlmessages.i18n.SimpleMessagesImpl could return a null + bundle in case of IOExceptions during loading: fixed</action> + </release> <release version="4.0.2" date="2009-05-24" description=""> <action type="update" dev="fgiust">Dependencies updated to magnolia 4.0.1, removed useless patches and classes with the "info.magnolia" package</action> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |