package caltool.view.schedule;

import caltool.model.schedule.*;
import javax.swing.*;
import java.awt.*;
import java.awt.event.*;

/**** 
 *
 * Class ListMeetingTimesButtonListener defines the action listener that is
 * attached to the Options button in the schedule meeting dialog.  The
 * actionPerformed method displays a meetings options dialog.
 *
 */

public class MeetingOptionsButtonListener implements ActionListener {

    /**
     * Construct this with the given Schedule model and parent dialog view.
     * Access to the model is for calling its ScheduleAppointment method.
     * Access to the parent view is for gathering date to be sent to Schedule.
     * ScheduleAppointment.
     */
    public MeetingOptionsButtonListener(Schedule schedule,
            ScheduleAppointmentDialog dialog) {
        this.schedule = schedule;
        this.dialog = dialog;
    }

    /**
     * Respond to a press of the OK button by calling ScheduleAppointment with
     * a new Appointment.  The Appointment data are gathered from the
     * JTextFields and other input fields in the parent dialog.
     */
    public void actionPerformed(ActionEvent e) {
        System.out.println(
            "In MeetingOptionsButtonListener.actionPerformed.");
    }

    /** The companion model */
    protected Schedule schedule;

    /** The parent view */
    protected ScheduleAppointmentDialog dialog;

}