Package org.apache.pivot.wtkx

Examples of org.apache.pivot.wtkx.WTKXSerializer.readObject()


    @Override
    public void startup(Display display, Map<String, String> properties)
        throws Exception {
        WTKXSerializer wtkxSerializer = new WTKXSerializer();
        window = new Window((Component)wtkxSerializer.readObject(getClass().getResource("slider_test.wtkx")));
        slider1 = (Slider)wtkxSerializer.get("slider1");
        slider1.getSliderValueListeners().add(new SliderValueListener() {
            @Override
            public void valueChanged(Slider slider, int previousValue) {
                valueLabel1.setText(Integer.toString(slider.getValue()));
View Full Code Here


public class WTKXDictionaryTest {
    @SuppressWarnings("unchecked")
    public static void main(String[] args) throws Exception {
        WTKXSerializer wtkxSerializer = new WTKXSerializer();
        HashMap<String, Object> hashMap =
            (HashMap<String, Object>)wtkxSerializer.readObject(WTKXDictionaryTest.class.getResource("wtkx_dictionary_test.wtkx"));
        System.out.println(JSONSerializer.toString(hashMap));
    }
}
View Full Code Here

    @Override
    public void startup(Display display, Map<String, String> properties)
        throws Exception {
        WTKXSerializer wtkxSerializer = new WTKXSerializer();
        window = (Window)wtkxSerializer.readObject(this, "table_pane_test.wtkx");
        window.open(display);
    }

    @Override
    public boolean shutdown(boolean optional) {
View Full Code Here

    @Override
    public void startup(Display display, Map<String, String> properties)
        throws Exception {
        WTKXSerializer wtkxSerializer = new WTKXSerializer();
        frame = new Frame((Component)wtkxSerializer.readObject(getClass().getResource("form_test.wtkx")));
        frame.setTitle("Form Test");
        frame.setPreferredSize(480, 360);
        frame.open(display);
    }
View Full Code Here

    private BindableWindow window = null;

    @Override
    public void startup(Display display, Map<String, String> properties) throws Exception {
        WTKXSerializer wtkxSerializer = new WTKXSerializer(new Resources(BindableWindow.class.getName()));
        window = (BindableWindow)wtkxSerializer.readObject(this, "bindable_test.wtkx");
        window.open(display);
    }

    @Override
    public boolean shutdown(boolean optional) {
View Full Code Here

    @Override
    public void startup(Display display, Map<String, String> properties)
        throws Exception {
        WTKXSerializer wtkxSerializer = new WTKXSerializer();
        window = (Window)wtkxSerializer.readObject(this, "expander_test.wtkx");
        window.open(display);
    }

    @Override
    public boolean shutdown(boolean optional) {
View Full Code Here

    private Window window = null;

    @Override
    public void startup(Display display, Map<String, String> properties) throws Exception {
        WTKXSerializer wtkxSerializer = new WTKXSerializer();
        window = new Window((Component)wtkxSerializer.readObject(getClass().getResource("baseline_test.wtkx")));
        window.setTitle("Baseline Test");
        window.setMaximized(true);
        window.open(display);
    }
View Full Code Here

    @Override
    public void startup(Display display, Map<String, String> properties)
        throws Exception {
        WTKXSerializer wtkxSerializer = new WTKXSerializer();
        window = (Window)wtkxSerializer.readObject(this, "table_view_test2.wtkx");
        tableView = (TableView)wtkxSerializer.get("tableView");

        TableViewRowEditor tableViewRowEditor = new TableViewRowEditor();
        tableViewRowEditor.setEditEffect(CardPaneSkin.SelectionChangeEffect.HORIZONTAL_SLIDE);
        tableView.setRowEditor(tableViewRowEditor);
View Full Code Here

    @Override
    public void startup(Display display, Map<String, String> properties)
        throws Exception {
        WTKXSerializer wtkxSerializer = new WTKXSerializer();
        BoxPane boxPane = (BoxPane) wtkxSerializer.readObject(this, "color_list_button_test.wtkx");
        listButton = (ListButton)wtkxSerializer.get("listButton");
        // test the getListPopup() method
        listButton.getListPopup().getDecorators().add(new ReflectionDecorator());

        frame = new Frame(boxPane);
View Full Code Here

    private TextInput textinputCustomBoolean = null;

    @Override
    public void startup(Display display, Map<String, String> properties) throws Exception {
        WTKXSerializer wtkxSerializer = new WTKXSerializer();
        window = new Window((Component)wtkxSerializer.readObject(
            getClass().getResource("textInputValidator_test.wtkx")));
        textinputFloatRange = (TextInput)wtkxSerializer.get("textinputFloatRange");
        textinputIntRange = (TextInput)wtkxSerializer.get("textinputIntRange");
        textinputDateRegex = (TextInput)wtkxSerializer.get("textinputDateRegex");
        textinputCustomBoolean = (TextInput)wtkxSerializer.get("textinputCustomBoolean");
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.