Package gui

Examples of gui.DateCalendar


        dateLabel.setFont(new Font("Tahoma", 1, 12));
        dateLabel.setForeground(new java.awt.Color(66, 79, 120));

        dateLabel.addMouseListener(new MouseListener() {
            public void mouseClicked(MouseEvent e) {
                DateCalendar fen = new DateCalendar(MainWindow.cadrePrincipal(), mode);
                fen.affiche();
                if (fen.okFlag) {
                    Date date = fen.retourDate();
                    if (dateValide(date)) {
                        dateLabel.setText(new SimpleDateFormat(dateFormat).format(date));
                    } else {
                        dateLabel.setText(DATE_ERREUR_TEXTE);
                        MessageBox(MainWindow.desktop(), "DATE INVALIDE...");
View Full Code Here


  public static JLabel cr�eChampDate(final String dateTimeFormat, final IRetourneDate retourneDate, final DateCalendar.Mode dateCalendarMode) {
    final JLabel jLabel = new JLabel(DATE_ERREUR_TEXTE);
    jLabel.setIcon(new ImageIcon(TaxiGuiUtil.class.getClassLoader().getResource("images/logoCalender.jpg")));
    jLabel.addMouseListener(new MouseListener() {
      public void mouseClicked(MouseEvent e) {
        DateCalendar fen = new DateCalendar(MainWindow.cadrePrincipal(), 0, dateCalendarMode);
        fen.affiche();
        jLabel.setText(DATE_ERREUR_TEXTE);
        if (fen.okFlag) {
          Date dateTemp = fen.retourDate();
          if (dateTemp.after(new Date())) {
            MessageBox(MainWindow.desktop(), "DATE INVALIDE...");
          } else {
            if (retourneDate != null) {
              retourneDate.onDate(dateTemp);
View Full Code Here

    textDtNais.setIcon(ani);
    textDtNais.setFont(titreFont);
    textDtNais.setForeground(new java.awt.Color(66, 79, 120));
    textDtNais.addMouseListener(new MouseListener() {
      public void mouseClicked(MouseEvent e) {
        DateCalendar fen = new DateCalendar(MainWindow.cadrePrincipal(), DateCalendar.Mode.DATE_SEULEMENT);
        fen.affiche();

        if (fen.okFlag) {
          Date dateNaissance = fen.retourDate();
          textDtNais.setText(new SimpleDateFormat(MotsCleProjet.DATE_FORMAT).format(dateNaissance));
         
        } else {
          textDtNais.setText(DATE_ERREUR_TEXTE);
          MessageBox(MainWindow.desktop(), "DATE INVALIDE...");
View Full Code Here

      textDateVisitMed.setForeground(new java.awt.Color(66, 79, 120));
      textDateVisitMed.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(66, 79, 120), 2));

      textDateVisitMed.addMouseListener(new MouseListener() {
        public void mouseClicked(MouseEvent e) {
          DateCalendar fen = new DateCalendar(MainWindow.cadrePrincipal(), DateCalendar.Mode.DATE_SEULEMENT);
          fen.affiche();

          if (fen.okFlag) {
            Date strDate = fen.retourDate();
            textDateVisitMed.setText(new SimpleDateFormat(MotsCleProjet.DATE_FORMAT).format(strDate));

          } else {
            textDateVisitMed.setText(DATE_ERREUR_TEXTE);
            MessageBox(MainWindow.desktop(), "DATE INVALIDE...");
View Full Code Here

      textDatePermis.setForeground(new java.awt.Color(66, 79, 120));
      textDatePermis.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(66, 79, 120), 2));

      textDatePermis.addMouseListener(new MouseListener() {
        public void mouseClicked(MouseEvent e) {
          DateCalendar fen = new DateCalendar(MainWindow.cadrePrincipal(), DateCalendar.Mode.DATE_SEULEMENT);
          fen.affiche();

          if (fen.okFlag) {
            Date strDate = fen.retourDate();
            textDatePermis.setText(new SimpleDateFormat(DATE_FORMAT).format(strDate));
           
          }
          else {
            textDatePermis.setText(DATE_ERREUR_TEXTE);
View Full Code Here

      textDateValidite.setForeground(new java.awt.Color(66, 79, 120));
      textDateValidite.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(66, 79, 120), 2));

      textDateValidite.addMouseListener(new MouseListener() {
        public void mouseClicked(MouseEvent e) {
          DateCalendar fen = new DateCalendar(MainWindow.cadrePrincipal(), DateCalendar.Mode.DATE_SEULEMENT);
          fen.affiche();

          if (fen.okFlag) {
            Date strDate = fen.retourDate();
            textDateValidite.setText(new SimpleDateFormat(DATE_FORMAT).format(strDate));

          }
          else {
            textDateValidite.setText(DATE_ERREUR_TEXTE);
View Full Code Here

    textDtDebCont.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(66, 79, 120), 2));
    textDtDebCont.setIcon(ani);   
   
    textDtDebCont.addMouseListener(new MouseListener() {
      public void mouseClicked(MouseEvent e) {
        DateCalendar fen = new DateCalendar(MainWindow.cadrePrincipal(), DateCalendar.Mode.DATE_SEULEMENT);
        fen.affiche();
        if (fen.okFlag) {
          //Date date = fen.retourDate();
          Date date = fen.retourDateSansTime();
          textDtDebCont.setText(new SimpleDateFormat(gui.MotsCleProjet.DATE_FORMAT).format(date));
        } else {
          textDtDebCont.setText(DATE_ERREUR_TEXTE);
          MessageBox(MainWindow.desktop(), "DATE INVALIDE...");
        }
      }

      public void mouseEntered(MouseEvent e) {}
      public void mouseExited(MouseEvent e) {}
      public void mousePressed(MouseEvent e) {}
      public void mouseReleased(MouseEvent e) {}
    });
   
    //textDateFin = new JTextControlKey("",10,IsNumString);
    ani = new ImageIcon(getClass().getClassLoader().getResource("images/logoCalender.jpg"))
      textDtFinCont= new JLabel();
      textDtFinCont.setBorder(javax.swing.BorderFactory.createLineBorder(new java.awt.Color(66, 79, 120), 2));
      textDtFinCont.setIcon(ani)
     
      textDtFinCont.addMouseListener(new MouseListener() {
      public void mouseClicked(MouseEvent e) {
        DateCalendar fen = new DateCalendar(MainWindow.cadrePrincipal(), DateCalendar.Mode.DATE_SEULEMENT);
        fen.affiche();
        if (fen.okFlag) {
          Date date = fen.retourDateSansTime();
          textDtFinCont.setText(new SimpleDateFormat(gui.MotsCleProjet.DATE_FORMAT).format(date));
        } else {
          textDtFinCont.setText("");
        }
      }
View Full Code Here

TOP

Related Classes of gui.DateCalendar

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.