Author: nbelaevski
Date: 2007-11-27 14:37:56 -0500 (Tue, 27 Nov 2007)
New Revision: 4297
Modified:
branches/3.1.x/samples/modalpanel-sample/pom.xml
branches/3.1.x/samples/modalpanel-sample/src/main/webapp/pages/index.jsp
Log:
http://jira.jboss.com/jira/browse/RF-1423
Modified: branches/3.1.x/samples/modalpanel-sample/pom.xml
===================================================================
--- branches/3.1.x/samples/modalpanel-sample/pom.xml 2007-11-27 19:31:13 UTC (rev 4296)
+++ branches/3.1.x/samples/modalpanel-sample/pom.xml 2007-11-27 19:37:56 UTC (rev 4297)
@@ -14,12 +14,17 @@
<dependency>
<groupId>org.richfaces.ui</groupId>
<artifactId>modal-panel</artifactId>
- <version>3.1.3-SNAPSHOT</version>
+ <version>${project.version}</version>
</dependency>
+ <dependency>
+ <groupId>org.richfaces.ui</groupId>
+ <artifactId>componentControl</artifactId>
+ <version>${project.version}</version>
+ </dependency>
<dependency>
<groupId>org.richfaces.samples</groupId>
<artifactId>skins</artifactId>
- <version>3.1.3-SNAPSHOT</version>
+ <version>${project.version}</version>
</dependency>
</dependencies>
<build>
Modified: branches/3.1.x/samples/modalpanel-sample/src/main/webapp/pages/index.jsp
===================================================================
--- branches/3.1.x/samples/modalpanel-sample/src/main/webapp/pages/index.jsp 2007-11-27
19:31:13 UTC (rev 4296)
+++ branches/3.1.x/samples/modalpanel-sample/src/main/webapp/pages/index.jsp 2007-11-27
19:37:56 UTC (rev 4297)
@@ -9,6 +9,7 @@
<%@ taglib
uri="http://java.sun.com/jsf/core" prefix="f" %>
<%@ taglib
uri="http://richfaces.org/a4j" prefix="a4j" %>
<%@ taglib
uri="http://labs.jboss.com/jbossrichfaces/ui/modal-panel"
prefix="mp" %>
+<%@ taglib
uri="http://labs.jboss.com/jbossrichfaces/ui/componentControl"
prefix="cc" %>
<html>
<head>
@@ -148,115 +149,21 @@
<a href="javascript:Richfaces.showModalPanel(':_panel', {width:
1});">Show: width = 1</a>
</f:verbatim>
</h:panelGrid>
-
- <%--
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
+
+ <mp:modalPanel id="ccPanel" controlsClass="pointerCursor"
onhide="alert(event.parameters.alertText)"
+ onshow="alert(event.parameters.alertText)">
+
+ <f:verbatim><a href="#" id="hideLink"
onclick="return false;">Click text to hide modal
panel!</a></f:verbatim>
</mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- <mp:modalPanel>
- <f:verbatim>
- Modal panel is here!
- </f:verbatim>
- </mp:modalPanel>
- --%>
+
+ <cc:componentControl attachTo="hideLink" event="onclick"
for="ccPanel" operation="hide" params="alertText:
'Bye-bye!'" />
+ <a4j:outputPanel style="cursor: pointer;">
+ <cc:componentControl event="onclick" for="ccPanel"
operation="show" params="alertText: 'Hello!'" />
+ <f:verbatim><h3>Click text to activate modal
panel!</h3></f:verbatim>
+ </a4j:outputPanel>
+
+
<f:verbatim>
<div id="fatDiv" style="width: 20px; height: 20px;">div
div div</div>
</f:verbatim>