Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
package org.nuiton.jaxx.widgets.datetime;
/*-
* #%L
* JAXX :: Widgets DateTime
* %%
* Copyright (C) 2008 - 2018 Code Lutin, Ultreia.io
* %%
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as
* published by the Free Software Foundation, either version 3 of the
* License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Lesser Public License for more details.
*
* You should have received a copy of the GNU General Lesser Public
* License along with this program. If not, see
* .
* #L%
*/
import java.awt.BorderLayout;
import java.awt.Container;
import java.awt.LayoutManager;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.TreeMap;
import javax.swing.DefaultBoundedRangeModel;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JSlider;
import javax.swing.JSpinner;
import javax.swing.JToolBar;
import javax.swing.SpinnerDateModel;
import javax.swing.event.ChangeEvent;
import javax.swing.event.ChangeListener;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import org.nuiton.jaxx.runtime.JAXXBinding;
import org.nuiton.jaxx.runtime.JAXXContext;
import org.nuiton.jaxx.runtime.JAXXObject;
import org.nuiton.jaxx.runtime.JAXXObjectDescriptor;
import org.nuiton.jaxx.runtime.JAXXUtil;
import org.nuiton.jaxx.runtime.binding.DefaultJAXXBinding;
import org.nuiton.jaxx.runtime.binding.SimpleJAXXObjectBinding;
import org.nuiton.jaxx.runtime.context.DefaultJAXXContext;
import org.nuiton.jaxx.runtime.swing.SwingUtil;
import org.nuiton.jaxx.validator.JAXXValidator;
import org.nuiton.jaxx.validator.swing.SwingValidator;
import org.nuiton.jaxx.validator.swing.SwingValidatorUtil;
import org.nuiton.jaxx.validator.swing.meta.Validator;
import org.nuiton.jaxx.validator.swing.meta.ValidatorField;
import org.nuiton.jaxx.validator.swing.ui.ImageValidationUI;
import org.nuiton.jaxx.widgets.hidor.HidorButton;
import static io.ultreia.java4all.i18n.I18n.t;
public class TimeEditor extends JPanel implements JAXXObject, JAXXValidator {
/*-----------------------------------------------------------------------*/
/*---------------- Constants for all javaBean properties ----------------*/
/*-----------------------------------------------------------------------*/
public static final String PROPERTY_SHOW_TIME_EDITOR_SLIDER = "showTimeEditorSlider";
/*-----------------------------------------------------------------------*/
/*------------------ Constants for all public bindings ------------------*/
/*-----------------------------------------------------------------------*/
public static final String BINDING_HOUR_EDITOR_ENABLED = "hourEditor.enabled";
public static final String BINDING_HOUR_MODEL_VALUE = "hourModel.value";
public static final String BINDING_MINUTE_EDITOR_ENABLED = "minuteEditor.enabled";
public static final String BINDING_MINUTE_MODEL_VALUE = "minuteModel.value";
public static final String BINDING_SLIDER_ENABLED = "slider.enabled";
public static final String BINDING_SLIDER_HIDOR_TARGET_VISIBLE = "sliderHidor.targetVisible";
public static final String BINDING_SLIDER_VALUE = "slider.value";
/*-----------------------------------------------------------------------*/
/*------------------------- Other static fields -------------------------*/
/*-----------------------------------------------------------------------*/
private static final String $jaxxObjectDescriptor = "H4sIAAAAAAAAAJ1WzW7bRhBeKZZsS3Zjp0EObooKTprIjUPJbRGgcP/8CyWQ7cByjLQ+pGtxba1LLZndZaRESA499NYX6KGH9tBLkXcIeirQS69+hwJ5hMwsKZGy6ciKDoQ4Mzvzzbez3/Kv/0lGSTLvykNL+Fy7wjqi7bYlfaF5k1n3lh4+3No/YnW9ylRdck+7kgS/VJqk90je7tmVJtZeFTKVgkwlzFQKM5VW3KbnCiZiiRarJKf0U4epBmNak+KZi+tKlWq9yMW258uwViLqpFr//rxwnGKrv6YJaXsAfwravjVEgqjrkSpJc1uTS9Uj+oSWHCoOAZzk4hAamkTbikOV2qRN9pi8IKNVkvWohGSa3H4nekw6k6rtaTJ2/d59KphT1qfxt7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BnnfKhU8Kn36OHU7BXJxM+Vk5mvaZTt9E3xXBxKuA8iEGMLyRB/GTMsf2qQt3OnnvS/iEooV9LmwA9vWprCl85gZmRPPv+PgjOcMHkOENPPNDk6oMAAA=";
private static final Logger log = LogManager.getLogger(TimeEditor.class);
private static final long serialVersionUID = 1L;
/*-----------------------------------------------------------------------*/
/*--------------------------- Internal states ---------------------------*/
/*-----------------------------------------------------------------------*/
protected List