gatein SVN: r1488 - portal/branches/EPP_5_0_0_Branch_Docs/Enterprise_Portal_Platform_Reference_Guide/en-US.
by do-not-reply@jboss.org
Author: smumford
Date: 2010-02-02 01:37:51 -0500 (Tue, 02 Feb 2010)
New Revision: 1488
Modified:
portal/branches/EPP_5_0_0_Branch_Docs/Enterprise_Portal_Platform_Reference_Guide/en-US/Reference_Guide.ent
Log:
Edits to Chapter 4
Modified: portal/branches/EPP_5_0_0_Branch_Docs/Enterprise_Portal_Platform_Reference_Guide/en-US/Reference_Guide.ent
===================================================================
--- portal/branches/EPP_5_0_0_Branch_Docs/Enterprise_Portal_Platform_Reference_Guide/en-US/Reference_Guide.ent 2010-02-02 04:46:19 UTC (rev 1487)
+++ portal/branches/EPP_5_0_0_Branch_Docs/Enterprise_Portal_Platform_Reference_Guide/en-US/Reference_Guide.ent 2010-02-02 06:37:51 UTC (rev 1488)
@@ -1,4 +1,4 @@
-<!ENTITY PRODUCT "Enterprise Portal Platform 5.0">
+<!ENTITY PRODUCT "Enterprise Portal Platform">
<!ENTITY BOOKID "User Guide">
<!ENTITY YEAR "2010">
<!ENTITY HOLDER "Red Hat, Inc">
14 years, 11 months
gatein SVN: r1487 - portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web.
by do-not-reply@jboss.org
Author: tuancn
Date: 2010-02-01 23:46:19 -0500 (Mon, 01 Feb 2010)
New Revision: 1487
Removed:
portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_vi.xml
Log:
Replace this file with GroovyPortlet_vi.properties
Deleted: portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_vi.xml
===================================================================
--- portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_vi.xml 2010-02-02 04:40:53 UTC (rev 1486)
+++ portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_vi.xml 2010-02-02 04:46:19 UTC (rev 1487)
@@ -1,52 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-
- Copyright (C) 2009 eXo Platform SAS.
-
- This is free software; you can redistribute it and/or modify it
- under the terms of the GNU Lesser General Public License as
- published by the Free Software Foundation; either version 2.1 of
- the License, or (at your option) any later version.
-
- This software 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
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with this software; if not, write to the Free
- Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- 02110-1301 USA, or see the FSF site: http://www.fsf.org.
-
--->
-
-<bundle>
- <!--
- #####################################################################################
- # EXCEPTION MAPPINGS #
- #####################################################################################
- -->
- <UIGroovyPortlet>
- <note>
- <Text>This is Groovy Portlet (Sample Portlet) it can be developed as a web application in the future.</Text>
- </note>
- </UIGroovyPortlet>
- <UIIFrameEditMode>
- <title>Thay đổi URL</title>
- <label>
- <iframeUrl>URL</iframeUrl>
- <editmode>Chế độ chỉnh sửa</editmode>
- </label>
- <action>
- <Save>Lưu</Save>
- </action>
- </UIIFrameEditMode>
-
- <UIGroovyPortlet>
- <action>
- <changeLanguage>Thay ngôn ngữ</changeLanguage>
- <register>Register</register>
- </action>
- </UIGroovyPortlet>
-</bundle>
-
14 years, 11 months
gatein SVN: r1486 - portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web.
by do-not-reply@jboss.org
Author: tuancn
Date: 2010-02-01 23:40:53 -0500 (Mon, 01 Feb 2010)
New Revision: 1486
Added:
portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_vi.properties
Modified:
portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_en.properties
Log:
Additional features localized for a number of labels
Modified: portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_en.properties
===================================================================
--- portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_en.properties 2010-02-02 04:38:17 UTC (rev 1485)
+++ portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_en.properties 2010-02-02 04:40:53 UTC (rev 1486)
@@ -36,6 +36,12 @@
UIHomePagePortlet.Label.Title=Try GateIn 3.0 with one of these user accounts:
UIHomePagePortlet.Label.Intro=The new version comes with a revolutionary user interface<br/>Classic and WebOS Desktop Layouts<br/> Drag and Drop Features. Create Page Wizard<br/>And many more...
UIHomePagePortlet.Label.Slogan=The Best of eXo and JBoss Portal<div>GateIn 3.0 Beta 5</div>
+UIHomePagePortlet.Label.GuideText=For more information, please contact us.
+UIHomePagePortlet.Label.IntroText=GateIn is the new generation of Open Source portal, jointly led by Red Hat and eXo Platform who partner to gather the best portal experts and communities around a robust and intuitive portal that brings rich administration functionalities to IT systems.
+UIHomePagePortlet.Label.Administrator=Administrator
+UIHomePagePortlet.Label.Manager=Manager
+UIHomePagePortlet.Label.User=User
+UIHomePagePortlet.Label.Demo=Demo
UIHomePagePortlet.Label.Username=Username:
UIHomePagePortlet.Label.Password=Password:
Added: portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_vi.properties
===================================================================
--- portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_vi.properties (rev 0)
+++ portal/trunk/portlet/web/src/main/webapp/WEB-INF/classes/locale/portlet/web/GroovyPortlet_vi.properties 2010-02-02 04:40:53 UTC (rev 1486)
@@ -0,0 +1,47 @@
+#
+# Copyright (C) 2009 eXo Platform SAS.
+#
+# This is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as
+# published by the Free Software Foundation; either version 2.1 of
+# the License, or (at your option) any later version.
+#
+# This software 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
+# Lesser General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public
+# License along with this software; if not, write to the Free
+# Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+# 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+#
+
+#####################################################################################
+# EXCEPTION MAPPINGS #
+#####################################################################################
+UIGroovyPortlet.note.Text=This is Groovy Portlet (Sample Portlet) it can be developed as a web application in the future.
+UIIFrameEditMode.title=Change URL
+UIIFrameEditMode.label.iframeUrl=URL
+UIIFrameEditMode.label.editmode=Edit Mode
+UIIFrameEditMode.action.Save=Save
+
+UIBannerPortlet.action.changeLanguage=Thay đổi ngôn ngữ
+UIBannerPortlet.action.register=Đăng ký
+
+ #############################################################################
+ #org.exoplatform.portal.webui.component.UIHomePagePortlet #
+ #############################################################################
+
+UIHomePagePortlet.Label.Title=Dùng thử GateIn 3.0 với một trong những tài khoản sau:
+UIHomePagePortlet.Label.Intro=The new version comes with a revolutionary user interface<br/>Classic and WebOS Desktop Layouts<br/> Drag and Drop Features. Create Page Wizard<br/>And many more...
+UIHomePagePortlet.Label.Slogan=The Best of eXo and JBoss Portal<div>GateIn 3.0 Beta 5</div>
+UIHomePagePortlet.Label.GuideText=Để biết thêm thông tin xin hãy liên lạc với chúng tôi.
+UIHomePagePortlet.Label.IntroText=GateIn là công thông tin thế hệ mới kết hợp giữa Red Hat và eXo Platform, tập trung những chuyên gia về cổng thông tin và cộng đồng tốt nhất, mang lại cho các hệ thống thông tin những tính năng đầy đủ nhất.
+UIHomePagePortlet.Label.Administrator=Quản trị
+UIHomePagePortlet.Label.Manager=Quản lý
+UIHomePagePortlet.Label.User=Người dùng
+UIHomePagePortlet.Label.Demo=Demo
+UIHomePagePortlet.Label.Username=Tên đăng nhập:
+UIHomePagePortlet.Label.Password=Mật khẩu:
+
14 years, 11 months
gatein SVN: r1485 - portal/trunk/web/portal/src/main/webapp/templates/groovy/webui/component.
by do-not-reply@jboss.org
Author: tuancn
Date: 2010-02-01 23:38:17 -0500 (Mon, 01 Feb 2010)
New Revision: 1485
Modified:
portal/trunk/web/portal/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl
Log:
Additional features localized for a number of labels
Modified: portal/trunk/web/portal/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl
===================================================================
--- portal/trunk/web/portal/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl 2010-02-02 02:27:54 UTC (rev 1484)
+++ portal/trunk/web/portal/src/main/webapp/templates/groovy/webui/component/UIHomePagePortlet.gtmpl 2010-02-02 04:38:17 UTC (rev 1485)
@@ -1,10 +1,10 @@
<div class="UIHomePagePortlet" id="$uicomponent.id">
<div class="TRContainer">
<div class="PortletDecoration">
- <div class="GuideText">GateIn is the new generation of Open Source portal, jointly led by Red Hat and eXo Platform who partner to gather the best portal experts and communities around a robust and intuitive portal that brings rich administration functionalities to IT systems.</div>
+ <div class="GuideText"><%=_ctx.appRes("UIHomePagePortlet.Label.IntroText")%></div>
<div class="VersionIcon"><span></span></div>
<div class="DotLine"><span></span></div>
- <div class="GuideText">For more information, please contact us.</div>
+ <div class="GuideText"><%=_ctx.appRes("UIHomePagePortlet.Label.GuideText")%></div>
<div class="ContactIcon"><span></span></div>
</div>
@@ -28,7 +28,7 @@
<div class="AccountsContainerDeco">
<div class="AccountBlock AdministratorUser">
<div class="AccountInfos">
- <div class="AccountTitle">Administrator</div>
+ <div class="AccountTitle"><%=_ctx.appRes("UIHomePagePortlet.Label.Administrator")%></div>
<div class="Username">
<div class="Lable"><%=_ctx.appRes("UIHomePagePortlet.Label.Username")%></div><span>root</span>
<div class="ClearBoth"><span></span></div>
@@ -42,7 +42,7 @@
<div class="SeparatorLine"><span></span></div>
<div class="AccountBlock ManagerUser">
<div class="AccountInfos">
- <div class="AccountTitle">Manager</div>
+ <div class="AccountTitle"><%=_ctx.appRes("UIHomePagePortlet.Label.Manager")%></div>
<div class="Username">
<div class="Lable"><%=_ctx.appRes("UIHomePagePortlet.Label.Username")%></div><span>john</span>
<div class="ClearBoth"><span></span></div>
@@ -56,7 +56,7 @@
<div class="SeparatorLine"><span></span></div>
<div class="AccountBlock NormalUser">
<div class="AccountInfos">
- <div class="AccountTitle">User</div>
+ <div class="AccountTitle"><%=_ctx.appRes("UIHomePagePortlet.Label.User")%></div>
<div class="Username">
<div class="Lable"><%=_ctx.appRes("UIHomePagePortlet.Label.Username")%></div><span>mary</span>
<div class="ClearBoth"><span></span></div>
@@ -70,7 +70,7 @@
<div class="SeparatorLine"><span></span></div>
<div class="AccountBlock DemoUser" style="margin-right: 0px;">
<div class="AccountInfos">
- <div class="AccountTitle">Demo</div>
+ <div class="AccountTitle"><%=_ctx.appRes("UIHomePagePortlet.Label.Demo")%></div>
<div class="Username">
<div class="Lable"><%=_ctx.appRes("UIHomePagePortlet.Label.Username")%></div><span>demo</span>
<div class="ClearBoth"><span></span></div>
14 years, 11 months
gatein SVN: r1484 - in portal/trunk: component/web/src/main/java/org/exoplatform/web/resource/config/xml and 2 other directories.
by do-not-reply@jboss.org
Author: hoang_to
Date: 2010-02-01 21:27:54 -0500 (Mon, 01 Feb 2010)
New Revision: 1484
Modified:
portal/trunk/component/portal/src/main/java/org/exoplatform/portal/resource/config/xml/AbstractTaskXMLBinding.java
portal/trunk/component/web/src/main/java/org/exoplatform/web/resource/config/xml/GateinResource.java
portal/trunk/examples/extension/war/src/main/webapp/WEB-INF/gatein-resources.xml
portal/trunk/web/portal/src/main/webapp/WEB-INF/gatein_resources_1_0.xsd
Log:
GTNPORTAL-520: Add overwrite option for skin in gatein-resources.xml
Modified: portal/trunk/component/portal/src/main/java/org/exoplatform/portal/resource/config/xml/AbstractTaskXMLBinding.java
===================================================================
--- portal/trunk/component/portal/src/main/java/org/exoplatform/portal/resource/config/xml/AbstractTaskXMLBinding.java 2010-02-01 10:11:30 UTC (rev 1483)
+++ portal/trunk/component/portal/src/main/java/org/exoplatform/portal/resource/config/xml/AbstractTaskXMLBinding.java 2010-02-02 02:27:54 UTC (rev 1484)
@@ -55,7 +55,7 @@
bindingCSSPath(pTask, element);
bindingSkinName(pTask, element);
bindingModuleName(pTask, element);
-
+ bindingOverwrite(pTask, element);
return pTask;
}
@@ -91,6 +91,17 @@
String skinModule = nodes.item(0).getFirstChild().getNodeValue();
task.setModuleName(skinModule);
}
+
+ private void bindingOverwrite(PortalSkinTask task, Element element)
+ {
+ NodeList nodes = element.getElementsByTagName(GateinResource.OVERWRITE);
+ if (nodes == null || nodes.getLength() < 1)
+ {
+ return;
+ }
+ String overwrite = nodes.item(0).getFirstChild().getNodeValue();
+ task.setOverwrite("true".equals(overwrite));
+ }
}
@@ -150,6 +161,7 @@
bindingPortletName(pTask, element);
bindingCSSPath(pTask, element);
bindingSkinName(pTask, element);
+ bindingOverwrite(pTask, element);
return pTask;
}
@@ -196,6 +208,17 @@
String skinName = nodes.item(0).getFirstChild().getNodeValue();
task.setSkinName(skinName);
}
+
+ private void bindingOverwrite(PortletSkinTask task, Element element)
+ {
+ NodeList nodes = element.getElementsByTagName(GateinResource.OVERWRITE);
+ if (nodes == null || nodes.getLength() < 1)
+ {
+ return;
+ }
+ String overwrite = nodes.item(0).getFirstChild().getNodeValue();
+ task.setOverwrite("true".equals(overwrite));
+ }
}
public static class I18nTaskXMLBinding extends AbstractTaskXMLBinding
Modified: portal/trunk/component/web/src/main/java/org/exoplatform/web/resource/config/xml/GateinResource.java
===================================================================
--- portal/trunk/component/web/src/main/java/org/exoplatform/web/resource/config/xml/GateinResource.java 2010-02-01 10:11:30 UTC (rev 1483)
+++ portal/trunk/component/web/src/main/java/org/exoplatform/web/resource/config/xml/GateinResource.java 2010-02-02 02:27:54 UTC (rev 1484)
@@ -29,7 +29,6 @@
*/
public interface GateinResource
{
-
final public static String SKIN_DEF_TAG = "skin-def";
final public static String SKIN_NAME_TAG = "skin-name";
@@ -62,5 +61,7 @@
final public static String JAVA_SCRIPT_PATH = "js-path";
+ final public static String OVERWRITE = "overwrite";
+
final public static String JAVA_SCRIPT_PRIORITY = "js-priority";
}
Modified: portal/trunk/examples/extension/war/src/main/webapp/WEB-INF/gatein-resources.xml
===================================================================
--- portal/trunk/examples/extension/war/src/main/webapp/WEB-INF/gatein-resources.xml 2010-02-01 10:11:30 UTC (rev 1483)
+++ portal/trunk/examples/extension/war/src/main/webapp/WEB-INF/gatein-resources.xml 2010-02-02 02:27:54 UTC (rev 1484)
@@ -28,6 +28,7 @@
<application-name>web</application-name>
<portlet-name>HomePagePortlet</portlet-name>
<skin-name>Default</skin-name>
+ <overwrite>false</overwrite>
<css-path>/templates/skin/webui/component/UIHomePagePortlet/DefaultStylesheet.css</css-path>
</portlet-skin>
Modified: portal/trunk/web/portal/src/main/webapp/WEB-INF/gatein_resources_1_0.xsd
===================================================================
--- portal/trunk/web/portal/src/main/webapp/WEB-INF/gatein_resources_1_0.xsd 2010-02-01 10:11:30 UTC (rev 1483)
+++ portal/trunk/web/portal/src/main/webapp/WEB-INF/gatein_resources_1_0.xsd 2010-02-02 02:27:54 UTC (rev 1484)
@@ -41,6 +41,7 @@
<xs:sequence>
<xs:element name="skin-name" type="xs:string" />
<xs:element name="css-path" type="xs:string" />
+ <xs:element name="overwrite" type="xs:string" />
</xs:sequence>
</xs:complexType>
@@ -50,6 +51,7 @@
<xs:element name="portlet-name" type="xs:string" />
<xs:element name="skin-name" type="xs:string" />
<xs:element name="css-path" type="xs:string" />
+ <xs:element name="overwrite" type="xs:string" />
</xs:sequence>
</xs:complexType>
14 years, 11 months
gatein SVN: r1483 - portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript.
by do-not-reply@jboss.org
Author: julien_viet
Date: 2010-02-01 05:11:30 -0500 (Mon, 01 Feb 2010)
New Revision: 1483
Modified:
portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptKey.java
Log:
- make javascript key immutable (it's a key)
- rewrite equals method more correctly
Modified: portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptKey.java
===================================================================
--- portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptKey.java 2010-02-01 08:48:58 UTC (rev 1482)
+++ portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptKey.java 2010-02-01 10:11:30 UTC (rev 1483)
@@ -26,41 +26,36 @@
public class JavascriptKey
{
- private String module;
+ private final String module;
- private String scriptPath;
+ private final String scriptPath;
- private int priority;
+ private final int priority;
- public JavascriptKey(String _module, String _scriptPath, Integer priority) throws IllegalArgumentException
+ public JavascriptKey(String module, String scriptPath, Integer priority) throws IllegalArgumentException
{
- if (_module == null || _scriptPath == null)
+ if (module == null || scriptPath == null)
{
throw new IllegalArgumentException("Module and scriptPath are mandatory for JavascriptKey");
}
- this.module = _module;
- this.scriptPath = _scriptPath;
- this.priority = (priority != null ? priority.intValue() : -1);
+ this.module = module;
+ this.scriptPath = scriptPath;
+ this.priority = (priority != null ? priority : -1);
}
@Override
public boolean equals(Object obj)
{
- if (this == null || obj == null)
+ if (obj == this)
{
- return this == null && obj == null;
+ return true;
}
-
- if (!(obj instanceof JavascriptKey))
+ if (obj instanceof JavascriptKey)
{
- return false;
+ JavascriptKey that = (JavascriptKey)obj;
+ return module.equals(that.module) && scriptPath.equals(that.scriptPath);
}
- else
- {
- JavascriptKey target = (JavascriptKey)obj;
- return module.equals(target.module) && scriptPath.equals(target.scriptPath);
- }
-
+ return false;
}
public String getModule()
14 years, 11 months
gatein SVN: r1482 - in portal/trunk: component/web/src/main/java/org/exoplatform/web/resource/config/xml and 2 other directories.
by do-not-reply@jboss.org
Author: tan_pham_dinh
Date: 2010-02-01 03:48:58 -0500 (Mon, 01 Feb 2010)
New Revision: 1482
Modified:
portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptConfigParser.java
portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptConfigService.java
portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptDeployer.java
portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptKey.java
portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptRemoval.java
portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptTask.java
portal/trunk/component/web/src/main/java/org/exoplatform/web/resource/config/xml/GateinResource.java
portal/trunk/web/eXoResources/src/main/webapp/WEB-INF/gatein-resources.xml
portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/workspace/UIPortalApplication.java
Log:
GTNPORTAL-541: Implement priority of Javascripts
Modified: portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptConfigParser.java
===================================================================
--- portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptConfigParser.java 2010-02-01 08:30:35 UTC (rev 1481)
+++ portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptConfigParser.java 2010-02-01 08:48:58 UTC (rev 1482)
@@ -18,6 +18,11 @@
*/
package org.exoplatform.web.application.javascript;
+import org.exoplatform.web.resource.config.xml.GateinResource;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.w3c.dom.NodeList;
+
import java.io.InputStream;
import java.util.ArrayList;
import java.util.List;
@@ -26,11 +31,6 @@
import javax.xml.parsers.DocumentBuilder;
import javax.xml.parsers.DocumentBuilderFactory;
-import org.exoplatform.web.resource.config.xml.GateinResource;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.NodeList;
-
/**
* @author <a href="mailto:hoang281283@gmail.com">Minh Hoang TO</a>
* @version $Id$
@@ -100,7 +100,18 @@
param_ele.getElementsByTagName(GateinResource.JAVA_SCRIPT_MODULE).item(0).getFirstChild().getNodeValue();
String js_path =
param_ele.getElementsByTagName(GateinResource.JAVA_SCRIPT_PATH).item(0).getFirstChild().getNodeValue();
- task.addJSKey(js_module, js_path);
+ Integer js_priority = null;
+ try
+ {
+ js_priority =
+ Integer.valueOf(param_ele.getElementsByTagName(GateinResource.JAVA_SCRIPT_PRIORITY).item(0)
+ .getFirstChild().getNodeValue());
+ }
+ catch (Exception e)
+ {
+ //Js_priority still is null;
+ }
+ task.addJSKey(js_module, js_path, js_priority);
}
return task;
}
Modified: portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptConfigService.java
===================================================================
--- portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptConfigService.java 2010-02-01 08:30:35 UTC (rev 1481)
+++ portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptConfigService.java 2010-02-01 08:48:58 UTC (rev 1482)
@@ -53,7 +53,7 @@
private JavascriptDeployer deployer;
private JavascriptRemoval removal;
-
+
/** Used to clear merged Javascript on undeploying an webapp */
private Map<String, List<String>> object_view_of_merged_JS;
@@ -91,23 +91,25 @@
availableScriptsPaths_.add(path);
extendedJavascripts.put(path, scriptData);
}
-
- public void addJavascript(JavascriptKey key, ServletContext scontext){
- addJavascript(key.getModule(), key.getScriptPath(), scontext);
+
+ public void addJavascript(JavascriptKey key, ServletContext scontext)
+ {
+ addJavascript(key.getModule(), key.getScriptPath(), key.getPriority(), scontext);
}
- public void addJavascript(String module, String scriptPath, ServletContext scontext)
+ public void addJavascript(String module, String scriptPath, Integer priority, ServletContext scontext)
{
String servletContextName = scontext.getServletContextName();
availableScripts_.add(module);
availableScriptsPaths_.add("/" + servletContextName + scriptPath);
-
+
List<String> mergedJS_list = object_view_of_merged_JS.get("/" + servletContextName);
- if(mergedJS_list == null){
+ if (mergedJS_list == null)
+ {
mergedJS_list = new ArrayList<String>();
object_view_of_merged_JS.put("/" + servletContextName, mergedJS_list);
}
-
+
StringBuffer sB = new StringBuffer();
String line = "";
try
@@ -137,23 +139,27 @@
}
sB.append("\n");
mergedJS_list.add("\n");
-
+
mergedJavascript = mergedJavascript.concat(sB.toString());
}
-
- public void removeJavascript(JavascriptKey key, ServletContext scontext){
+
+ public void removeJavascript(JavascriptKey key, ServletContext scontext)
+ {
String contextPath = scontext.getContextPath();
availableScripts_.remove(key.getModule());
availableScriptsPaths_.remove(contextPath + key.getScriptPath());
object_view_of_merged_JS.remove(contextPath);
}
-
+
/** Refresh the mergedJavascript **/
- public void refreshMergedJavascript(){
+ public void refreshMergedJavascript()
+ {
mergedJavascript = "";
StringBuffer buffer = new StringBuffer();
- for(String webApp : object_view_of_merged_JS.keySet()){
- for(String jsPath : object_view_of_merged_JS.get(webApp)){
+ for (String webApp : object_view_of_merged_JS.keySet())
+ {
+ for (String jsPath : object_view_of_merged_JS.get(webApp))
+ {
buffer.append(jsPath);
}
}
@@ -211,5 +217,5 @@
DefaultServletContainerFactory.getInstance().getServletContainer().removeWebAppListener(deployer);
DefaultServletContainerFactory.getInstance().getServletContainer().removeWebAppListener(removal);
}
-
+
}
\ No newline at end of file
Modified: portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptDeployer.java
===================================================================
--- portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptDeployer.java 2010-02-01 08:30:35 UTC (rev 1481)
+++ portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptDeployer.java 2010-02-01 08:48:58 UTC (rev 1482)
@@ -43,7 +43,7 @@
{
private static final String GATEIN_CONFIG_RESOURCE = "/WEB-INF/gatein-resources.xml";
-
+
/**
* Logger
*/
Modified: portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptKey.java
===================================================================
--- portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptKey.java 2010-02-01 08:30:35 UTC (rev 1481)
+++ portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptKey.java 2010-02-01 08:48:58 UTC (rev 1482)
@@ -25,40 +25,56 @@
*/
public class JavascriptKey
{
-
+
private String module;
-
+
private String scriptPath;
-
- public JavascriptKey(String _module, String _scriptPath) throws IllegalArgumentException{
- if(_module == null || _scriptPath == null){
+
+ private int priority;
+
+ public JavascriptKey(String _module, String _scriptPath, Integer priority) throws IllegalArgumentException
+ {
+ if (_module == null || _scriptPath == null)
+ {
throw new IllegalArgumentException("Module and scriptPath are mandatory for JavascriptKey");
}
this.module = _module;
this.scriptPath = _scriptPath;
+ this.priority = (priority != null ? priority.intValue() : -1);
}
-
+
@Override
public boolean equals(Object obj)
{
- if(this == null || obj == null){
+ if (this == null || obj == null)
+ {
return this == null && obj == null;
}
-
- if(!(obj instanceof JavascriptKey)){
+
+ if (!(obj instanceof JavascriptKey))
+ {
return false;
- }else{
+ }
+ else
+ {
JavascriptKey target = (JavascriptKey)obj;
return module.equals(target.module) && scriptPath.equals(target.scriptPath);
}
-
+
}
-
- public String getModule(){
+
+ public String getModule()
+ {
return module;
}
-
- public String getScriptPath(){
+
+ public String getScriptPath()
+ {
return scriptPath;
}
+
+ public int getPriority()
+ {
+ return priority;
+ }
}
Modified: portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptRemoval.java
===================================================================
--- portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptRemoval.java 2010-02-01 08:30:35 UTC (rev 1481)
+++ portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptRemoval.java 2010-02-01 08:48:58 UTC (rev 1482)
@@ -18,16 +18,16 @@
*/
package org.exoplatform.web.application.javascript;
-import java.util.List;
-
-import javax.servlet.ServletContext;
-
import org.gatein.wci.WebAppEvent;
import org.gatein.wci.WebAppLifeCycleEvent;
import org.gatein.wci.WebAppListener;
import org.gatein.wci.impl.DefaultServletContainerFactory;
import org.picocontainer.Startable;
+import java.util.List;
+
+import javax.servlet.ServletContext;
+
/**
* @author <a href="mailto:hoang281283@gmail.com">Minh Hoang TO</a>
* @version $Id$
Modified: portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptTask.java
===================================================================
--- portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptTask.java 2010-02-01 08:30:35 UTC (rev 1481)
+++ portal/trunk/component/web/src/main/java/org/exoplatform/web/application/javascript/JavascriptTask.java 2010-02-01 08:48:58 UTC (rev 1482)
@@ -19,6 +19,8 @@
package org.exoplatform.web.application.javascript;
import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Comparator;
import java.util.List;
import javax.servlet.ServletContext;
@@ -40,6 +42,20 @@
public void execute(JavascriptConfigService service, ServletContext scontext)
{
+ Collections.sort(jsKeys, new Comparator<JavascriptKey>()
+ {
+ public int compare(JavascriptKey js1, JavascriptKey js2)
+ {
+ if (js1.getPriority() == js2.getPriority())
+ return js1.getModule().compareTo(js2.getModule());
+ else if (js1.getPriority() < 0)
+ return 1;
+ else if (js2.getPriority() < 0)
+ return -1;
+ else
+ return js1.getPriority() - js2.getPriority();
+ }
+ });
for (JavascriptKey key : jsKeys)
{
service.addJavascript(key, scontext);
@@ -47,8 +63,8 @@
JavascriptDependentManager.addJavascriptDependent(scontext.getContextPath(), jsKeys);
}
- public void addJSKey(String moduleName, String scriptPath)
+ public void addJSKey(String moduleName, String scriptPath, Integer priority)
{
- jsKeys.add(new JavascriptKey(moduleName, scriptPath));
+ jsKeys.add(new JavascriptKey(moduleName, scriptPath, priority));
}
}
Modified: portal/trunk/component/web/src/main/java/org/exoplatform/web/resource/config/xml/GateinResource.java
===================================================================
--- portal/trunk/component/web/src/main/java/org/exoplatform/web/resource/config/xml/GateinResource.java 2010-02-01 08:30:35 UTC (rev 1481)
+++ portal/trunk/component/web/src/main/java/org/exoplatform/web/resource/config/xml/GateinResource.java 2010-02-01 08:48:58 UTC (rev 1482)
@@ -61,4 +61,6 @@
final public static String JAVA_SCRIPT_MODULE = "js-module";
final public static String JAVA_SCRIPT_PATH = "js-path";
+
+ final public static String JAVA_SCRIPT_PRIORITY = "js-priority";
}
Modified: portal/trunk/web/eXoResources/src/main/webapp/WEB-INF/gatein-resources.xml
===================================================================
--- portal/trunk/web/eXoResources/src/main/webapp/WEB-INF/gatein-resources.xml 2010-02-01 08:30:35 UTC (rev 1481)
+++ portal/trunk/web/eXoResources/src/main/webapp/WEB-INF/gatein-resources.xml 2010-02-01 08:48:58 UTC (rev 1482)
@@ -112,6 +112,7 @@
<param>
<js-module>eXo</js-module>
<js-path>/javascript/eXo.js</js-path>
+ <js-priority>0</js-priority>
</param>
</javascript>
@@ -120,14 +121,17 @@
<param>
<js-module>eXo.core.Utils</js-module>
<js-path>/javascript/eXo/core/Util.js</js-path>
+ <js-priority>0</js-priority>
</param>
<param>
<js-module>eXo.core.DOMUtil</js-module>
<js-path>/javascript/eXo/core/DOMUtil.js</js-path>
+ <js-priority>1</js-priority>
</param>
<param>
<js-module>eXo.core.Browser</js-module>
<js-path>/javascript/eXo/core/Browser.js</js-path>
+ <js-priority>1</js-priority>
</param>
<param>
<js-module>eXo.core.MouseEventManager</js-module>
Modified: portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/workspace/UIPortalApplication.java
===================================================================
--- portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/workspace/UIPortalApplication.java 2010-02-01 08:30:35 UTC (rev 1481)
+++ portal/trunk/webui/portal/src/main/java/org/exoplatform/portal/webui/workspace/UIPortalApplication.java 2010-02-01 08:48:58 UTC (rev 1482)
@@ -26,11 +26,9 @@
import org.exoplatform.portal.config.UserPortalConfig;
import org.exoplatform.portal.config.UserPortalConfigService;
import org.exoplatform.portal.config.model.Container;
+import org.exoplatform.portal.config.model.Page;
import org.exoplatform.portal.config.model.PageNavigation;
import org.exoplatform.portal.config.model.PageNode;
-import org.exoplatform.portal.config.model.PortalConfig;
-import org.exoplatform.portal.config.model.Page;
-import org.exoplatform.portal.config.model.PageNode;
import org.exoplatform.portal.resource.Skin;
import org.exoplatform.portal.resource.SkinConfig;
import org.exoplatform.portal.resource.SkinService;
@@ -66,7 +64,6 @@
import java.util.List;
import java.util.Locale;
import java.util.Map;
-import java.util.ResourceBundle;
import java.util.Set;
14 years, 11 months
gatein SVN: r1481 - portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal.
by do-not-reply@jboss.org
Author: tuancn
Date: 2010-02-01 03:30:35 -0500 (Mon, 01 Feb 2010)
New Revision: 1481
Modified:
portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_en.properties
Log:
Additional features localized for a number of labels of Sitemap Portlet
Modified: portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_en.properties
===================================================================
--- portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_en.properties 2010-02-01 08:30:06 UTC (rev 1480)
+++ portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_en.properties 2010-02-01 08:30:35 UTC (rev 1481)
@@ -961,6 +961,8 @@
############################################################################
UISitemap.label.message=There is no child page in this location.
+UISitemapPortlet.label.CollapseAll=Collapse All
+UISitemapPortlet.label.ExpandAll=Expand All
############################################################################
# org.exoplatform.portal.component.customization.UIPortalToolPanel #
14 years, 11 months
gatein SVN: r1480 - portal/trunk/web/portal/src/main/webapp/groovy/webui/core.
by do-not-reply@jboss.org
Author: tuancn
Date: 2010-02-01 03:30:06 -0500 (Mon, 01 Feb 2010)
New Revision: 1480
Modified:
portal/trunk/web/portal/src/main/webapp/groovy/webui/core/UISitemapTree.gtmpl
Log:
Additional features localized for a number of labels of Sitemap Portlet
Modified: portal/trunk/web/portal/src/main/webapp/groovy/webui/core/UISitemapTree.gtmpl
===================================================================
--- portal/trunk/web/portal/src/main/webapp/groovy/webui/core/UISitemapTree.gtmpl 2010-02-01 08:29:25 UTC (rev 1479)
+++ portal/trunk/web/portal/src/main/webapp/groovy/webui/core/UISitemapTree.gtmpl 2010-02-01 08:30:06 UTC (rev 1480)
@@ -101,8 +101,12 @@
<div id="UISiteMap" class="UISitemap" >
<div class="ClearFix">
- <div class="CollapseAll FloatLeft" onclick="eXo.portal.UIPortal.collapseExpand(this);$actionCollapseAll">Collapse All</div>
- <div class="ExpandAll FloatLeft" onclick="if(!eXo.portal.UIPortal.expandAll(this)){$actionExpandAll}">Expand All</div>
+ <div class="CollapseAll FloatLeft" onclick="eXo.portal.UIPortal.collapseExpand(this);$actionCollapseAll">
+ <%=_ctx.appRes(siteMapPortlet.getName() + ".label.CollapseAll")%>
+ </div>
+ <div class="ExpandAll FloatLeft" onclick="if(!eXo.portal.UIPortal.expandAll(this)){$actionExpandAll}">
+ <%=_ctx.appRes(siteMapPortlet.getName() + ".label.ExpandAll")%>
+ </div>
</div>
<div class="SitemapContent">
<div class="UISiteTree">
14 years, 11 months
gatein SVN: r1479 - portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal.
by do-not-reply@jboss.org
Author: tuancn
Date: 2010-02-01 03:29:25 -0500 (Mon, 01 Feb 2010)
New Revision: 1479
Modified:
portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_vi.properties
Log:
Additional features localized for a number of labels of Sitemap Portlet
Modified: portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_vi.properties
===================================================================
--- portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_vi.properties 2010-02-01 08:12:27 UTC (rev 1478)
+++ portal/trunk/web/portal/src/main/webapp/WEB-INF/classes/locale/portal/webui_vi.properties 2010-02-01 08:29:25 UTC (rev 1479)
@@ -936,6 +936,8 @@
############################################################################
UISitemap.label.message=Không có trang nào!
+UISitemapPortlet.label.CollapseAll=Đóng tất cả
+UISitemapPortlet.label.ExpandAll=Mở tất cả
############################################################################
# org.exoplatform.portal.component.customization.UIPortalToolPanel #
14 years, 11 months