Ignore:
Timestamp:
2012-05-12T18:23:08+02:00 (12 years ago)
Author:
bastiK
Message:

separate preference gui from core projection code (there may be bugs)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/projection/CustomProjection.java

    r5228 r5234  
    4040     * null means fall back mode (Mercator)
    4141     */
    42     protected String pref = null;
     42    protected String pref;
    4343    protected Bounds bounds;
    4444
     
    8787            this.key = key;
    8888            this.hasValue = hasValue;
     89        }
     90    }
     91
     92    public CustomProjection() {
     93        this.pref = null;
     94    }
     95
     96    public CustomProjection(String pref) {
     97        try {
     98            this.pref = pref;
     99            update(pref);
     100        } catch (ProjectionConfigurationException ex) {
     101            try {
     102                update(null);
     103            } catch (ProjectionConfigurationException ex1) {
     104                throw new RuntimeException();
     105            }
    89106        }
    90107    }
Note: See TracChangeset for help on using the changeset viewer.