01: /*
02: * uDig - User Friendly Desktop Internet GIS client http://udig.refractions.net (C) 2004,
03: * Refractions Research Inc. This library is free software; you can redistribute it and/or modify it
04: * under the terms of the GNU Lesser General Public License as published by the Free Software
05: * Foundation; version 2.1 of the License. This library is distributed in the hope that it will be
06: * useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
07: * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
08: */
09: package net.refractions.udig.project.internal.command.navigation;
10:
11: import net.refractions.udig.project.command.MapCommand;
12: import net.refractions.udig.project.internal.Messages;
13:
14: import org.eclipse.core.runtime.IProgressMonitor;
15:
16: /**
17: * A command for making the viewport zoom out fully so the entire map is displayed.
18: *
19: * @author jeichar
20: * @since 0.3
21: */
22: public class ZoomExtentCommand extends AbstractNavCommand {
23:
24: /**
25: * @see net.refractions.udig.project.internal.command.MapCommand#copy()
26: */
27: public MapCommand copy() {
28: return new ZoomExtentCommand();
29: }
30:
31: /**
32: * @see net.refractions.udig.project.internal.command.navigation.AbstractNavCommand#runImpl()
33: */
34: protected void runImpl(IProgressMonitor monitor) {
35: model.zoomToExtent();
36: }
37:
38: /**
39: * @see net.refractions.udig.project.command.MapCommand#getName()
40: */
41: public String getName() {
42: return Messages.ZoomExtentCommand_name;
43: }
44:
45: }
|