Ignore:
Timestamp:
2003-05-30T14:06:18+12:00 (21 years ago)
Author:
kjdon
Message:

the modal dialog now is one of our special ModalDialogs which only block the parent, enabling the use of help files while the dialog is open. A SimpleMenuBar with help on it has been added to the dialog.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gli/src/org/greenstone/gatherer/gui/EditorDialog.java

    r4367 r4427  
    4040import javax.swing.*;
    4141import org.greenstone.gatherer.Gatherer;
     42import org.greenstone.gatherer.gui.SimpleMenuBar;
     43import org.greenstone.gatherer.gui.ModalDialog;
     44
    4245/** A class that extends a JDialog into a editor for editing large block of text for the metadata value.
    4346 * @author John Thompson, Greenstone Digital Library, University of Waikato
     
    4548 */
    4649final public class EditorDialog
    47     extends JDialog
     50    extends ModalDialog
    4851    implements ActionListener {
    4952    /** The cancel, and I don't want the text I've typed, button. */
     
    5659    private String result = null;
    5760    /** The size of the edit pop-up. */
    58     final static private Dimension SIZE = new Dimension(400,400);
     61    final static private Dimension SIZE = new Dimension(400,425);
    5962    /** Constructor.*/
    6063    public EditorDialog() {
     64    super(Gatherer.g_man);
     65   
    6166    }
    6267    /** Any implementation of ActionListener must include this method so we can be informed when an action has been performed on one of our target controls. In this case we generate a pop-up window to edit in.
     
    7782    setSize(SIZE);
    7883    setTitle(Gatherer.dictionary.get("General.Edit"));
     84    setJMenuBar(new SimpleMenuBar("6.1"));
    7985    // Create
    8086    cancel = new JButton(Gatherer.dictionary.get("General.Cancel"));
     
    101107    Dimension screen_size = Gatherer.config.screen_size;
    102108    setLocation((screen_size.width - SIZE.width) / 2, (screen_size.height - SIZE.height) / 2);
    103     show();
     109    setVisible(true);
    104110    return result;
    105111    }
Note: See TracChangeset for help on using the changeset viewer.