Package org.jbpm.formbuilder.client.bus

Examples of org.jbpm.formbuilder.client.bus.UndoableEvent


            }
        }
        Map<String, Object> dataSnapshot = new HashMap<String, Object>();
        dataSnapshot.put("menuItem", menuItem);
        dataSnapshot.put("groupName", groupName);
        bus.fireEvent(new UndoableEvent(dataSnapshot, new UndoableHandler() {
            @Override
            public void onEvent(UndoableEvent event) {  }
            @Override
            public void undoAction(UndoableEvent event) {
                FBMenuItem menuItem = (FBMenuItem) event.getData("menuItem");
View Full Code Here


        dataSnapshot.put("item", item);
        dataSnapshot.put("oldWidth", item.getWidth());
        dataSnapshot.put("oldHeight", item.getHeight());
        dataSnapshot.put("newWidth", "" + event.getWidth() + "px");
        dataSnapshot.put("newHeight", "" + event.getHeight() + "px");
        bus.fireEvent(new UndoableEvent(dataSnapshot, new UndoableHandler() {
            @Override
            public void onEvent(UndoableEvent event) { /* do nothing */ }
            @Override
            public void undoAction(UndoableEvent event) {
                FBFormItem item = (FBFormItem) event.getData("item");
View Full Code Here

                Map<String, Object> dataSnapshot = new HashMap<String, Object>();
                dataSnapshot.put("labelBoxValue", labelBox.getValue());
                dataSnapshot.put("valueBoxValue", valueBox.getValue());
                dataSnapshot.put("item", getItem());
                EventBus bus = CommonGlobals.getInstance().getEventBus();
                bus.fireEvent(new UndoableEvent(dataSnapshot, new UndoableHandler() {
                    @Override
                    public void onEvent(UndoableEvent event) {  }
                    @Override
                    public void undoAction(UndoableEvent event) {
                        String label = (String) event.getData("labelBoxValue");
View Full Code Here

            }
        });
    }
   
    protected void fireUndoableEvent(Map<String, Object> dataSnapshot, UndoableHandler handler) {
        bus.fireEvent(new UndoableEvent(dataSnapshot, handler));
    }
View Full Code Here

    @Override
    protected void createStyles() {
        final Map<String, Object> dataSnapshot = new HashMap<String, Object>();
        dataSnapshot.put("selectedY", getParent().getAbsoluteTop());
        dataSnapshot.put("item", getItem());
        bus.fireEvent(new UndoableEvent(dataSnapshot, new UndoableHandler() {
            @Override
            @SuppressWarnings("unchecked")
            public void undoAction(UndoableEvent event) {
                TableLayoutFormItem item = (TableLayoutFormItem) event.getData("item");
                Integer selectedY = (Integer) event.getData("selectedY");
View Full Code Here

    }
   
    private void deleteForm(FormRepresentation form) {
        Map<String, Object> dataSnapshot = new HashMap<String, Object>();
        dataSnapshot.put("form", form);
        bus.fireEvent(new UndoableEvent(dataSnapshot, new UndoableHandler() {
            @Override
            public void undoAction(UndoableEvent event) {
                FormRepresentation form = (FormRepresentation) event.getData("form");
                if (form != null) {
                    try {
View Full Code Here

    @Override
    protected void createStyles() {
        final Map<String, Object> dataSnapshot = new HashMap<String, Object>();
        dataSnapshot.put("selectedX", getParent().getAbsoluteLeft());
        dataSnapshot.put("item", getItem());
        bus.fireEvent(new UndoableEvent(dataSnapshot, new UndoableHandler() {
            @Override
            public void undoAction(UndoableEvent event) {
                TableLayoutFormItem item = (TableLayoutFormItem) event.getData("item");
                Integer selectedX = (Integer) event.getData("selectedX");
                int columnNumber = item.getColumnForXCoordinate(selectedX);
View Full Code Here

                MIGLayoutFormItem container = (MIGLayoutFormItem) event.getData("container");
                FBFormItem item = (FBFormItem) event.getData("item");
                container.setSpan(item, colspan, rowspan);
            }
        };
        bus.fireEvent(new UndoableEvent(dataSnapshot, rollbackHandler));
        container.setSpan(item, colspan.getValue(), rowspan.getValue());
    }
View Full Code Here

            }
            Map<String, Object> dataSnapshot = new HashMap<String, Object>();
            dataSnapshot.put("oldAlignment", hw.getHorizontalAlignment());
            dataSnapshot.put("newAlignment", align);
            dataSnapshot.put("hwidget", hw);
            bus.fireEvent(new UndoableEvent(dataSnapshot, new UndoableHandler() {
                @Override
                public void onEvent(UndoableEvent event) {  }
                @Override
                public void undoAction(UndoableEvent event) {
                    HorizontalAlignmentConstant oldAlignment = (HorizontalAlignmentConstant) event.getData("oldAlignment");
View Full Code Here

    @Override
    protected void createStyles() {
        final Map<String, Object> dataSnapshot = new HashMap<String, Object>();
        dataSnapshot.put("selectedY", getParent().getAbsoluteTop());
        dataSnapshot.put("item", getItem());
        bus.fireEvent(new UndoableEvent(dataSnapshot, new UndoableHandler() {
            @Override
            public void undoAction(UndoableEvent event) {
                TableLayoutFormItem item = (TableLayoutFormItem) event.getData("item");
                Integer selectedY = (Integer) event.getData("selectedY");
                int rowNumber = item.getRowForYCoordinate(selectedY);
View Full Code Here

TOP

Related Classes of org.jbpm.formbuilder.client.bus.UndoableEvent

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.