Package org.springframework.binding.form

Examples of org.springframework.binding.form.FormModel.revert()


        ValueModel valueModel = formModel.getValueModel("property");
        valueModel.setValue("dirty");

        // sleep for a while so the gui can update itself
        Thread.sleep(500);
        formModel.revert();

        // find a reference to the overlay component
        JLayeredPane layeredPane = frame.getRootPane().getLayeredPane();
        assertEquals("sanity check: assume the layered pane only has one component, and that it is a panel and the overlay",
                     2, layeredPane.getComponentCount());
View Full Code Here


    }

    public void testReadOnlyRevert() {
        FormModel fm = getFormModel(new TestBean());
        fm.getValueModel("readOnly");
        fm.revert();

        // no additional asserts, this test should just not throw an exception!
    }

    public void testDefaultFormModelFromValueModel() throws Exception {
View Full Code Here

                    break;
                case JOptionPane.YES_OPTION:
                    getCommitCommand().execute();
                    break;
                case JOptionPane.NO_OPTION:
                    detailFormModel.revert();
                    break;
            }
        }

        return !userBreak;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.