Examples of KongaTable


Examples of org.jitterbit.ui.widget.table.KongaTable

    }

    private KongaRowTable createTable(DatabaseObject dbObject) {
        TableModel model = new TableModel(updateKeys, dbObject);
        TableFactory factory = ComponentFactories.tableFactory();
        KongaTable table = factory.newTable(model, 4);
        TableStyles.wide().makeOver(table);
        TableCellRenderer valueRenderer = new ValueRenderer(updateKeys);
        table.setCellRendererAt(2, valueRenderer);
        TableStringEditor valueEditor = new TableStringEditor();
        valueEditor.setClickCountToStart(1);
        table.setCellEditorAt(2, valueEditor);
        table.setTerminateEditOnFocusLost(true);
        TableUndoRedoService undoRedo = new TableUndoRedoService();
        undoRedo.install(table, true);
        return new KongaRowTable(table);
    }
View Full Code Here

Examples of org.jitterbit.ui.widget.table.KongaTable

            model.addRow(r);
        }
    }

    private KongaRowTable createTable(EntityTestHistoryTableModel model) {
        KongaTable raw = createRawTable(model);
        return new KongaRowTable(raw);
    }
View Full Code Here

Examples of org.jitterbit.ui.widget.table.KongaTable

        return new KongaRowTable(raw);
    }

    private KongaTable createRawTable(EntityTestHistoryTableModel model) {
        TableFactory factory = ComponentFactories.tableFactory();
        KongaTable raw = factory.newSortedTable(model, 10);
        raw.setComparator(model.getEntityColumnIndex(), new EntityTypeAndNameSorter());
        EntityTestHistoryTableRenderers.install(raw);
        return raw;
    }
View Full Code Here

Examples of org.jitterbit.ui.widget.table.KongaTable

        });
    }

    private KongaRowTable createTable() {
        DataElementReferenceTableModel model = new DataElementReferenceTableModel();
        KongaTable table = ComponentFactories.tableFactory().newSortedTable(model);
        installSorter(table, model);
        setRenderers(table);
        TableStyles.normal().makeOver(table);
        return new KongaRowTable(table);
    }
View Full Code Here

Examples of org.jitterbit.ui.widget.table.KongaTable

            }
        });
    }

    private KongaRowTable createTable() {
        KongaTable table = new KongaTable(tableModel) {

            @Override
            public String getToolTipText(MouseEvent event) {
                Point p = event.getPoint();
                TableColumnMetaData col = columnDescriptorAtPoint(p);
                if (col == DataElementTableModel.NAME) {
                    int row = rowAtPoint(p);
                    if (row >= 0) {
                        row = convertRowIndexToModel(row);
                        return tableModel.getRowObjectAt(row).getName();
                    }
                }
                return super.getToolTipText(event);
            }

            @Override
            protected boolean processKeyBinding(KeyStroke ks, KeyEvent e, int condition, boolean pressed) {
                // F8 is by default bound to a "focusHeader" action. We want to use it for
                // Resume Debugging. Just removing that KeyBinding from the InputMap does not seem
                // to work (I don't know why).
                if (KeyUtils.F8.equals(ks)) {
                    return false;
                }
                return super.processKeyBinding(ks, e, condition, pressed);
            }

            @Override
            public boolean isCellEditable(int row, int column) {
                TableColumnMetaData md = tableModel.getColumnDescriptor(column);
                if (md == DataElementTableModel.NAME) {
                    return false;
                }
                DataElement de = tableModel.getRowObjectAt(row);
                return de.getScope() == DataElementScope.GLOBAL || sourceDataElementValuesEditable;
            }
        };
        table.setAutoCreateRowSorter(true);
        TableStyles.wide().makeOver(table);
        table.setShowVerticalLines(true);
        installEditors(table);
        table.setCellRendererFor(DataElementTableModel.NAME, new NameTableRenderer());
        table.setRendererPreparer(new RendererPreparerImpl(table.getFont()));
        setNumberOfVisibleRows(table, 10);
        return new KongaRowTable(table);
    }
View Full Code Here

Examples of org.jitterbit.ui.widget.table.KongaTable

        bindProperties();
    }

    private KongaRowTable createTable() {
        int visibleRows = 4;
        KongaTable table = ComponentFactories.tableFactory().newTable(tableModel, visibleRows);
        TableStyles.normal().makeOver(table);
        table.setTerminateEditOnFocusLost(true);
        table.setCellRendererFor(Model.OBJECT, new ObjectRenderer());
        TableIntegerEditor countEditor = new TableIntegerEditor();
        countEditor.setClickCountToStart(1);
        table.setCellEditorFor(Model.USE_COUNT, countEditor);
        return new KongaRowTable(table);
    }
View Full Code Here

Examples of org.jitterbit.ui.widget.table.KongaTable

    }

    private KongaRowTable createTable(DatabaseObject dbObject) {
        TableModel model = new TableModel(dbObject);
        TableFactory factory = ComponentFactories.tableFactory();
        KongaTable table = factory.newTable(model, 4);
        TableStyles.normal().makeOver(table);
        return new KongaRowTable(table);
    }
View Full Code Here

Examples of org.jitterbit.ui.widget.table.KongaTable

    }

    private KongaRowTable createTable(PropertiesDescriptorTableModel model) {
        TableFactory factory = ComponentFactories.tableFactory();
        int visibleRows = getVisibleRowCount(model);
        KongaTable raw = factory.newTable(model, visibleRows);
        customizeTable(raw);
        return new KongaRowTable(raw);
    }
View Full Code Here

Examples of org.jitterbit.ui.widget.table.KongaTable

        return model;
    }

    private KongaRowTable createTable() {
        TableFactory factory = ComponentFactories.tableFactory();
        KongaTable table = factory.newTable(tableModel);
        TableStyles.normal().makeOver(table);
        table.setVisibleRowCount(Math.min(4, tableModel.getRowCount()));
        table.setShowVerticalLines(true);
        table.setTerminateEditOnFocusLost(true);
        installEditors(table);
        return new KongaRowTable(table);
    }
View Full Code Here

Examples of org.jitterbit.ui.widget.table.KongaTable

            this.deleteAction = a;
        }

        public static void install(DocDefTable table, Action a) {
            DeleteActionEnabler e = new DeleteActionEnabler(table, a);
            KongaTable ui = table.getTable();
            ui.getSelectionModel().addListSelectionListener(e);
        }
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.