source: josm/trunk/src/org/openstreetmap/josm/actions/ZoomInAction.java@ 1054

Last change on this file since 1054 was 1054, checked in by stoecker, 16 years ago

fixed a lot of the shortcut related translations

File size: 754 bytes
Line 
1// License: GPL. Copyright 2007 by Immanuel Scholz and others
2package org.openstreetmap.josm.actions;
3
4import static org.openstreetmap.josm.tools.I18n.tr;
5
6import java.awt.event.ActionEvent;
7import java.awt.event.KeyEvent;
8
9import org.openstreetmap.josm.Main;
10import org.openstreetmap.josm.tools.ShortCut;
11
12public final class ZoomInAction extends JosmAction {
13
14 public ZoomInAction() {
15 super(tr("Zoom in"), "dialogs/zoomin", tr("Zoom in"),
16 ShortCut.registerShortCut("view:zoomin", tr("View: {0}", tr("Zoom in")), KeyEvent.VK_PLUS, ShortCut.GROUP_DIRECT), true);
17 setEnabled(true);
18 }
19
20 public void actionPerformed(ActionEvent e) {
21 double zoom = Main.map.mapView.getScale();
22 Main.map.mapView.zoomTo(Main.map.mapView.getCenter(), zoom * .9);
23 }
24}
Note: See TracBrowser for help on using the repository browser.