home *** CD-ROM | disk | FTP | other *** search
- import java.io.File;
- import java.net.URL;
- import mug.app.Command;
-
- public class ImportImageMapFileCommand extends Command {
- private MainShell _app;
-
- public ImportImageMapFileCommand(MainShell var1) {
- this._app = var1;
- }
-
- public void execute() {
- File var1 = this._app.showFileDialog("Import Image Map", 0, new ImageFilenameFilter());
- if (var1 != null) {
- this._app.setBusy(true);
- ImageMap var2 = (ImageMap)this._app.getDocument();
- var2.import_(var1);
- this._app.getMapCanvas().loadImage((URL)null, var2.getBaseFile(), var2.getImgSrc());
- this._app.setBusy(false);
- ((Command)this).executeNext();
- }
- }
- }
-