Ignore:
Timestamp:
2013-11-03T01:06:23+01:00 (11 years ago)
Author:
Don-vip
Message:

Checkstyle:

  • private constructors for util classes
  • final classes
  • missing "else" statements
  • import cleanup
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/util/TableHelper.java

    r5927 r6362  
    1010 * The class that provide common JTable customization methods
    1111 */
    12 public class TableHelper {
     12public final class TableHelper {
     13   
     14    private TableHelper() {
     15        // Hide default constructor for utils classes
     16    }
     17   
    1318    /**
    14     * (originally from @class org.openstreetmap.josm.gui.preferences.SourceEditor)
    15     * adjust the preferred width of column col to the maximum preferred width of the cells
    16     * requires JTable.setAutoResizeMode(JTable.AUTO_RESIZE_OFF);
    17     */
     19     * (originally from @class org.openstreetmap.josm.gui.preferences.SourceEditor)
     20     * adjust the preferred width of column col to the maximum preferred width of the cells
     21     * requires JTable.setAutoResizeMode(JTable.AUTO_RESIZE_OFF);
     22     */
    1823    public static void adjustColumnWidth(JTable tbl, int col, int maxColumnWidth) {
    1924        int maxwidth = 0;
     
    2631        tbl.getColumnModel().getColumn(col).setPreferredWidth(Math.min(maxwidth+10, maxColumnWidth));
    2732    }
    28    
    2933}
Note: See TracChangeset for help on using the changeset viewer.