Search in sources :

Example 1 with LayerGroupUIProviderManager

use of blue.ui.core.score.layers.LayerGroupUIProviderManager in project blue by kunstmusik.

the class ScoreManagerDialog method layerGroupsTableMouseClicked.

// GEN-LAST:event_layersMinusButtonActionPerformed
private void layerGroupsTableMouseClicked(java.awt.event.MouseEvent evt) {
    // GEN-FIRST:event_layerGroupsTableMouseClicked
    if (layerGroupsTable.isEditing()) {
        return;
    }
    int rowIndex = layerGroupsTable.getSelectedRow();
    if (rowIndex < 0) {
        layersTable.setModel(emptyList);
        propertiesScrollPane.setViewportView(null);
    } else {
        final LayerGroup layerGroup = score.get(rowIndex);
        layersTable.setModel(new LayersTableModel(layerGroup));
        TableColumn col = layersTable.getTableHeader().getColumnModel().getColumn(0);
        col.setMaxWidth(50);
        col.setMinWidth(50);
        col.setPreferredWidth(50);
        propertiesScrollPane.setViewportView(null);
        LayerGroupUIProviderManager manager = LayerGroupUIProviderManager.getInstance();
        JComponent comp = manager.getLayerGroupPropertiesPanel(layerGroup);
        if (comp != null) {
            propertiesScrollPane.setViewportView(comp);
        }
    }
// if (UiUtilities.isRightMouseButton(e)) {
// convertPopup.show(arrangementTable, e.getX(), e.getY());
// }
}
Also used : LayerGroupUIProviderManager(blue.ui.core.score.layers.LayerGroupUIProviderManager) LayerGroup(blue.score.layers.LayerGroup) TableColumn(javax.swing.table.TableColumn) Point(java.awt.Point)

Aggregations

LayerGroup (blue.score.layers.LayerGroup)1 LayerGroupUIProviderManager (blue.ui.core.score.layers.LayerGroupUIProviderManager)1 Point (java.awt.Point)1 TableColumn (javax.swing.table.TableColumn)1