Changeset 9754 in josm


Ignore:
Timestamp:
2016-02-07T19:03:59+01:00 (6 years ago)
Author:
bastiK
Message:

fixed: white cells in unsaved changed dialog (closes #12462)

Location:
trunk/src/org/openstreetmap/josm/gui/io
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/io/LayerNameAndFilePathTableCell.java

    r9751 r9754  
    3030import org.openstreetmap.josm.tools.GBC;
    3131
     32/**
     33 * Display and edit layer name and file path in a <code>JTable</code>.
     34 *
     35 * Note: Do not use the same object both as <code>TableCellRenderer</code> and
     36 * <code>TableCellEditor</code> - this can mess up the current editor component
     37 * by subsequent calls to the renderer (#12462).
     38 */
    3239class LayerNameAndFilePathTableCell extends JPanel implements TableCellRenderer, TableCellEditor {
    3340    private static final Color colorError = new Color(255, 197, 197);
  • trunk/src/org/openstreetmap/josm/gui/io/SaveLayersTableColumnModel.java

    r9751 r9754  
    8686
    8787        // column 0 - layer name, save path editor
    88         LayerNameAndFilePathTableCell lnafptc = new LayerNameAndFilePathTableCell();
     88        LayerNameAndFilePathTableCell lnfpRenderer = new LayerNameAndFilePathTableCell();
     89        LayerNameAndFilePathTableCell lnfpEditor = new LayerNameAndFilePathTableCell();
    8990        col = new TableColumn(0); // keep in sync with SaveLayersModel#columnFilename
    9091        col.setHeaderValue(tr("Layer Name and File Path"));
    9192        col.setResizable(true);
    92         col.setCellRenderer(lnafptc);
    93         col.setCellEditor(lnafptc);
     93        col.setCellRenderer(lnfpRenderer);
     94        col.setCellEditor(lnfpEditor);
    9495        col.setPreferredWidth(324);
    9596        addColumn(col);
Note: See TracChangeset for help on using the changeset viewer.