Blame view

src/main/config/component/focus.xml 3.44 KB
bernard authored
1
<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE components PUBLIC "-//AJAX4JSF//CDK Generator config/EN"
bernard authored
2
        "http://labs.jboss.com/jbossrichfaces/component-config.dtd" >
bernard authored
3 4 5 6 7 8 9 10 11 12 13 14
<components>
    <component>
        <name>org.richfaces.Focus</name>
        <family>org.richfaces.Focus</family>
        <classname>org.richfaces.component.html.HtmlFocus</classname>
        <superclass>org.richfaces.component.UIFocus</superclass>
        <description>
            <![CDATA[Puts focus on rendered field. In case of text inputs it's
            content is selected. If you use it with i.e. radio use suffix
            attribute.
             ]]>
        </description>
bernard authored
15
        <renderer generate="false" override="false">
bernard authored
16
            <name>org.richfaces.FocusRenderer</name>
bernard authored
17
            <classname>org.richfaces.renderkit.html.HtmlFocusRenderer</classname>
bernard authored
18 19 20 21 22 23 24 25 26 27 28
        </renderer>
        <tag>
            <name>focus</name>
            <classname>org.richfaces.taglib.FocusTag</classname>
            <superclass>
                org.ajax4jsf.webapp.taglib.HtmlComponentTagBase
            </superclass>
            <test>
                <classname>org.richfaces.taglib.HtmlFocusTagTest</classname>
                <superclassname>org.ajax4jsf.tests.AbstractJspTestCase</superclassname>
            </test>
bernard authored
29
bernard authored
30
        </tag> &ui_component_attributes;
bernard authored
31 32 33 34 35 36 37 38 39 40 41 42
        <property>
            <name>for</name>
            <classname>java.lang.String</classname>
            <description>
                Id of component that should be focused
            </description>
            <defaultvalue>""</defaultvalue>
        </property>
        <property>
            <name>priority</name>
            <classname>java.lang.Integer</classname>
            <description>
bernard authored
43
                If there are more components requesting focus, then component with lowest priority will be focused.
bernard authored
44 45 46
            </description>
        </property>
        <property>
bernard authored
47 48 49 50 51 52 53 54 55
            <name>targetClientId</name>
            <classname>java.lang.String</classname>
            <description>
                If some other element then the one matching clintId of target component should be focused and it cannot be achieved with suffix, use this
                attribute.
            </description>
            <defaultvalue>""</defaultvalue>
        </property>
        <property>
bernard authored
56 57 58
            <name>suffix</name>
            <classname>java.lang.String</classname>
            <description>
bernard authored
59
                Suffix added to clientId. Useful for focusing radio elements. Example : suffix=":0" puts focus on first radio if target is radio.
bernard authored
60 61 62
            </description>
            <defaultvalue>""</defaultvalue>
        </property>
bernard authored
63 64 65 66
        <property>
            <name>timing</name>
            <classname>java.lang.String</classname>
            <description>
bernard authored
67 68
                Moment when focus should be put. The possible values are "onJScall" and "onload". If "onJScall" is used then you must manually call
                Richfaces.FocusManager.focus(). The default value is "onload".
bernard authored
69 70 71 72 73 74 75
            </description>
            <defaultvalue>"onload"</defaultvalue>
        </property>
        <property>
            <name>name</name>
            <classname>java.lang.String</classname>
            <description>
bernard authored
76
                Name of JavaScript function generated to trigger focus. This is required if "timing" attribute is set to "onJScall".
bernard authored
77 78 79
            </description>
            <defaultvalue>null</defaultvalue>
        </property>
bernard authored
80 81
    </component>
</components>