Package org.apache.cocoon.forms.event

Examples of org.apache.cocoon.forms.event.ActionListener


    public static class AddRowActionDefinition extends RepeaterActionDefinition {
       
        public AddRowActionDefinition(String repeaterName) {
            super(repeaterName);
           
            this.addActionListener(new ActionListener() {
                public void actionPerformed(ActionEvent event) {
                    Repeater repeater = ((RepeaterAction)event.getSource()).getRepeater();
                    repeater.addRow();
                }
            });
View Full Code Here


       
        public InsertRowsActionDefinition(String repeaterName, String selectWidgetName) {
            super(repeaterName);
            this.selectName = selectWidgetName;
           
            this.addActionListener(new ActionListener() {
                public void actionPerformed(ActionEvent event) {
                    Repeater repeater = ((RepeaterAction)event.getSource()).getRepeater();
                    boolean foundSelection = false;
                    for (int i = repeater.getSize() - 1; i >= 0; i--) {
                        Repeater.RepeaterRow row = repeater.getRow(i);
View Full Code Here

     * Moves up the row containing this action. Action listeners, if any, are called <em>after</em>
     * the row has been moved.
     */
    public static class MoveUpDefinition extends RowActionDefinition {
        public MoveUpDefinition() {
            super.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent event) {
                    Repeater.RepeaterRow row = Repeater.getParentRow(event.getSourceWidget());
                    Repeater repeater = (Repeater)row.getParent();
                    // Rotation: up in a table is left in a list!
View Full Code Here

     * Moves up the row containing this action. Action listeners, if any, are called <em>after</em>
     * the row has been moved.
     */
    public static class MoveDownDefinition extends RowActionDefinition {
        public MoveDownDefinition() {
            super.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent event) {
                    Repeater.RepeaterRow row = Repeater.getParentRow(event.getSourceWidget());
                    Repeater repeater = (Repeater)row.getParent();
                    // Rotation : down in a table is right in a list!
View Full Code Here

     * Adds a row after the one containing this action. Action listeners, if any, are called <em>after</em>
     * the new row has been created.
     */
    public static class AddAfterDefinition extends RowActionDefinition {
        public AddAfterDefinition() {
            super.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent event) {
                    Repeater.RepeaterRow row = Repeater.getParentRow(event.getSourceWidget());
                    Repeater repeater = (Repeater)row.getParent();
                    repeater.addRow(repeater.indexOf(row)+1);
View Full Code Here

public class AddRowActionDefinition extends RepeaterActionDefinition {
   
    public AddRowActionDefinition(String repeaterName) {
        super(repeaterName);
       
        this.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent event) {
                Repeater repeater = ((RepeaterAction)event.getSource()).getRepeater();
                repeater.addRow();
            }
        });
View Full Code Here

        return new RowAction(this);
    }
   
    public static class DeleteRowDefinition extends RowActionDefinition {
        public DeleteRowDefinition() {
            super.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent event) {
                    Repeater.RepeaterRow row = Repeater.getParentRow(event.getSourceWidget());
                    Repeater repeater = (Repeater)row.getParent();
                    repeater.removeRow(repeater.indexOf(row));
View Full Code Here

        }
    }
   
    public static class MoveUpDefinition extends RowActionDefinition {
        public MoveUpDefinition() {
            super.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent event) {
                    Repeater.RepeaterRow row = Repeater.getParentRow(event.getSourceWidget());
                    Repeater repeater = (Repeater)row.getParent();
                    // Rotation: up in a table is left in a list!
View Full Code Here

        }
    }
   
    public static class MoveDownDefinition extends RowActionDefinition {
        public MoveDownDefinition() {
            super.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent event) {
                    Repeater.RepeaterRow row = Repeater.getParentRow(event.getSourceWidget());
                    Repeater repeater = (Repeater)row.getParent();
                    // Rotation : down in a table is right in a list!
View Full Code Here

        }
    }
   
    public static class AddAfterDefinition extends RowActionDefinition {
        public AddAfterDefinition() {
            super.addActionListener(new ActionListener() {

                public void actionPerformed(ActionEvent event) {
                    Repeater.RepeaterRow row = Repeater.getParentRow(event.getSourceWidget());
                    Repeater repeater = (Repeater)row.getParent();
                    repeater.addRow(repeater.indexOf(row)+1);
View Full Code Here

TOP

Related Classes of org.apache.cocoon.forms.event.ActionListener

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.