Ignore:
Timestamp:
2005-10-02T20:32:00+02:00 (19 years ago)
Author:
imi
Message:

added mapmodes for adding and combining stuff. Reorganized images

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/org/openstreetmap/josm/gui/MapFrame.java

    r4 r7  
    2525import javax.swing.event.ChangeListener;
    2626
     27import org.openstreetmap.josm.actions.mapmode.AddLineSegmentAction;
     28import org.openstreetmap.josm.actions.mapmode.AddNodeAction;
     29import org.openstreetmap.josm.actions.mapmode.AddTrackAction;
     30import org.openstreetmap.josm.actions.mapmode.CombineAction;
    2731import org.openstreetmap.josm.actions.mapmode.DebugAction;
     32import org.openstreetmap.josm.actions.mapmode.DeleteAction;
    2833import org.openstreetmap.josm.actions.mapmode.MapMode;
     34import org.openstreetmap.josm.actions.mapmode.MoveAction;
    2935import org.openstreetmap.josm.actions.mapmode.SelectionAction;
    3036import org.openstreetmap.josm.actions.mapmode.ZoomAction;
     
    3945 * @author imi
    4046 */
    41 public class MapFrame extends JComponent {
     47public class MapFrame extends JPanel {
    4248
    4349        /**
     
    123129
    124130                add(mapView = new MapView(dataSet), BorderLayout.CENTER);
    125                
     131
     132                // toolbar
    126133                toolBarActions.setFloatable(false);
    127134                toolBarActions.add(new IconToggleButton(this, new ZoomAction(this)));
    128135                toolBarActions.add(new IconToggleButton(this, new SelectionAction(this)));
     136                toolBarActions.add(new IconToggleButton(this, new MoveAction(this)));
     137                toolBarActions.add(new IconToggleButton(this, new AddNodeAction(this)));
     138                toolBarActions.add(new IconToggleButton(this, new AddLineSegmentAction(this)));
     139                toolBarActions.add(new IconToggleButton(this, new AddTrackAction(this)));
     140                toolBarActions.add(new IconToggleButton(this, new CombineAction(this)));
     141                toolBarActions.add(new IconToggleButton(this, new DeleteAction(this)));
    129142                toolBarActions.add(new IconToggleButton(this, new DebugAction(this)));
    130143
     
    159172        public void selectMapMode(MapMode mapMode) {
    160173                if (this.mapMode != null)
    161                         this.mapMode.unregisterListener(mapView);
     174                        this.mapMode.unregisterListener();
    162175                this.mapMode = mapMode;
    163                 mapMode.registerListener(mapView);
     176                mapMode.registerListener();
    164177        }
    165178
Note: See TracChangeset for help on using the changeset viewer.