Ignore:
Timestamp:
2009-07-03T12:33:32+02:00 (10 years ago)
Author:
stoecker
Message:

Large rework in projection handling - now allows only switching and more specific projections
TODO:

  • allow subprojections (i.e. settings for projections)
  • setup preferences for subprojections
  • better support of the new projection depending world bounds (how to handle valid data outside of world)
  • do not allow to zoom out of the world - zoom should stop when whole world is displayed
  • fix Lambert and SwissGrid to handle new OutOfWorld style and subprojections
  • fix new UTM projection
  • handle layers with fixed projection on projection change
  • allow easier projection switching (e.g. in menu)

NOTE:
This checkin very likely will cause problems. Please report or fix them. Older plugins may have trouble. The SVN plugins
have been fixed but may have problems nevertheless. This is a BIG change, but will make JOSMs internal structure much cleaner
and reduce lots of projection related problems.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/gpx/GpxData.java

    r1677 r1722  
    4040    public Collection<WayPoint> waypoints = new LinkedList<WayPoint>();
    4141
    42     public Bounds bounds;
    43 
    4442    public void mergeFrom(GpxData other) {
    4543        if (storageFile == null && other.storageFile != null) {
     
    8280
    8381    // FIXME might perhaps use visitor pattern?
    84     public void recalculateBounds() {
    85         bounds = null;
     82    public Bounds recalculateBounds() {
     83        Bounds bounds = null;
    8684        for (WayPoint wpt : waypoints) {
    8785            if (bounds == null) {
     
    111109            }
    112110        }
    113         if (bounds == null) {
    114             bounds = new Bounds();
    115         }
     111        return bounds;
    116112    }
    117113
Note: See TracChangeset for help on using the changeset viewer.