JBoss Rich Faces SVN: r3077 - trunk/docs/userguide/en/src/main/docbook/included.
by richfaces-svn-commits@lists.jboss.org
Author: vkorluzhenko
Date: 2007-09-24 12:36:14 -0400 (Mon, 24 Sep 2007)
New Revision: 3077
Modified:
trunk/docs/userguide/en/src/main/docbook/included/dataDefinitionList.xml
trunk/docs/userguide/en/src/main/docbook/included/dataList.xml
trunk/docs/userguide/en/src/main/docbook/included/dataOrderedList.xml
Log:
http://jira.jboss.com/jira/browse/RF-920 - corrected descriptions for classes
Modified: trunk/docs/userguide/en/src/main/docbook/included/dataDefinitionList.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/dataDefinitionList.xml 2007-09-24 16:15:29 UTC (rev 3076)
+++ trunk/docs/userguide/en/src/main/docbook/included/dataDefinitionList.xml 2007-09-24 16:36:14 UTC (rev 3077)
@@ -138,7 +138,7 @@
<tbody>
<row>
<entry>rich-deflist</entry>
- <entry>Defines styles for a wrapping element of the component</entry>
+ <entry>Defines styles for a wrapper element of the component</entry>
</row>
<row>
<entry>rich-definition</entry>
Modified: trunk/docs/userguide/en/src/main/docbook/included/dataList.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/dataList.xml 2007-09-24 16:15:29 UTC (rev 3076)
+++ trunk/docs/userguide/en/src/main/docbook/included/dataList.xml 2007-09-24 16:36:14 UTC (rev 3077)
@@ -138,7 +138,7 @@
<tbody>
<row>
<entry>rich-datalist</entry>
- <entry>Defines styles for a wrapping element of the component</entry>
+ <entry>Defines styles for a wrapper element of the component</entry>
</row>
<row>
<entry>rich-list-item</entry>
Modified: trunk/docs/userguide/en/src/main/docbook/included/dataOrderedList.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/dataOrderedList.xml 2007-09-24 16:15:29 UTC (rev 3076)
+++ trunk/docs/userguide/en/src/main/docbook/included/dataOrderedList.xml 2007-09-24 16:36:14 UTC (rev 3077)
@@ -137,7 +137,7 @@
<tbody>
<row>
<entry>rich-datalist</entry>
- <entry>Defines styles for a wrapping element of the component</entry>
+ <entry>Defines styles for a wrapper element of the component</entry>
</row>
<row>
<entry>rich-list-item</entry>
16 years, 7 months
JBoss Rich Faces SVN: r3075 - trunk/ui/toolBar/src/main/java/org/richfaces/component.
by richfaces-svn-commits@lists.jboss.org
Author: sergeyhalipov
Date: 2007-09-24 12:09:16 -0400 (Mon, 24 Sep 2007)
New Revision: 3075
Modified:
trunk/ui/toolBar/src/main/java/org/richfaces/component/UIToolBarGroup.java
Log:
http://jira.jboss.com/jira/browse/RF-970
Modified: trunk/ui/toolBar/src/main/java/org/richfaces/component/UIToolBarGroup.java
===================================================================
--- trunk/ui/toolBar/src/main/java/org/richfaces/component/UIToolBarGroup.java 2007-09-24 16:04:02 UTC (rev 3074)
+++ trunk/ui/toolBar/src/main/java/org/richfaces/component/UIToolBarGroup.java 2007-09-24 16:09:16 UTC (rev 3075)
@@ -40,14 +40,13 @@
public UIToolBar getToolBar() {
UIComponent component = this.getParent();
- while (component != null && !(component instanceof UIToolBar)) {
- component = component.getParent();
+ if (component == null) {
+ throw new FacesException("The component: " + this.getClientId(getFacesContext()) +
+ " is not nested within " + UIToolBar.class.getSimpleName());
+ } else if (!(component instanceof UIToolBar)) {
+ throw new FacesException("The component: " + this.getClientId(getFacesContext()) +
+ " is not a direct child of " + UIToolBar.class.getSimpleName());
}
-
- if (component == null) {
- throw new FacesException("The component: " + this.getClientId(getFacesContext()) + " is not nested within " + UIToolBar.class.getSimpleName());
- } else {
- return (UIToolBar) component;
- }
+ return (UIToolBar) component;
}
}
16 years, 7 months
JBoss Rich Faces SVN: r3073 - trunk/docs/userguide/en/src/main/docbook/included.
by richfaces-svn-commits@lists.jboss.org
Author: smukhina
Date: 2007-09-24 11:55:23 -0400 (Mon, 24 Sep 2007)
New Revision: 3073
Modified:
trunk/docs/userguide/en/src/main/docbook/included/jsFunction.xml
trunk/docs/userguide/en/src/main/docbook/included/mediaOutput.xml
trunk/docs/userguide/en/src/main/docbook/included/message.xml
trunk/docs/userguide/en/src/main/docbook/included/modalPanel.xml
trunk/docs/userguide/en/src/main/docbook/included/outputPanel.xml
trunk/docs/userguide/en/src/main/docbook/included/page.xml
trunk/docs/userguide/en/src/main/docbook/included/panel.xml
trunk/docs/userguide/en/src/main/docbook/included/region.xml
trunk/docs/userguide/en/src/main/docbook/included/suggestionBox.xml
trunk/docs/userguide/en/src/main/docbook/included/support.xml
Log:
http://jira.jboss.com/jira/browse/RF-769
Added highlighting to a newly marked attributes
Modified: trunk/docs/userguide/en/src/main/docbook/included/jsFunction.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/jsFunction.xml 2007-09-24 14:02:29 UTC (rev 3072)
+++ trunk/docs/userguide/en/src/main/docbook/included/jsFunction.xml 2007-09-24 15:55:23 UTC (rev 3073)
@@ -68,7 +68,7 @@
<section>
<title>Key attributes and ways of usage</title>
<para> As the component uses Ajax request to get data from server - it has all common Ajax
- Action attributes. Hence, "action" and "actionListener" can be invoked, and reRendering some parts of
+ Action attributes. Hence, "action" and<emphasis><property> "actionListener" </property></emphasis>can be invoked, and reRendering some parts of
the page fired after calling function. </para>
<para> When using the <emphasis role="bold">
<property><a4j:jsFunction></property>
Modified: trunk/docs/userguide/en/src/main/docbook/included/mediaOutput.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/mediaOutput.xml 2007-09-24 14:02:29 UTC (rev 3072)
+++ trunk/docs/userguide/en/src/main/docbook/included/mediaOutput.xml 2007-09-24 15:55:23 UTC (rev 3073)
@@ -84,7 +84,7 @@
<para>As it was shown in the example above there are two main components:</para>
<itemizedlist>
<listitem>
- "createContent" specifies a method accepting 2 parameters. The first (of java.io.OutputStream type) defines a stream, where any binary data is output. The second (of java.lang.Object type) contains deserialized object with data specified in the <emphasis >
+ <emphasis><property> "createContent" </property></emphasis>specifies a method accepting 2 parameters. The first (of java.io.OutputStream type) defines a stream, where any binary data is output. The second (of java.lang.Object type) contains deserialized object with data specified in the <emphasis >
<property>"value"</property>
</emphasis> attribute.
</listitem>
Modified: trunk/docs/userguide/en/src/main/docbook/included/message.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/message.xml 2007-09-24 14:02:29 UTC (rev 3072)
+++ trunk/docs/userguide/en/src/main/docbook/included/message.xml 2007-09-24 15:55:23 UTC (rev 3073)
@@ -99,7 +99,7 @@
<para> The following example shows different variants of customization of the component. The
attribute 'passedLabel' is used for definition the label to be displayed when no message
appears. But the message component isn't appears before the form submission even with passed
- state defined (on initial rendering).Boolean attribute "showSummary" defines possibility to
+ state defined (on initial rendering).Boolean attribute<emphasis><property> "showSummary" </property></emphasis>defines possibility to
display summary portion of displayed messages. The facets "errorMarker" and 'passedMarker' set
corresponding images for markers. </para>
Modified: trunk/docs/userguide/en/src/main/docbook/included/modalPanel.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/modalPanel.xml 2007-09-24 14:02:29 UTC (rev 3072)
+++ trunk/docs/userguide/en/src/main/docbook/included/modalPanel.xml 2007-09-24 15:55:23 UTC (rev 3073)
@@ -249,11 +249,11 @@
>RichFaces Development Forum</ulink>.</para>
<para> There is a possibility to restore of the previous component state on a page (including
position on the screen) after submitting and reloading. The modalPanel has some special
- attributes like "showWhenRendered" and "keepVisualState". </para>
- <para> "showWhenRendered" - This boolean attribute is used if modalPanel should be rendered after
+ attributes like <emphasis><property>"showWhenRendered"</emphasis></property> and <emphasis><property>"keepVisualState"</emphasis></property>. </para>
+ <para> <emphasis><property>"showWhenRendered"</emphasis></property> - This boolean attribute is used if modalPanel should be rendered after
first page loading. </para>
- <para> "keepVisualState" - Used if modalPanel should save state after submission. If
- "keepVisualState"=true then parameters which modalPanel has during opening should be submitted
+ <para><emphasis><property><emphasis><property> "keepVisualState"</property></emphasis> </property></emphasis>- Used if modalPanel should save state after submission. If
+ <emphasis><property> "keepVisualState"</property></emphasis>=true then parameters which modalPanel has during opening should be submitted
and passed to new page. </para>
<para>
Modified: trunk/docs/userguide/en/src/main/docbook/included/outputPanel.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/outputPanel.xml 2007-09-24 14:02:29 UTC (rev 3072)
+++ trunk/docs/userguide/en/src/main/docbook/included/outputPanel.xml 2007-09-24 15:55:23 UTC (rev 3073)
@@ -77,9 +77,9 @@
</h:panelGrid>
</a4j:outputPanel>
]]></programlisting>
- <para>In addition to the areas directly indicated in "reRender" attribute of Ajax components, <emphasis role="bold">
+ <para>In addition to the areas directly indicated in<emphasis><property> "reRender" </property></emphasis>attribute of Ajax components, <emphasis role="bold">
<property><a4j:outputPanel></property>
- </emphasis> allows to update a part of a page basing on its own flag. The flag is defined by the "ajaxRendered" attribute. The flag is commonly used when a part of a page must be updated or can be updated on any response.</para>
+ </emphasis> allows to update a part of a page basing on its own flag. The flag is defined by the<emphasis><property> "ajaxRendered" </property></emphasis>attribute. The flag is commonly used when a part of a page must be updated or can be updated on any response.</para>
<para><emphasis role="bold">Example:</emphasis></para>
<programlisting role="XML"><![CDATA[<a4j:outputPanel ajaxRendered="true">
<h:messages/>
@@ -116,7 +116,7 @@
]]></programlisting>
<para>As you see, the code is very similar to the one shown above, but <emphasis ><property>"reRender "</property></emphasis> attribute refers directly to the updating panelGrid and not to the framing outputPanel, and it's more semantically correct.</para>
<para><emphasis role="bold"><property><a4j:outPanel></property></emphasis> should be used for non-JSF component part framing, which is to be updated on Ajax response, as Ajax4jsf specifies the list of updating areas as a list of an existing JSF component. </para>
- <para>On default non-JSF context isn't saved in a component tree, but is rendered anew every time. To accelerate the processing speed and Ajax response input speed, Ajax4jsf saves non-JSF context in a component tree on default. This option could be canceled by "keepTransient" attribute that cancels transient flag forced setting for child components. This flag setting keeps the current value set by child components.</para>
+ <para>On default non-JSF context isn't saved in a component tree, but is rendered anew every time. To accelerate the processing speed and Ajax response input speed, Ajax4jsf saves non-JSF context in a component tree on default. This option could be canceled by<emphasis><property> "keepTransient" </property></emphasis>attribute that cancels transient flag forced setting for child components. This flag setting keeps the current value set by child components.</para>
<para>Note: In JSF 1.1 implementation and lower, where non-JSF context should be framed with the "f:verbatim" attribute, <emphasis role="bold">
<property><a4j:outputPanel></property>
</emphasis> doesn't improve this JSF implementation option in any way, so you still have to use this tag where it's necessary without Ajax4jsf usage. </para>
Modified: trunk/docs/userguide/en/src/main/docbook/included/page.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/page.xml 2007-09-24 14:02:29 UTC (rev 3072)
+++ trunk/docs/userguide/en/src/main/docbook/included/page.xml 2007-09-24 15:55:23 UTC (rev 3073)
@@ -82,7 +82,7 @@
</emphasis> on a page round the Ajax updatable area. In the last versions of both frameworks the problem is successfully fixed and no <emphasis role="bold"><property><a4j:page></property></emphasis> usage is required.</para>
<para>The component is rendered as a full HTML page template (it was shown in the example). The "<emphasis >
<property>head</property>
- </emphasis>" section is defined with the help of the corresponding facet with the name="head" and also there is an attribute with the same name for "contentType" definition.</para>
+ </emphasis>" section is defined with the help of the corresponding facet with the name="head" and also there is an attribute with the same name for<emphasis><property> "contentType" </property></emphasis>definition.</para>
</section>
<section>
Modified: trunk/docs/userguide/en/src/main/docbook/included/panel.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/panel.xml 2007-09-24 14:02:29 UTC (rev 3072)
+++ trunk/docs/userguide/en/src/main/docbook/included/panel.xml 2007-09-24 15:55:23 UTC (rev 3073)
@@ -142,9 +142,9 @@
<para>As it has been mentioned <link linkend="panel">above</link>, the component is mostly used for a page style definition,
hence the main attributes are style ones.</para>
<itemizedlist>
- <listitem> "styleClass" and "style" </listitem>
- <listitem> "headerClass" and "headerStyle" </listitem>
- <listitem> "bodyClass" and "bodyStyle" </listitem>
+ <listitem><emphasis><property> "styleClass" </property></emphasis>and "style" </listitem>
+ <listitem><emphasis><property> "headerClass" </property></emphasis>and<emphasis><property> "headerStyle" </property></emphasis></listitem>
+ <listitem><emphasis><property> "bodyClass" </property></emphasis>and<emphasis><property> "bodyStyle" </property></emphasis></listitem>
</itemizedlist>
<para>Moreover, to add e.g. some JavaScript effects, events defined on it are used.</para>
<itemizedlist>
Modified: trunk/docs/userguide/en/src/main/docbook/included/region.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/region.xml 2007-09-24 14:02:29 UTC (rev 3072)
+++ trunk/docs/userguide/en/src/main/docbook/included/region.xml 2007-09-24 15:55:23 UTC (rev 3073)
@@ -85,7 +85,7 @@
<!--..Some content that will be decoded on server after Ajax request.-->
</a4j:region >]]></programlisting>
<para>Therefore, the external region is decoded for the "link1" and the internal one is decoded for the "link2".</para>
- <para>Ajax4jsf allows setting Ajax responses rendering directly basing on component tree nodes without referring to the JSP (XHTML) page code. It could be defined by "selfRendered" attribute setting to <emphasis><property>"true"</property></emphasis> on <emphasis role="bold">
+ <para>Ajax4jsf allows setting Ajax responses rendering directly basing on component tree nodes without referring to the JSP (XHTML) page code. It could be defined by<emphasis><property> "selfRendered" </property></emphasis>attribute setting to <emphasis><property>"true"</property></emphasis> on <emphasis role="bold">
<property><a4j:region></property>
</emphasis> and could help considerably speed up a response output. However, this rapid processing could cause missing of transient components that present on view and don't come into a component tree as well as omitting of <emphasis role="bold">
<property><a4j:outputPanel></property>
@@ -115,7 +115,7 @@
<para>This example shows that one of the regions is decoded when a link is used inside. Nevertheless,
if after processing the "link1" is clicked, the first region passes into Encode as a root
region and encode performance time is reduced. This optimization doesn't allow data update out of the
- region and should be implemented very carefully. The data out of the region described with "renderRegionOnly"="false" is updated successfully.</para>
+ region and should be implemented very carefully. The data out of the region described with<emphasis><property> "renderRegionOnly"</property></emphasis>="false" is updated successfully.</para>
</section>
<section>
<title>Relevant resources links</title>
Modified: trunk/docs/userguide/en/src/main/docbook/included/suggestionBox.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/suggestionBox.xml 2007-09-24 14:02:29 UTC (rev 3072)
+++ trunk/docs/userguide/en/src/main/docbook/included/suggestionBox.xml 2007-09-24 15:55:23 UTC (rev 3073)
@@ -193,7 +193,7 @@
<section>
<para>
There is possibility to define what be shown if the autocomplete returns empty list.
-Attribute "nothingLabel" or facet with the same name could be used for it.
+Attribute<emphasis><property> "nothingLabel" </property></emphasis>or facet with the same name could be used for it.
</para>
<para>
<emphasis role="bold">Example:</emphasis>
Modified: trunk/docs/userguide/en/src/main/docbook/included/support.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/support.xml 2007-09-24 14:02:29 UTC (rev 3072)
+++ trunk/docs/userguide/en/src/main/docbook/included/support.xml 2007-09-24 15:55:23 UTC (rev 3073)
@@ -102,7 +102,7 @@
<para><emphasis ><property>"ajaxSingle"</property></emphasis> is an attribute that allows submission on the server only component sending a request, as if the component presented on a separate form.
</para>
- <para><emphasis ><property>"limitToList"</property></emphasis> is an attribute that allows to limit areas, which are updated after the responses. Only these components defined in the "reRender" attribute are updated. </para>
+ <para><emphasis ><property>"limitToList"</property></emphasis> is an attribute that allows to limit areas, which are updated after the responses. Only these components defined in the <emphasis><property> "reRender" </property></emphasis>attribute are updated. </para>
</listitem>
</itemizedlist></para>
<para><emphasis role="bold">Example 1:</emphasis></para>
@@ -123,7 +123,7 @@
</h:inputText>
<h:outputText value="#{person.name}" id="test"/>
</form>]]></programlisting>
- <para>In this example the component "h:messages" is always updated (as it capturing all Ajax requests, located in ajaxRendered <emphasis role="bold"><property><a4j:outputPanel></property></emphasis>), except the case when a response is sent from the input component from the example. On sending this component marks that updating area is limited to the defined in it components, it means that on its usage with "limitToList"="true" the only component updated is the one with "d"="test".</para>
+ <para>In this example the component "h:messages" is always updated (as it capturing all Ajax requests, located in ajaxRendered <emphasis role="bold"><property><a4j:outputPanel></property></emphasis>), except the case when a response is sent from the input component from the example. On sending this component marks that updating area is limited to the defined in it components, it means that on its usage with<emphasis><property> "limitToList"</property></emphasis>="true" the only component updated is the one with "d"="test".</para>
<itemizedlist>
<listitem>
<emphasis role="bold">Limitation of requests frequency and updates quantity after the responses. </emphasis>
16 years, 7 months
JBoss Rich Faces SVN: r3072 - trunk/ui/drag-drop/src/test/java/org/richfaces/component.
by richfaces-svn-commits@lists.jboss.org
Author: sergeyhalipov
Date: 2007-09-24 10:02:29 -0400 (Mon, 24 Sep 2007)
New Revision: 3072
Modified:
trunk/ui/drag-drop/src/test/java/org/richfaces/component/DragDropTest.java
Log:
Added test for rendering style sheets.
Modified: trunk/ui/drag-drop/src/test/java/org/richfaces/component/DragDropTest.java
===================================================================
--- trunk/ui/drag-drop/src/test/java/org/richfaces/component/DragDropTest.java 2007-09-24 12:56:25 UTC (rev 3071)
+++ trunk/ui/drag-drop/src/test/java/org/richfaces/component/DragDropTest.java 2007-09-24 14:02:29 UTC (rev 3072)
@@ -9,7 +9,11 @@
import javax.faces.component.UIPanel;
import javax.faces.component.html.HtmlForm;
import javax.faces.event.PhaseId;
+import javax.servlet.http.HttpServletResponse;
+import org.ajax4jsf.resource.InternetResource;
+import org.ajax4jsf.resource.InternetResourceBuilder;
+import org.ajax4jsf.resource.ResourceBuilderImpl;
import org.ajax4jsf.tests.AbstractAjax4JsfTestCase;
import org.ajax4jsf.tests.MockViewRoot;
import org.apache.commons.collections.Buffer;
@@ -17,6 +21,7 @@
import org.richfaces.renderkit.DraggableRendererContributor;
import org.richfaces.renderkit.DropzoneRendererContributor;
+import com.gargoylesoftware.htmlunit.Page;
import com.gargoylesoftware.htmlunit.html.HtmlElement;
import com.gargoylesoftware.htmlunit.html.HtmlPage;
import com.gargoylesoftware.htmlunit.html.HtmlScript;
@@ -38,6 +43,8 @@
private UIComponent form;
+ private static final String CSS_FILE_PATH = "org/richfaces/renderkit/html/css/dragIndicator.xcss";
+
private static Set javaScripts = new HashSet();
static {
javaScripts.add("org.ajax4jsf.javascript.PrototypeScript");
@@ -73,7 +80,7 @@
super(testName);
}
- public void SetUp() throws Exception {
+ public void setUp() throws Exception {
super.setUp();
@@ -132,7 +139,6 @@
* Rigourous Test :-)
*/
public void testComponent() throws Exception {
- SetUp();
HtmlPage page = renderView();
assertNotNull(page);
@@ -157,7 +163,6 @@
}
public void testScript() throws Exception {
- SetUp();
HtmlPage page = renderView();
assertNotNull(page);
List scripts = page.getDocumentElement().getHtmlElementsByTagName(
@@ -185,8 +190,6 @@
}
public void testDecode() throws Exception {
-
- SetUp();
externalContext.addRequestParameterMap(DraggableRendererContributor.DRAG_SOURCE_ID, dragsupport.getClientId(facesContext));
externalContext.addRequestParameterMap(DropzoneRendererContributor.DROP_TARGET_ID, dropsupport.getClientId(facesContext));
@@ -211,4 +214,26 @@
}
}
+
+ /**
+ * Test style rendering
+ *
+ * @throws Exception
+ */
+ public void testRenderStyle() throws Exception {
+ HtmlPage page = renderView();
+ assertNotNull(page);
+ List links = page.getDocumentElement().getHtmlElementsByTagName("link");
+ assertEquals(1, links.size());
+ HtmlElement link = (HtmlElement) links.get(0);
+ assertTrue(link.getAttributeValue("href").contains(CSS_FILE_PATH));
+
+ InternetResourceBuilder builder = ResourceBuilderImpl.getInstance();
+ InternetResource resource = builder.getResource(CSS_FILE_PATH);
+ assertNotNull(resource);
+ String uri = "http:" + resource.getUri(facesContext, null);
+ Page cssFile = webClient.getPage(uri);
+ assertNotNull(cssFile);
+ assertTrue(cssFile.getWebResponse().getStatusCode() == HttpServletResponse.SC_OK);
+ }
}
16 years, 7 months
JBoss Rich Faces SVN: r3071 - trunk/ui/modal-panel/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: pyaschenko
Date: 2007-09-24 08:56:25 -0400 (Mon, 24 Sep 2007)
New Revision: 3071
Modified:
trunk/ui/modal-panel/src/main/resources/org/richfaces/renderkit/html/scripts/modalPanel.js
Log:
RF-835
Modified: trunk/ui/modal-panel/src/main/resources/org/richfaces/renderkit/html/scripts/modalPanel.js
===================================================================
--- trunk/ui/modal-panel/src/main/resources/org/richfaces/renderkit/html/scripts/modalPanel.js 2007-09-24 12:52:44 UTC (rev 3070)
+++ trunk/ui/modal-panel/src/main/resources/org/richfaces/renderkit/html/scripts/modalPanel.js 2007-09-24 12:56:25 UTC (rev 3071)
@@ -23,6 +23,41 @@
garbageBin.innerHTML = '';
}
+Selection = {};
+Selection.eventHandler=function(event){Event.stop(event);};
+Selection.eventHandler = Selection.eventHandler.bindAsEventListener(Selection);
+Selection.disableSelection = function (element)
+{
+ if (typeof element.onselectstart!="undefined") //IE
+ {
+ Event.observe(element, 'selectstart', this.eventHandler);
+ }
+ else if (typeof element.style.MozUserSelect!="undefined") //Firefox
+ {
+ element.style.MozUserSelect="none";
+ }
+ else //All other (ie: Opera)
+ {
+ Event.observe(element, 'mousedown', this.eventHandler);
+ }
+}
+
+Selection.enableSelection = function (element)
+{
+ if (typeof element.onselectstart!="undefined") //IE
+ {
+ Event.stopObserving(element, 'selectstart', this.eventHandler);
+ }
+ else if (typeof element.style.MozUserSelect!="undefined") //Firefox
+ {
+ element.style.MozUserSelect="";
+ }
+ else //All other (ie: Opera)
+ {
+ Event.stopObserving(element, 'mousedown', this.eventHandler);
+ }
+}
+
ModalPanel = Class.create();
{
@@ -627,9 +662,10 @@
},
startDrag: function(border) {
- for (var k = 0; k < this.borders.length; k++ ) {
- //this.borders[k].hide();
- }
+ //for (var k = 0; k < this.borders.length; k++ ) {
+ // this.borders[k].hide();
+ //}
+ Selection.disableSelection(document.body);
},
endDrag: function(border) {
@@ -637,6 +673,7 @@
//this.borders[k].show();
this.borders[k].doPosition();
}
+ Selection.enableSelection(document.body);
},
hide: function(opts) {
16 years, 7 months
JBoss Rich Faces SVN: r3070 - branches/3.1.x/ui/calendar/src/main/config/component.
by richfaces-svn-commits@lists.jboss.org
Author: akushunin
Date: 2007-09-24 08:52:44 -0400 (Mon, 24 Sep 2007)
New Revision: 3070
Modified:
branches/3.1.x/ui/calendar/src/main/config/component/calendar.xml
Log:
RF-988
Modified: branches/3.1.x/ui/calendar/src/main/config/component/calendar.xml
===================================================================
--- branches/3.1.x/ui/calendar/src/main/config/component/calendar.xml 2007-09-24 12:44:20 UTC (rev 3069)
+++ branches/3.1.x/ui/calendar/src/main/config/component/calendar.xml 2007-09-24 12:52:44 UTC (rev 3070)
@@ -127,15 +127,8 @@
<description>Defines date pattern</description>
<defaultvalue>"MMM d, yyyy"</defaultvalue>
</property>
+
<property>
- <name>scrollMode</name>
- <classname>java.lang.String</classname>
- <description>
- Valid values are "ajax" and "client"
- </description>
- <defaultvalue>"ajax"</defaultvalue>
- </property>
- <property>
<name>popup</name>
<classname>boolean</classname>
<description>
@@ -466,7 +459,31 @@
<classname>java.lang.String</classname>
<description>Defines disabled icon for the popup button element. The attribute is ignored if the "buttonLabel" is set</description>
</property>
+ <property>
+ <name>mode</name>
+ <classname>java.lang.String</classname>
+ <defaultvalue>UICalendar.CLIENT_MODE</defaultvalue>
+ <description>Valid values = ajax or client</description>
+ </property>
+ <property>
+ <name>horizontalOffset</name>
+ <classname>int</classname>
+ <description>
+ Sets the horizontal offset between button and calendar element conjunction point
+ </description>
+ <defaultvalue>0</defaultvalue>
+ </property>
+
+ <property>
+ <name>verticalOffset</name>
+ <classname>int</classname>
+ <description>
+ Sets the vertical offset between button and calendar element conjunction point
+ </description>
+ <defaultvalue>0</defaultvalue>
+ </property>
+
</component>
&listeners;
</components>
16 years, 7 months
JBoss Rich Faces SVN: r3069 - branches/3.1.x/ui/calendar/src/main/java/org/richfaces/renderkit.
by richfaces-svn-commits@lists.jboss.org
Author: akushunin
Date: 2007-09-24 08:44:20 -0400 (Mon, 24 Sep 2007)
New Revision: 3069
Modified:
branches/3.1.x/ui/calendar/src/main/java/org/richfaces/renderkit/CalendarRendererBase.java
Log:
RF-965/RF-966
Modified: branches/3.1.x/ui/calendar/src/main/java/org/richfaces/renderkit/CalendarRendererBase.java
===================================================================
--- branches/3.1.x/ui/calendar/src/main/java/org/richfaces/renderkit/CalendarRendererBase.java 2007-09-24 12:17:08 UTC (rev 3068)
+++ branches/3.1.x/ui/calendar/src/main/java/org/richfaces/renderkit/CalendarRendererBase.java 2007-09-24 12:44:20 UTC (rev 3069)
@@ -21,6 +21,7 @@
package org.richfaces.renderkit;
+import java.awt.Component;
import java.io.IOException;
import java.text.DateFormatSymbols;
import java.util.Calendar;
@@ -40,6 +41,7 @@
import org.ajax4jsf.context.AjaxContext;
import org.ajax4jsf.event.AjaxEvent;
+import org.ajax4jsf.event.AjaxSingleEvent;
import org.ajax4jsf.javascript.JSFunction;
import org.ajax4jsf.javascript.JSFunctionDefinition;
import org.ajax4jsf.javascript.JSReference;
@@ -49,6 +51,7 @@
import org.richfaces.event.CurrentDateChangeEvent;
import org.richfaces.component.UICalendar;
import org.richfaces.component.util.ComponentUtil;
+import org.ajax4jsf.event.AjaxSingleEvent;
/**
* @author Nick Belaevski - mailto:nbelaevski@exadel.com created 08.06.2007
@@ -126,7 +129,8 @@
// TODO nick - nick - queue this event when ValueChangeEvent is
// queued?
- new AjaxEvent(component).queue();
+ new AjaxEvent(component).queue();
+
}
String selectedDateString = (String) requestParameterMap.get(clientId
@@ -177,8 +181,11 @@
ajaxFunction.addParameter(JSReference.NULL);
Map options = AjaxRendererUtils.buildEventOptions(context, calendar);
options.put("calendar", JSReference.THIS);
- //options.put("single", JSReference.TRUE);
-
+ boolean isSingle = ((Boolean)calendar.getAttributes().get("ajaxSingle")).booleanValue();
+ if(isSingle){
+ options.put("single", JSReference.TRUE);
+ }
+
String oncomplete = AjaxRendererUtils.getAjaxOncomplete(calendar);
JSFunctionDefinition oncompleteDefinition = new JSFunctionDefinition();
oncompleteDefinition.addParameter("request");
16 years, 7 months
JBoss Rich Faces SVN: r3068 - trunk/ui/calendar/src/main/java/org/richfaces/renderkit.
by richfaces-svn-commits@lists.jboss.org
Author: akushunin
Date: 2007-09-24 08:17:08 -0400 (Mon, 24 Sep 2007)
New Revision: 3068
Modified:
trunk/ui/calendar/src/main/java/org/richfaces/renderkit/CalendarRendererBase.java
Log:
RF-965, RF-966
Modified: trunk/ui/calendar/src/main/java/org/richfaces/renderkit/CalendarRendererBase.java
===================================================================
--- trunk/ui/calendar/src/main/java/org/richfaces/renderkit/CalendarRendererBase.java 2007-09-24 12:01:15 UTC (rev 3067)
+++ trunk/ui/calendar/src/main/java/org/richfaces/renderkit/CalendarRendererBase.java 2007-09-24 12:17:08 UTC (rev 3068)
@@ -21,6 +21,7 @@
package org.richfaces.renderkit;
+import java.awt.Component;
import java.io.IOException;
import java.text.DateFormatSymbols;
import java.util.Calendar;
@@ -40,6 +41,7 @@
import org.ajax4jsf.context.AjaxContext;
import org.ajax4jsf.event.AjaxEvent;
+import org.ajax4jsf.event.AjaxSingleEvent;
import org.ajax4jsf.javascript.JSFunction;
import org.ajax4jsf.javascript.JSFunctionDefinition;
import org.ajax4jsf.javascript.JSReference;
@@ -49,6 +51,7 @@
import org.richfaces.event.CurrentDateChangeEvent;
import org.richfaces.component.UICalendar;
import org.richfaces.component.util.ComponentUtil;
+import org.ajax4jsf.event.AjaxSingleEvent;
/**
* @author Nick Belaevski - mailto:nbelaevski@exadel.com created 08.06.2007
@@ -126,7 +129,8 @@
// TODO nick - nick - queue this event when ValueChangeEvent is
// queued?
- new AjaxEvent(component).queue();
+ new AjaxEvent(component).queue();
+
}
String selectedDateString = (String) requestParameterMap.get(clientId
@@ -177,8 +181,11 @@
ajaxFunction.addParameter(JSReference.NULL);
Map options = AjaxRendererUtils.buildEventOptions(context, calendar);
options.put("calendar", JSReference.THIS);
- //options.put("single", JSReference.TRUE);
-
+ boolean isSingle = ((Boolean)calendar.getAttributes().get("ajaxSingle")).booleanValue();
+ if(isSingle){
+ options.put("single", JSReference.TRUE);
+ }
+
String oncomplete = AjaxRendererUtils.getAjaxOncomplete(calendar);
JSFunctionDefinition oncompleteDefinition = new JSFunctionDefinition();
oncompleteDefinition.addParameter("request");
16 years, 7 months
JBoss Rich Faces SVN: r3067 - branches/3.1.x/ui/drag-drop/src/main/templates/org/richfaces.
by richfaces-svn-commits@lists.jboss.org
Author: sergeyhalipov
Date: 2007-09-24 08:01:15 -0400 (Mon, 24 Sep 2007)
New Revision: 3067
Modified:
branches/3.1.x/ui/drag-drop/src/main/templates/org/richfaces/htmlDragIndicator.jspx
Log:
http://jira.jboss.com/jira/browse/RF-991
Modified: branches/3.1.x/ui/drag-drop/src/main/templates/org/richfaces/htmlDragIndicator.jspx
===================================================================
--- branches/3.1.x/ui/drag-drop/src/main/templates/org/richfaces/htmlDragIndicator.jspx 2007-09-24 11:58:02 UTC (rev 3066)
+++ branches/3.1.x/ui/drag-drop/src/main/templates/org/richfaces/htmlDragIndicator.jspx 2007-09-24 12:01:15 UTC (rev 3067)
@@ -20,7 +20,7 @@
/org/richfaces/renderkit/html/scripts/dnd/dnd-common.js,
scripts/drag-indicator.js
</h:scripts>
- <h:styles>css/dragIndicator.xcss</h:styles>
+ <h:styles>/org/richfaces/renderkit/html/css/dragIndicator.xcss</h:styles>
<f:clientId var="clientId" />
16 years, 7 months
JBoss Rich Faces SVN: r3066 - trunk/ui/drag-drop/src/main/templates/org/richfaces.
by richfaces-svn-commits@lists.jboss.org
Author: sergeyhalipov
Date: 2007-09-24 07:58:02 -0400 (Mon, 24 Sep 2007)
New Revision: 3066
Modified:
trunk/ui/drag-drop/src/main/templates/org/richfaces/htmlDragIndicator.jspx
Log:
http://jira.jboss.com/jira/browse/RF-991
Modified: trunk/ui/drag-drop/src/main/templates/org/richfaces/htmlDragIndicator.jspx
===================================================================
--- trunk/ui/drag-drop/src/main/templates/org/richfaces/htmlDragIndicator.jspx 2007-09-24 11:54:25 UTC (rev 3065)
+++ trunk/ui/drag-drop/src/main/templates/org/richfaces/htmlDragIndicator.jspx 2007-09-24 11:58:02 UTC (rev 3066)
@@ -20,7 +20,7 @@
/org/richfaces/renderkit/html/scripts/dnd/dnd-common.js,
scripts/drag-indicator.js
</h:scripts>
- <h:styles>css/dragIndicator.xcss</h:styles>
+ <h:styles>/org/richfaces/renderkit/html/css/dragIndicator.xcss</h:styles>
<f:clientId var="clientId" />
16 years, 7 months