Logo Search packages:      
Sourcecode: qtodo version File versions  Download package

void QTodoDateEdit::init (  )  [private]

For internal use only.

Definition at line 1101 of file qtodo_datetimeedit.cpp.

References setFocusSection(), stepDown(), stepUp(), updateButtons(), and valueChanged().

Referenced by QTodoDateEdit().

{
      d = new QTodoDateEditPrivate();
      d->controls = new QDateTimeSpinWidget( this, qstrcmp( name(), "qt_datetime_dateedit" ) == 0 ? "qt_spin_widget" : "date edit controls" );
      d->controls->move(d->controls->x()+1,d->controls->y()-1);
      d->ed = new QTodoDateTimeEditor( this, d->controls, "date editor" );
      d->controls->setEditWidget( d->ed );
      setFocusProxy( d->ed );
      connect( d->controls, SIGNAL( stepUpPressed() ), SLOT( stepUp() ) );
      connect( d->controls, SIGNAL( stepDownPressed() ), SLOT( stepDown() ) );
      connect( this, SIGNAL( valueChanged(const QDate&) ),
               SLOT( updateButtons() ) );
      connect( d->ed, SIGNAL(focusInSignal()),this,SLOT(slotFocusInSignal()));
      connect( d->ed, SIGNAL(focusOutSignal()),this,SLOT(slotFocusOutSignal()));

      d->ed->appendSection( QTodoNumberSection( 0,4 ) );
      d->ed->appendSection( QTodoNumberSection( 5,7 ) );
      d->ed->appendSection( QTodoNumberSection( 8,10 ) );

      d->yearSection = -1;
      d->monthSection = -1;
      d->daySection = -1;

      d->y = 0;
      d->m = 0;
      d->d = 0;
      d->dayCache = 0;
      setOrder( localOrder() );
      setFocusSection( 0 );
      d->overwrite = TRUE;
      d->adv = FALSE;
      d->timerId = 0;
      d->typing = FALSE;
      d->min = QDate( 1752, 9, 14 );
      d->max = QDate( 8000, 12, 31 );
      d->changed = FALSE;

      setSizePolicy( QSizePolicy::Minimum, QSizePolicy::Fixed );

      m_spin_width = d->controls->upRect().width();

      refcount++;
}


Generated by  Doxygen 1.6.0   Back to index