| | |
| | | * information: "Portions Copyright [year] [name of copyright owner]". |
| | | * |
| | | * Copyright 2009-2010 Sun Microsystems, Inc. |
| | | * Portions Copyright 2014-2015 ForgeRock AS. |
| | | * Portions Copyright 2014-2016 ForgeRock AS. |
| | | */ |
| | | |
| | | package org.opends.guitools.controlpanel.ui; |
| | |
| | | import org.forgerock.i18n.LocalizableMessage; |
| | | import org.opends.server.backends.task.RecurringTask; |
| | | |
| | | /** |
| | | * The panel that allows the user to specify when a task will be launched. |
| | | * |
| | | */ |
| | | /** The panel that allows the user to specify when a task will be launched. */ |
| | | public class TaskToSchedulePanel extends StatusGenericPanel |
| | | { |
| | | private static final long serialVersionUID = 6855081932432566784L; |
| | |
| | | createLayout(); |
| | | } |
| | | |
| | | /** |
| | | * Creates the layout of the panel (but the contents are not populated here). |
| | | */ |
| | | /** Creates the layout of the panel (but the contents are not populated here). */ |
| | | private void createLayout() |
| | | { |
| | | GridBagConstraints gbc = new GridBagConstraints(); |
| | |
| | | |
| | | scheduleType.addItemListener(new ItemListener() |
| | | { |
| | | @Override |
| | | public void itemStateChanged(ItemEvent ev) |
| | | { |
| | | Object element = scheduleType.getSelectedItem(); |
| | |
| | | add(Box.createVerticalGlue(), gbc); |
| | | } |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public void toBeDisplayed(boolean visible) |
| | | { |
| | | // Reset the schedule and the labels |
| | |
| | | } |
| | | } |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public LocalizableMessage getTitle() |
| | | { |
| | | return INFO_CTRL_PANEL_TASK_TO_SCHEDULE_TITLE.get(taskName); |
| | | } |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public void okClicked() |
| | | { |
| | | schedule = null; |
| | |
| | | return schedule == null; |
| | | } |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public void configurationChanged(ConfigurationChangeEvent ev) |
| | | { |
| | | } |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public Component getPreferredFocusComponent() |
| | | { |
| | | return scheduleType; |