// File: ActionShowContent.java // Classes: ActionShowContent // Original Author: kedar patankar // Date 21 Jan 1997 package uci.graphedit; import java.util.Vector; import java.awt.Dialog; import gjt.DialogClient; /** Action to show the help topics */ public class ActionShowDocuments extends Action implements DialogClient { private Vector openDocumentNames; public ActionShowDocuments(Editor e,Vector v) { super(e); openDocumentNames=v; } public String name() { return "Show Documents dialog"; } public void doIt() { WindowDialog wd = new WindowDialog(_editor,this,"Windows",openDocumentNames); wd.show(); } public void undoIt() { } public void dialogDismissed(Dialog d) { String choice=((WindowDialog)d).getRequest(); String name=((WindowDialog)d).getSelection(); if(choice.equals("SHOW")) _editor.showDocument(name); else { Action act=new ActionClose(_editor,_editor.getDocument(name)); act.doIt(); } } } /* end class ActionShowContent */