Author: jpapouse
Date: 2011-08-05 09:31:32 -0400 (Fri, 05 Aug 2011)
New Revision: 22596
Added:
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichNotifyBean.java
modules/tests/metamer/trunk/application/src/main/webapp/components/richNotify/
Modified:
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/Attributes.java
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java
modules/tests/metamer/trunk/application/src/main/webapp/components/richNotify/moreStacks.xhtml
modules/tests/metamer/trunk/application/src/main/webapp/components/richNotify/simple.xhtml
modules/tests/metamer/trunk/application/src/main/webapp/components/richNotify/validation.xhtml
Log:
added notify component to metamer (merged from branch 'sandbox-components')
Modified:
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/Attributes.java
===================================================================
---
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/Attributes.java 2011-08-05
12:07:57 UTC (rev 22595)
+++
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/Attributes.java 2011-08-05
13:31:32 UTC (rev 22596)
@@ -160,6 +160,18 @@
* Factory method for creating instances of class Attributes. Attributes are loaded
from class.
*
* @param clazz
+ * general class object whose attributes will be stored
+ * @param beanClass
+ * class object of a managed bean
+ */
+ public static Attributes getAttributesFromClass(Class<?> interfaze,
Class<?> beanClass) {
+ return new Attributes(interfaze, beanClass, true);
+ }
+
+ /**
+ * Factory method for creating instances of class Attributes. Attributes are loaded
from class.
+ *
+ * @param clazz
* class object of a JSF component whose attributes will be stored
* @param beanClass
* class object of a managed bean
Modified:
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java
===================================================================
---
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java 2011-08-05
12:07:57 UTC (rev 22595)
+++
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java 2011-08-05
13:31:32 UTC (rev 22596)
@@ -156,6 +156,7 @@
richComponents.put("richMenuSeparator", "Rich Menu
Separator");
richComponents.put("richMessage", "Rich Message");
richComponents.put("richMessages", "Rich Messages");
+ richComponents.put("richNotify", "Rich Notify");
richComponents.put("richOrderingList", "Rich Ordering
List");
richComponents.put("richPanel", "Rich Panel");
richComponents.put("richPanelMenu", "Rich Panel Menu");
Added:
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichNotifyBean.java
===================================================================
---
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichNotifyBean.java
(rev 0)
+++
modules/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/rich/RichNotifyBean.java 2011-08-05
13:31:32 UTC (rev 22596)
@@ -0,0 +1,250 @@
+/*******************************************************************************
+ * JBoss, Home of Professional Open Source
+ * Copyright 2010-2011, Red Hat, Inc. and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * 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.
+ *******************************************************************************/
+package org.richfaces.tests.metamer.bean.rich;
+
+import java.io.Serializable;
+
+import javax.annotation.PostConstruct;
+import javax.faces.application.FacesMessage;
+import javax.faces.bean.ManagedBean;
+import javax.faces.bean.ViewScoped;
+import javax.faces.context.FacesContext;
+
+import org.richfaces.component.AbstractNotify;
+import org.richfaces.component.AbstractNotifyMessages;
+import org.richfaces.component.AbstractNotifyStack;
+import org.richfaces.component.NotifyAttributes;
+import org.richfaces.tests.metamer.Attributes;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Managed bean for notify:notify
+ *
+ * @author <a href="mailto:jpapouse@redhat.com">Jan Papousek</a>
+ */
+@ManagedBean(name = "notifyBean")
+@ViewScoped
+public class RichNotifyBean implements Serializable {
+
+ public static final String DEFAULT_DETAIL = "Message detail";
+ public static final String DEFAULT_SUMMARY = "Message summary";
+ private static final long serialVersionUID = 8408544368608166106L;
+ private static Logger logger;
+ private Attributes attributesNotify;
+ private Attributes attributesNotifyMessages;
+ private Attributes attributesNotifyStackFirst;
+ private Attributes attributesNotifyStackSecond;
+ private Attributes attributesBean;
+
+ /**
+ * Initializes the managed bean.
+ */
+ @PostConstruct
+ public void init() {
+ logger = LoggerFactory.getLogger(getClass());
+ logger.debug("initializing bean " + getClass().getName());
+ attributesNotify =
Attributes.getComponentAttributesFromClass(AbstractNotify.class, getClass());
+ attributesNotifyMessages =
Attributes.getComponentAttributesFromClass(AbstractNotifyMessages.class, getClass());
+ attributesNotifyStackFirst =
Attributes.getComponentAttributesFromClass(AbstractNotifyStack.class, getClass());
+ attributesNotifyStackSecond =
Attributes.getComponentAttributesFromClass(AbstractNotifyStack.class, getClass());
+ attributesBean = Attributes.getEmptyAttributes(getClass());
+
+ attributesNotify.putAll(getGeneralAttributes());
+ attributesNotify.setAttribute("detail", DEFAULT_DETAIL);
+ attributesNotify.setAttribute("rendered", true);
+ attributesNotify.setAttribute("summary", DEFAULT_SUMMARY);
+
+ attributesNotifyMessages.putAll(getGeneralAttributes());
+ attributesNotifyMessages.setAttribute("interval", 800);
+ attributesNotifyMessages.setAttribute("showSummary", true);
+ attributesNotifyMessages.setAttribute("rendered", true);
+ attributesNotifyMessages.remove("for");
+ attributesNotifyMessages.remove("ajaxRendered");
+
+ attributesNotifyStackFirst.setAttribute("direction",
"vertical");
+ attributesNotifyStackFirst.setAttribute("method", "first");
+ attributesNotifyStackFirst.setAttribute("position",
"topRight");
+ attributesNotifyStackFirst.setAttribute("rendered", true);
+ attributesNotifyStackFirst.setAttribute("styleClass",
"topRight");
+
+ attributesNotifyStackSecond.setAttribute("direction",
"vertical");
+ attributesNotifyStackSecond.setAttribute("method", "first");
+ attributesNotifyStackSecond.setAttribute("position",
"bottomRight");
+ attributesNotifyStackSecond.setAttribute("rendered", true);
+ attributesNotifyStackSecond.setAttribute("styleClass",
"bottomRight");
+
+ attributesBean.setAttribute("messageCount", "1");
+ attributesBean.setAttribute("messageDetail", DEFAULT_DETAIL);
+ attributesBean.setAttribute("messageText", DEFAULT_SUMMARY);
+ }
+
+ /**
+ * Produces error message which is handled by notify:notifyMessages component.
+ */
+ public void produceError() {
+ produceMessage(FacesMessage.SEVERITY_ERROR);
+ }
+
+ /**
+ * Produces fatal message which is handled by notify:notifyMessages component.
+ */
+ public void produceFatal() {
+ produceMessage(FacesMessage.SEVERITY_FATAL);
+ }
+
+ /**
+ * Produces info message which is handled by notify:notifyMessages component.
+ */
+ public void produceInfo() {
+ produceMessage(FacesMessage.SEVERITY_INFO);
+ }
+
+ /**
+ * Produces warn message which is handled by notify:notifyMessages component.
+ */
+ public void produceWarn() {
+ produceMessage(FacesMessage.SEVERITY_WARN);
+ }
+
+ /**
+ * General attributes for this bean
+ */
+ public Attributes getAttributesBean() {
+ return attributesBean;
+ }
+
+ /**
+ * Attributes for notify:notify component
+ *
+ * @return A map containing all attributes of tested component. Name of the component
is key in the map.
+ */
+ public Attributes getAttributesNotify() {
+ return attributesNotify;
+ }
+
+ /**
+ * Attributes for notify:notifyMessages component
+ *
+ * @return A map containing all attributes of tested component. Name of the component
is key in the map.
+ */
+ public Attributes getAttributesNotifyMessages() {
+ return attributesNotifyMessages;
+ }
+
+ /**
+ * Attributes for notify:notifyStack (1) component
+ *
+ * @return A map containing all attributes of tested component. Name of the component
is key in the map.
+ */
+ public Attributes getAttributesNotifyStackFirst() {
+ return attributesNotifyStackFirst;
+ }
+
+ /**
+ * Attributes for notify:notifyStack (2) component
+ *
+ * @return A map containing all attributes of tested component. Name of the component
is key in the map.
+ */
+ public Attributes getAttributesNotifyStackSecond() {
+ return attributesNotifyStackSecond;
+ }
+ /**
+ * General attributes for this bean
+ *
+ * @param attributesBean
+ * map containing all attributes of tested component. Name of the
component is key in the map.
+ */
+ public void setAttributesBean(Attributes attributesBean) {
+ this.attributesBean = attributesBean;
+ }
+
+ /**
+ * Attributes for notify:notify component
+ *
+ * @param attributesNotify
+ * map containing all attributes of tested component. Name of the
component is key in the map.
+ */
+ public void setAttributesNotify(Attributes attributesNotify) {
+ this.attributesNotify = attributesNotify;
+ }
+
+ /**
+ * Attributes for notify:notifyMessages component
+ *
+ * @param attributesNotifyMessages
+ * map containing all attributes of tested component. Name of the
component is key in the map.
+ */
+ public void setAttributesNotifyMessages(Attributes attributesNotifyMessages) {
+ this.attributesNotifyMessages = attributesNotifyMessages;
+ }
+
+ /**
+ * Attributes for notify:notifyStack (1) component
+ *
+ * @param attributesNotifyStack
+ * map containing all attributes of tested component. Name of the
component is key in the map.
+ */
+ public void setAttributesNotifyStackFirst(Attributes attributesNotifyStack) {
+ this.attributesNotifyStackFirst = attributesNotifyStack;
+ }
+
+ /**
+ * Attributes for notify:notifyStack (2) component
+ *
+ * @param attributesNotifyStack
+ * map containing all attributes of tested component. Name of the
component is key in the map.
+ */
+ public void setAttributesNotifyStackSecond(Attributes attributesNotifyStack) {
+ this.attributesNotifyStackSecond = attributesNotifyStack;
+ }
+
+ /**
+ * Produces a message which is handled by notify:notifyMessages component.
+ *
+ * @param severity the severity
+ */
+ private void produceMessage(FacesMessage.Severity severity) {
+ int messageCount =
Integer.valueOf((String)attributesBean.get("messageCount").getValue());
+ String text = (String) attributesBean.get("messageText").getValue();
+ String detail = (String)
attributesBean.get("messageDetail").getValue();
+ for(int i=0; i<messageCount; i++) {
+ FacesContext.getCurrentInstance().addMessage(null, new FacesMessage(severity,
text, detail));
+ }
+ }
+
+ /**
+ * It returns attributes shared by AbstractNotify and AbstractNotifyMessages
(NotifyAttributes)
+ *
+ * @return map containing all attributes of tested component. Name of the component
is key in the map.
+ */
+ private Attributes getGeneralAttributes() {
+ Attributes attributes = Attributes.getAttributesFromClass(NotifyAttributes.class,
getClass());
+ attributes.setAttribute("animationSpeed", 100);
+ attributes.setAttribute("appearAnimation", "fade");
+ attributes.setAttribute("hideAnimation", "show");
+ attributes.setAttribute("showCloseButton", true);
+ attributes.setAttribute("stayTime", 100000);
+ attributes.remove("stack");
+ return attributes;
+ }
+}
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richNotify/moreStacks.xhtml
===================================================================
---
modules/tests/metamer/branches/sandbox-components/application/src/main/webapp/components/notify/moreStacks.xhtml 2011-08-04
15:43:59 UTC (rev 22594)
+++
modules/tests/metamer/trunk/application/src/main/webapp/components/richNotify/moreStacks.xhtml 2011-08-05
13:31:32 UTC (rev 22596)
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html
xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
-
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:notify="http://richfaces.org/sandbox/notify"
-
xmlns:metamer="http://java.sun.com/jsf/composite/metamer"
xmlns:a4j="http://richfaces.org/a4j">
+
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:metamer="http://java.sun.com/jsf/composite/metamer"
+
xmlns:a4j="http://richfaces.org/a4j"
xmlns:rich="http://richfaces.org/rich">>
<!--
JBoss, Home of Professional Open Source
@@ -29,6 +29,7 @@
<ui:composition template="/templates/template.xhtml">
<ui:define name="head">
+<!--
<style>
.topLeft {
bottom: auto;
@@ -58,107 +59,108 @@
left: auto;
}
</style>
+ -->
</ui:define>
<ui:define name="component">
<h:form>
- <notify:notifyMessages ajaxRendered="true"
-
animationSpeed="#{notifyBean.attributesNotifyMessages['animationSpeed'].value}"
-
appearAnimation="#{notifyBean.attributesNotifyMessages['appearAnimation'].value}"
-
delay="#{notifyBean.attributesNotifyMessages['delay'].value}"
- execute="{@form}"
- for="number1"
-
globalOnly="#{notifyBean.attributesNotifyMessages['delay'].value}"
-
hideAnimation="#{notifyBean.attributesNotifyMessages['hideAnimation'].value}"
-
keepTransient="#{notifyBean.attributesNotifyMessages['keepTransient'].value}"
-
interval="#{notifyBean.attributesNotifyMessages['interval'].value}"
-
nonblocking="#{notifyBean.attributesNotifyMessages['nonBlocking'].value}"
-
nonblockingOpacity="#{notifyBean.attributesNotifyMessages['nonBlockingOpacity'].value}"
-
rendered="#{notifyBean.attributesNotifyMessages['rendered'].value}"
-
showCloseButton="#{notifyBean.attributesNotifyMessages['showCloseButton'].value}"
-
showDetail="#{notifyBean.attributesNotifyMessages['showDetail'].value}"
-
showHistory="#{notifyBean.attributesNotifyMessages['showHistory'].value}"
-
showShadow="#{notifyBean.attributesNotifyMessages['showShadow'].value}"
-
showSummary="#{notifyBean.attributesNotifyMessages['showSummary'].value}"
- stack="topRightStack"
-
stayTime="#{notifyBean.attributesNotifyMessages['stayTime'].value}"
-
sticky="#{notifyBean.attributesNotifyMessages['sticky'].value}"
-
styleClass="#{notifyBean.attributesNotifyMessages['styleClass'].value}"
- />
- <notify:notifyMessages ajaxRendered="true"
-
animationSpeed="#{notifyBean.attributesNotifyMessages['animationSpeed'].value}"
-
appearAnimation="#{notifyBean.attributesNotifyMessages['appearAnimation'].value}"
-
delay="#{notifyBean.attributesNotifyMessages['delay'].value}"
- execute="{@form}"
- for="number2"
-
globalOnly="#{notifyBean.attributesNotifyMessages['delay'].value}"
-
hideAnimation="#{notifyBean.attributesNotifyMessages['hideAnimation'].value}"
-
keepTransient="#{notifyBean.attributesNotifyMessages['keepTransient'].value}"
-
interval="#{notifyBean.attributesNotifyMessages['interval'].value}"
-
nonblocking="#{notifyBean.attributesNotifyMessages['nonBlocking'].value}"
-
nonblockingOpacity="#{notifyBean.attributesNotifyMessages['nonBlockingOpacity'].value}"
-
rendered="#{notifyBean.attributesNotifyMessages['rendered'].value}"
-
showCloseButton="#{notifyBean.attributesNotifyMessages['showCloseButton'].value}"
-
showDetail="#{notifyBean.attributesNotifyMessages['showDetail'].value}"
-
showHistory="#{notifyBean.attributesNotifyMessages['showHistory'].value}"
-
showShadow="#{notifyBean.attributesNotifyMessages['showShadow'].value}"
-
showSummary="#{notifyBean.attributesNotifyMessages['showSummary'].value}"
- stack="bottomRightStack"
-
stayTime="#{notifyBean.attributesNotifyMessages['stayTime'].value}"
-
sticky="#{notifyBean.attributesNotifyMessages['sticky'].value}"
-
styleClass="#{notifyBean.attributesNotifyMessages['styleClass'].value}"
- />
+ <rich:notifyMessages ajaxRendered="true"
+
animationSpeed="#{notifyBean.attributesNotifyMessages['animationSpeed'].value}"
+
appearAnimation="#{notifyBean.attributesNotifyMessages['appearAnimation'].value}"
+
delay="#{notifyBean.attributesNotifyMessages['delay'].value}"
+ execute="{@form}"
+ for="number1"
+
globalOnly="#{notifyBean.attributesNotifyMessages['delay'].value}"
+
hideAnimation="#{notifyBean.attributesNotifyMessages['hideAnimation'].value}"
+
keepTransient="#{notifyBean.attributesNotifyMessages['keepTransient'].value}"
+
interval="#{notifyBean.attributesNotifyMessages['interval'].value}"
+
nonblocking="#{notifyBean.attributesNotifyMessages['nonBlocking'].value}"
+
nonblockingOpacity="#{notifyBean.attributesNotifyMessages['nonBlockingOpacity'].value}"
+
rendered="#{notifyBean.attributesNotifyMessages['rendered'].value}"
+
showCloseButton="#{notifyBean.attributesNotifyMessages['showCloseButton'].value}"
+
showDetail="#{notifyBean.attributesNotifyMessages['showDetail'].value}"
+
showHistory="#{notifyBean.attributesNotifyMessages['showHistory'].value}"
+
showShadow="#{notifyBean.attributesNotifyMessages['showShadow'].value}"
+
showSummary="#{notifyBean.attributesNotifyMessages['showSummary'].value}"
+ stack="topRightStack"
+
stayTime="#{notifyBean.attributesNotifyMessages['stayTime'].value}"
+
sticky="#{notifyBean.attributesNotifyMessages['sticky'].value}"
+
styleClass="#{notifyBean.attributesNotifyMessages['styleClass'].value}"
+ />
+ <rich:notifyMessages ajaxRendered="true"
+
animationSpeed="#{notifyBean.attributesNotifyMessages['animationSpeed'].value}"
+
appearAnimation="#{notifyBean.attributesNotifyMessages['appearAnimation'].value}"
+
delay="#{notifyBean.attributesNotifyMessages['delay'].value}"
+ execute="{@form}"
+ for="number2"
+
globalOnly="#{notifyBean.attributesNotifyMessages['delay'].value}"
+
hideAnimation="#{notifyBean.attributesNotifyMessages['hideAnimation'].value}"
+
keepTransient="#{notifyBean.attributesNotifyMessages['keepTransient'].value}"
+
interval="#{notifyBean.attributesNotifyMessages['interval'].value}"
+
nonblocking="#{notifyBean.attributesNotifyMessages['nonBlocking'].value}"
+
nonblockingOpacity="#{notifyBean.attributesNotifyMessages['nonBlockingOpacity'].value}"
+
rendered="#{notifyBean.attributesNotifyMessages['rendered'].value}"
+
showCloseButton="#{notifyBean.attributesNotifyMessages['showCloseButton'].value}"
+
showDetail="#{notifyBean.attributesNotifyMessages['showDetail'].value}"
+
showHistory="#{notifyBean.attributesNotifyMessages['showHistory'].value}"
+
showShadow="#{notifyBean.attributesNotifyMessages['showShadow'].value}"
+
showSummary="#{notifyBean.attributesNotifyMessages['showSummary'].value}"
+ stack="bottomRightStack"
+
stayTime="#{notifyBean.attributesNotifyMessages['stayTime'].value}"
+
sticky="#{notifyBean.attributesNotifyMessages['sticky'].value}"
+
styleClass="#{notifyBean.attributesNotifyMessages['styleClass'].value}"
+ />
- <notify:notify
animationSpeed="#{notifyBean.attributesNotify['animationSpeed'].value}"
-
appearAnimation="#{notifyBean.attributesNotify['appearAnimation'].value}"
-
delay="#{notifyBean.attributesNotify['delay'].value}"
-
hideAnimation="#{notifyBean.attributesNotify['hideAnimation'].value}"
-
nonblocking="#{notifyBean.attributesNotify['nonBlocking'].value}"
-
nonblockingOpacity="#{notifyBean.attributesNotify['nonBlockingOpacity'].value}"
-
rendered="#{notifyBean.attributesNotify['rendered'].value}"
-
showCloseButton="#{notifyBean.attributesNotify['showCloseButton'].value}"
-
showHistory="#{notifyBean.attributesNotify['showHistory'].value}"
-
showShadow="#{notifyBean.attributesNotify['showShadow'].value}"
- stack="topRightStack"
-
stayTime="#{notifyBean.attributesNotify['stayTime'].value}"
-
sticky="#{notifyBean.attributesNotify['sticky'].value}"
-
styleClass="#{notifyBean.attributesNotify['styleClass'].value}"
- text="Stack 1 -
#{notifyBean.attributesNotify['text'].value}"
- title="Stack 1 -
#{notifyBean.attributesNotify['title'].value}"
- />
- <notify:notify
animationSpeed="#{notifyBean.attributesNotify['animationSpeed'].value}"
-
appearAnimation="#{notifyBean.attributesNotify['appearAnimation'].value}"
-
delay="#{notifyBean.attributesNotify['delay'].value}"
-
hideAnimation="#{notifyBean.attributesNotify['hideAnimation'].value}"
-
nonblocking="#{notifyBean.attributesNotify['nonBlocking'].value}"
-
nonblockingOpacity="#{notifyBean.attributesNotify['nonBlockingOpacity'].value}"
-
rendered="#{notifyBean.attributesNotify['rendered'].value}"
-
showCloseButton="#{notifyBean.attributesNotify['showCloseButton'].value}"
-
showHistory="#{notifyBean.attributesNotify['showHistory'].value}"
-
showShadow="#{notifyBean.attributesNotify['showShadow'].value}"
- stack="bottomRightStack"
-
stayTime="#{notifyBean.attributesNotify['stayTime'].value}"
-
sticky="#{notifyBean.attributesNotify['sticky'].value}"
-
styleClass="#{notifyBean.attributesNotify['styleClass'].value}"
- text="Stack 2 -
#{notifyBean.attributesNotify['text'].value}"
- title="Stack 2 -
#{notifyBean.attributesNotify['title'].value}"
- />
+ <rich:notify
animationSpeed="#{notifyBean.attributesNotify['animationSpeed'].value}"
+
appearAnimation="#{notifyBean.attributesNotify['appearAnimation'].value}"
+ detail="Stack 2 -
#{notifyBean.attributesNotify['detail'].value}"
+
delay="#{notifyBean.attributesNotify['delay'].value}"
+
hideAnimation="#{notifyBean.attributesNotify['hideAnimation'].value}"
+
nonblocking="#{notifyBean.attributesNotify['nonBlocking'].value}"
+
nonblockingOpacity="#{notifyBean.attributesNotify['nonBlockingOpacity'].value}"
+
rendered="#{notifyBean.attributesNotify['rendered'].value}"
+
showCloseButton="#{notifyBean.attributesNotify['showCloseButton'].value}"
+
showHistory="#{notifyBean.attributesNotify['showHistory'].value}"
+
showShadow="#{notifyBean.attributesNotify['showShadow'].value}"
+ stack="topRightStack"
+
stayTime="#{notifyBean.attributesNotify['stayTime'].value}"
+
sticky="#{notifyBean.attributesNotify['sticky'].value}"
+
styleClass="#{notifyBean.attributesNotify['styleClass'].value}"
+ summary="Stack 2 -
#{notifyBean.attributesNotify['summary'].value}"
+ />
+ <rich:notify
animationSpeed="#{notifyBean.attributesNotify['animationSpeed'].value}"
+
appearAnimation="#{notifyBean.attributesNotify['appearAnimation'].value}"
+
delay="#{notifyBean.attributesNotify['delay'].value}"
+ detail="Stack 2 -
#{notifyBean.attributesNotify['detail'].value}"
+
hideAnimation="#{notifyBean.attributesNotify['hideAnimation'].value}"
+
nonblocking="#{notifyBean.attributesNotify['nonBlocking'].value}"
+
nonblockingOpacity="#{notifyBean.attributesNotify['nonBlockingOpacity'].value}"
+
rendered="#{notifyBean.attributesNotify['rendered'].value}"
+
showCloseButton="#{notifyBean.attributesNotify['showCloseButton'].value}"
+
showHistory="#{notifyBean.attributesNotify['showHistory'].value}"
+
showShadow="#{notifyBean.attributesNotify['showShadow'].value}"
+ stack="bottomRightStack"
+
stayTime="#{notifyBean.attributesNotify['stayTime'].value}"
+
sticky="#{notifyBean.attributesNotify['sticky'].value}"
+
styleClass="#{notifyBean.attributesNotify['styleClass'].value}"
+ summary="Stack 2 -
#{notifyBean.attributesNotify['summary'].value}"
+ />
- <notify:notifyStack id="topRightStack"
-
push="#{notifyBean.attributesNotifyStackFirst['push'].value}"
-
rendered="#{notifyBean.attributesNotifyStackFirst['rendered'].value}"
-
stackDir1="#{notifyBean.attributesNotifyStackFirst['stackDir1'].value}"
-
stackDir2="#{notifyBean.attributesNotifyStackFirst['stackDir2'].value}"
-
styleClass="#{notifyBean.attributesNotifyStackFirst['styleClass'].value}"
- />
+ <rich:notifyStack id="topRightStack"
+
direction="#{notifyBean.attributesNotifyStackFirst['direction'].value}"
+
method="#{notifyBean.attributesNotifyStackFirst['method'].value}"
+
position="#{notifyBean.attributesNotifyStackFirst['position'].value}"
+
rendered="#{notifyBean.attributesNotifyStackFirst['rendered'].value}"
+
styleClass="#{notifyBean.attributesNotifyStackFirst['styleClass'].value}"
+ />
- <notify:notifyStack id="bottomRightStack"
-
push="#{notifyBean.attributesNotifyStackSecond['push'].value}"
-
rendered="#{notifyBean.attributesNotifyStackSecond['rendered'].value}"
-
stackDir1="#{notifyBean.attributesNotifyStackSecond['stackDir1'].value}"
-
stackDir2="#{notifyBean.attributesNotifyStackSecond['stackDir2'].value}"
-
styleClass="#{notifyBean.attributesNotifyStackSecond['styleClass'].value}"
- />
+ <rich:notifyStack id="bottomRightStack"
+
direction="#{notifyBean.attributesNotifyStackSecond['direction'].value}"
+
method="#{notifyBean.attributesNotifyStackSecond['method'].value}"
+
position="#{notifyBean.attributesNotifyStackSecond['position'].value}"
+
rendered="#{notifyBean.attributesNotifyStackSecond['rendered'].value}"
+
styleClass="#{notifyBean.attributesNotifyStackSecond['styleClass'].value}"
+ />
<h:outputLabel for="number1" value="Number for Stack 1
(from 5 to 10)"/>
<h:inputText id="number1" required="true">
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richNotify/simple.xhtml
===================================================================
---
modules/tests/metamer/branches/sandbox-components/application/src/main/webapp/components/notify/simple.xhtml 2011-08-04
15:43:59 UTC (rev 22594)
+++
modules/tests/metamer/trunk/application/src/main/webapp/components/richNotify/simple.xhtml 2011-08-05
13:31:32 UTC (rev 22596)
@@ -2,7 +2,8 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html
xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:notify="http://richfaces.org/sandbox/notify"
-
xmlns:metamer="http://java.sun.com/jsf/composite/metamer"
xmlns:a4j="http://richfaces.org/a4j">
+
xmlns:metamer="http://java.sun.com/jsf/composite/metamer"
xmlns:a4j="http://richfaces.org/a4j"
+
xmlns:rich="http://richfaces.org/rich">
<!--
JBoss, Home of Professional Open Source
@@ -31,52 +32,53 @@
<ui:define name="component">
<h:form>
<a4j:outputPanel ajaxRendered="true">
- <notify:notifyStack id="exampleNotifyStack"
-
push="#{notifyBean.attributesNotifyStackFirst['push'].value}"
-
rendered="#{notifyBean.attributesNotifyStackFirst['rendered'].value}"
-
stackDir1="#{notifyBean.attributesNotifyStackFirst['stackDir1'].value}"
-
stackDir2="#{notifyBean.attributesNotifyStackFirst['stackDir2'].value}"
-
styleClass="#{notifyBean.attributesNotifyStackFirst['styleClass'].value}"
- />
- <notify:notify
animationSpeed="#{notifyBean.attributesNotify['animationSpeed'].value}"
-
appearAnimation="#{notifyBean.attributesNotify['appearAnimation'].value}"
-
delay="#{notifyBean.attributesNotify['delay'].value}"
-
hideAnimation="#{notifyBean.attributesNotify['hideAnimation'].value}"
-
nonblocking="#{notifyBean.attributesNotify['nonBlocking'].value}"
-
nonblockingOpacity="#{notifyBean.attributesNotify['nonBlockingOpacity'].value}"
-
rendered="#{notifyBean.attributesNotify['rendered'].value}"
-
showCloseButton="#{notifyBean.attributesNotify['showCloseButton'].value}"
-
showHistory="#{notifyBean.attributesNotify['showHistory'].value}"
-
showShadow="#{notifyBean.attributesNotify['showShadow'].value}"
- stack="exampleNotifyStack"
-
stayTime="#{notifyBean.attributesNotify['stayTime'].value}"
-
sticky="#{notifyBean.attributesNotify['sticky'].value}"
-
styleClass="#{notifyBean.attributesNotify['styleClass'].value}"
-
text="#{notifyBean.attributesNotify['text'].value}"
-
title="#{notifyBean.attributesNotify['title'].value}"
- />
- <notify:notifyMessages
animationSpeed="#{notifyBean.attributesNotifyMessages['animationSpeed'].value}"
-
appearAnimation="#{notifyBean.attributesNotifyMessages['appearAnimation'].value}"
-
delay="#{notifyBean.attributesNotifyMessages['delay'].value}"
- execute="{@form}"
-
for="#{notifyBean.attributesNotifyMessages['for'].value}"
-
globalOnly="#{notifyBean.attributesNotifyMessages['delay'].value}"
-
hideAnimation="#{notifyBean.attributesNotifyMessages['hideAnimation'].value}"
-
keepTransient="#{notifyBean.attributesNotifyMessages['keepTransient'].value}"
-
interval="#{notifyBean.attributesNotifyMessages['interval'].value}"
-
nonblocking="#{notifyBean.attributesNotifyMessages['nonBlocking'].value}"
-
nonblockingOpacity="#{notifyBean.attributesNotifyMessages['nonBlockingOpacity'].value}"
-
rendered="#{notifyBean.attributesNotifyMessages['rendered'].value}"
-
showCloseButton="#{notifyBean.attributesNotifyMessages['showCloseButton'].value}"
-
showDetail="#{notifyBean.attributesNotifyMessages['showDetail'].value}"
-
showHistory="#{notifyBean.attributesNotifyMessages['showHistory'].value}"
-
showShadow="#{notifyBean.attributesNotifyMessages['showShadow'].value}"
-
showSummary="#{notifyBean.attributesNotifyMessages['showSummary'].value}"
- stack="exampleNotifyStack"
-
stayTime="#{notifyBean.attributesNotifyMessages['stayTime'].value}"
-
sticky="#{notifyBean.attributesNotifyMessages['sticky'].value}"
-
styleClass="#{notifyBean.attributesNotifyMessages['styleClass'].value}"
- />
+
+ <rich:notifyStack id="exampleNotifyStack"
+
direction="#{notifyBean.attributesNotifyStackFirst['direction'].value}"
+
method="#{notifyBean.attributesNotifyStackFirst['method'].value}"
+
position="#{notifyBean.attributesNotifyStackFirst['position'].value}"
+
rendered="#{notifyBean.attributesNotifyStackFirst['rendered'].value}"
+
styleClass="#{notifyBean.attributesNotifyStackFirst['styleClass'].value}"
+ />
+ <rich:notify
animationSpeed="#{notifyBean.attributesNotify['animationSpeed'].value}"
+
appearAnimation="#{notifyBean.attributesNotify['appearAnimation'].value}"
+
delay="#{notifyBean.attributesNotify['delay'].value}"
+
detail="#{notifyBean.attributesNotify['detail'].value}"
+
hideAnimation="#{notifyBean.attributesNotify['hideAnimation'].value}"
+
nonblocking="#{notifyBean.attributesNotify['nonBlocking'].value}"
+
nonblockingOpacity="#{notifyBean.attributesNotify['nonBlockingOpacity'].value}"
+
rendered="#{notifyBean.attributesNotify['rendered'].value}"
+
showCloseButton="#{notifyBean.attributesNotify['showCloseButton'].value}"
+
showHistory="#{notifyBean.attributesNotify['showHistory'].value}"
+
showShadow="#{notifyBean.attributesNotify['showShadow'].value}"
+ stack="exampleNotifyStack"
+
stayTime="#{notifyBean.attributesNotify['stayTime'].value}"
+
sticky="#{notifyBean.attributesNotify['sticky'].value}"
+
styleClass="#{notifyBean.attributesNotify['styleClass'].value}"
+
summary="#{notifyBean.attributesNotify['summary'].value}"
+ />
+ <rich:notifyMessages
animationSpeed="#{notifyBean.attributesNotifyMessages['animationSpeed'].value}"
+
appearAnimation="#{notifyBean.attributesNotifyMessages['appearAnimation'].value}"
+
delay="#{notifyBean.attributesNotifyMessages['delay'].value}"
+ execute="{@form}"
+
for="#{notifyBean.attributesNotifyMessages['for'].value}"
+
globalOnly="#{notifyBean.attributesNotifyMessages['delay'].value}"
+
hideAnimation="#{notifyBean.attributesNotifyMessages['hideAnimation'].value}"
+
keepTransient="#{notifyBean.attributesNotifyMessages['keepTransient'].value}"
+
interval="#{notifyBean.attributesNotifyMessages['interval'].value}"
+
nonblocking="#{notifyBean.attributesNotifyMessages['nonBlocking'].value}"
+
nonblockingOpacity="#{notifyBean.attributesNotifyMessages['nonBlockingOpacity'].value}"
+
rendered="#{notifyBean.attributesNotifyMessages['rendered'].value}"
+
showCloseButton="#{notifyBean.attributesNotifyMessages['showCloseButton'].value}"
+
showDetail="#{notifyBean.attributesNotifyMessages['showDetail'].value}"
+
showHistory="#{notifyBean.attributesNotifyMessages['showHistory'].value}"
+
showShadow="#{notifyBean.attributesNotifyMessages['showShadow'].value}"
+
showSummary="#{notifyBean.attributesNotifyMessages['showSummary'].value}"
+ stack="exampleNotifyStack"
+
stayTime="#{notifyBean.attributesNotifyMessages['stayTime'].value}"
+
sticky="#{notifyBean.attributesNotifyMessages['sticky'].value}"
+
styleClass="#{notifyBean.attributesNotifyMessages['styleClass'].value}"
+ />
</a4j:outputPanel>
<a4j:commandButton id="produceError" value="Produce
Error" action="#{notifyBean.produceError}" execute="@form"/>
<a4j:commandButton id="produceFatal" value="Produce
Fatal" action="#{notifyBean.produceFatal}" execute="@form"/>
Modified:
modules/tests/metamer/trunk/application/src/main/webapp/components/richNotify/validation.xhtml
===================================================================
---
modules/tests/metamer/branches/sandbox-components/application/src/main/webapp/components/notify/validation.xhtml 2011-08-04
15:43:59 UTC (rev 22594)
+++
modules/tests/metamer/trunk/application/src/main/webapp/components/richNotify/validation.xhtml 2011-08-05
13:31:32 UTC (rev 22596)
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html
xmlns="http://www.w3.org/1999/xhtml"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
-
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:notify="http://richfaces.org/sandbox/notify"
+
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:rich="http://richfaces.org/rich"
xmlns:metamer="http://java.sun.com/jsf/composite/metamer"
xmlns:a4j="http://richfaces.org/a4j">
<!--
@@ -30,55 +30,54 @@
<ui:define name="component">
<h:form>
- <notify:notifyMessages ajaxRendered="true"
-
animationSpeed="#{notifyBean.attributesNotifyMessages['animationSpeed'].value}"
-
appearAnimation="#{notifyBean.attributesNotifyMessages['appearAnimation'].value}"
-
delay="#{notifyBean.attributesNotifyMessages['delay'].value}"
- execute="{@form}"
- for="number"
-
globalOnly="#{notifyBean.attributesNotifyMessages['delay'].value}"
-
hideAnimation="#{notifyBean.attributesNotifyMessages['hideAnimation'].value}"
-
keepTransient="#{notifyBean.attributesNotifyMessages['keepTransient'].value}"
-
interval="#{notifyBean.attributesNotifyMessages['interval'].value}"
-
nonblocking="#{notifyBean.attributesNotifyMessages['nonBlocking'].value}"
-
nonblockingOpacity="#{notifyBean.attributesNotifyMessages['nonBlockingOpacity'].value}"
-
rendered="#{notifyBean.attributesNotifyMessages['rendered'].value}"
-
showCloseButton="#{notifyBean.attributesNotifyMessages['showCloseButton'].value}"
-
showDetail="#{notifyBean.attributesNotifyMessages['showDetail'].value}"
-
showHistory="#{notifyBean.attributesNotifyMessages['showHistory'].value}"
-
showShadow="#{notifyBean.attributesNotifyMessages['showShadow'].value}"
-
showSummary="#{notifyBean.attributesNotifyMessages['showSummary'].value}"
- stack="exampleNotifyStack"
-
stayTime="#{notifyBean.attributesNotifyMessages['stayTime'].value}"
-
sticky="#{notifyBean.attributesNotifyMessages['sticky'].value}"
-
styleClass="#{notifyBean.attributesNotifyMessages['styleClass'].value}"
- />
+ <rich:notifyMessages ajaxRendered="true"
+
animationSpeed="#{notifyBean.attributesNotifyMessages['animationSpeed'].value}"
+
appearAnimation="#{notifyBean.attributesNotifyMessages['appearAnimation'].value}"
+
delay="#{notifyBean.attributesNotifyMessages['delay'].value}"
+ execute="{@form}"
+ for="number"
+
globalOnly="#{notifyBean.attributesNotifyMessages['delay'].value}"
+
hideAnimation="#{notifyBean.attributesNotifyMessages['hideAnimation'].value}"
+
keepTransient="#{notifyBean.attributesNotifyMessages['keepTransient'].value}"
+
interval="#{notifyBean.attributesNotifyMessages['interval'].value}"
+
nonblocking="#{notifyBean.attributesNotifyMessages['nonBlocking'].value}"
+
nonblockingOpacity="#{notifyBean.attributesNotifyMessages['nonBlockingOpacity'].value}"
+
rendered="#{notifyBean.attributesNotifyMessages['rendered'].value}"
+
showCloseButton="#{notifyBean.attributesNotifyMessages['showCloseButton'].value}"
+
showDetail="#{notifyBean.attributesNotifyMessages['showDetail'].value}"
+
showHistory="#{notifyBean.attributesNotifyMessages['showHistory'].value}"
+
showShadow="#{notifyBean.attributesNotifyMessages['showShadow'].value}"
+
showSummary="#{notifyBean.attributesNotifyMessages['showSummary'].value}"
+ stack="exampleNotifyStack"
+
stayTime="#{notifyBean.attributesNotifyMessages['stayTime'].value}"
+
sticky="#{notifyBean.attributesNotifyMessages['sticky'].value}"
+
styleClass="#{notifyBean.attributesNotifyMessages['styleClass'].value}"
+ />
- <notify:notify
animationSpeed="#{notifyBean.attributesNotify['animationSpeed'].value}"
-
appearAnimation="#{notifyBean.attributesNotify['appearAnimation'].value}"
-
delay="#{notifyBean.attributesNotify['delay'].value}"
-
hideAnimation="#{notifyBean.attributesNotify['hideAnimation'].value}"
-
nonblocking="#{notifyBean.attributesNotify['nonBlocking'].value}"
-
nonblockingOpacity="#{notifyBean.attributesNotify['nonBlockingOpacity'].value}"
-
rendered="#{notifyBean.attributesNotify['rendered'].value}"
-
showCloseButton="#{notifyBean.attributesNotify['showCloseButton'].value}"
-
showHistory="#{notifyBean.attributesNotify['showHistory'].value}"
-
showShadow="#{notifyBean.attributesNotify['showShadow'].value}"
- stack="exampleNotifyStack"
-
stayTime="#{notifyBean.attributesNotify['stayTime'].value}"
-
sticky="#{notifyBean.attributesNotify['sticky'].value}"
-
styleClass="#{notifyBean.attributesNotify['styleClass'].value}"
-
text="#{notifyBean.attributesNotify['text'].value}"
- title="
#{notifyBean.attributesNotify['title'].value}"
- />
+ <rich:notify
animationSpeed="#{notifyBean.attributesNotify['animationSpeed'].value}"
+
appearAnimation="#{notifyBean.attributesNotify['appearAnimation'].value}"
+
delay="#{notifyBean.attributesNotify['delay'].value}"
+
detail="#{notifyBean.attributesNotify['detail'].value}"
+
hideAnimation="#{notifyBean.attributesNotify['hideAnimation'].value}"
+
nonblocking="#{notifyBean.attributesNotify['nonBlocking'].value}"
+
nonblockingOpacity="#{notifyBean.attributesNotify['nonBlockingOpacity'].value}"
+
rendered="#{notifyBean.attributesNotify['rendered'].value}"
+
showCloseButton="#{notifyBean.attributesNotify['showCloseButton'].value}"
+
showHistory="#{notifyBean.attributesNotify['showHistory'].value}"
+
showShadow="#{notifyBean.attributesNotify['showShadow'].value}"
+ stack="exampleNotifyStack"
+
stayTime="#{notifyBean.attributesNotify['stayTime'].value}"
+
sticky="#{notifyBean.attributesNotify['sticky'].value}"
+
styleClass="#{notifyBean.attributesNotify['styleClass'].value}"
+ summary="
#{notifyBean.attributesNotify['title'].value}"
+ />
- <notify:notifyStack id="exampleNotifyStack"
-
push="#{notifyBean.attributesNotifyStackFirst['push'].value}"
-
rendered="#{notifyBean.attributesNotifyStackFirst['rendered'].value}"
-
stackDir1="#{notifyBean.attributesNotifyStackFirst['stackDir1'].value}"
-
stackDir2="#{notifyBean.attributesNotifyStackFirst['stackDir2'].value}"
-
styleClass="#{notifyBean.attributesNotifyStackFirst['styleClass'].value}"
- />
+ <rich:notifyStack id="exampleNotifyStack"
+
direction="#{notifyBean.attributesNotifyStackFirst['direction'].value}"
+
method="#{notifyBean.attributesNotifyStackFirst['method'].value}"
+
position="#{notifyBean.attributesNotifyStackFirst['position'].value}"
+
rendered="#{notifyBean.attributesNotifyStackFirst['rendered'].value}"
+
styleClass="#{notifyBean.attributesNotifyStackFirst['styleClass'].value}"
/>
<h:outputLabel for="number" value="Number (from 5 to
10)"/>
<h:inputText id="number" required="true">