Ignore:
Timestamp:
2014-01-10T19:24:34+01:00 (6 years ago)
Author:
Don-vip
Message:

see #9508 - refactor validator preferences + handling of JScrollPane policies ("vertical as needed" / "horizontal as needed" are default policies)

Location:
trunk/src/org/openstreetmap/josm/gui/history
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/history/HistoryBrowser.java

    r6267 r6666  
    1111import javax.swing.JSplitPane;
    1212import javax.swing.JTabbedPane;
    13 import javax.swing.JTable;
    1413
    1514import org.openstreetmap.josm.data.osm.OsmPrimitive;
     
    3332
    3433    /**
    35      * embedds table in a {@link JScrollPane}
    36      *
    37      * @param table the table
    38      * @return the {@link JScrollPane} with the embedded table
    39      */
    40     protected JScrollPane embeddInScrollPane(JTable table) {
    41         JScrollPane pane = new JScrollPane(table);
    42         pane.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
    43         pane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
    44         return pane;
    45     }
    46 
    47     /**
    4834     * creates the table which shows the list of versions
    4935     *
     
    5541
    5642        VersionTable versionTable = new VersionTable(model);
    57         pnl.add(embeddInScrollPane(versionTable), BorderLayout.CENTER);
     43        pnl.add(new JScrollPane(versionTable), BorderLayout.CENTER);
    5844        return pnl;
    5945    }
  • trunk/src/org/openstreetmap/josm/gui/history/HistoryViewerPanel.java

    r6207 r6666  
    3131    private JScrollPane embedInScrollPane(JTable table) {
    3232        JScrollPane pane = new JScrollPane(table);
    33         pane.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
    34         pane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
    3533        adjustmentSynchronizer.participateInSynchronizedScrolling(pane.getVerticalScrollBar());
    3634        return pane;
  • trunk/src/org/openstreetmap/josm/gui/history/NodeListViewer.java

    r6336 r6666  
    5555    protected JScrollPane embeddInScrollPane(JTable table) {
    5656        JScrollPane pane = new JScrollPane(table);
    57         pane.setHorizontalScrollBarPolicy(JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED);
    58         pane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED);
    5957        adjustmentSynchronizer.participateInSynchronizedScrolling(pane.getVerticalScrollBar());
    6058        return pane;
Note: See TracChangeset for help on using the changeset viewer.