-rw-r--r-- | korganizer/koagendaview.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/korganizer/koagendaview.cpp b/korganizer/koagendaview.cpp index f8301f8..918931a 100644 --- a/korganizer/koagendaview.cpp +++ b/korganizer/koagendaview.cpp @@ -419,33 +419,32 @@ KOAgendaView::KOAgendaView(Calendar *cal,QWidget *parent,const char *name) : else widebut = (widebut*3) / 2; //mExpandButton->setSizePolicy( QSizePolicy( QSizePolicy::Fixed, // QSizePolicy::Fixed ) ); mExpandButton->setFixedSize( widebut, widebut); connect( mExpandButton, SIGNAL( clicked() ), SIGNAL( toggleExpand() ) ); mExpandButton->setFocusPolicy(NoFocus); mAllDayAgenda = new KOAgenda(1,mAllDayFrame); mAllDayAgenda->setFocusPolicy(NoFocus); QVBox *dummyAllDayRight = new QVBox(mAllDayFrame); QPushButton *dummyAllDayRightB = new QPushButton(dummyAllDayRight); mDummyAllDayRightL = new QLabel ( dummyAllDayRight ); dummyAllDayRightB->setFlat( true ); dummyAllDayRightB->setFocusPolicy(NoFocus); - // dummyAllDayRightB->setSizePolicy(QSizePolicy( QSizePolicy::Expanding ,QSizePolicy::Expanding )); dummyAllDayRightB->setFixedHeight( (dummyAllDayRightB->sizeHint().height()/4)*3 ); QPopupMenu * wpo = new QPopupMenu (this); wpo->insertItem( i18n("W#"), 0 ); int i; for ( i = 1; i < 53; i++ ) wpo->insertItem( QString::number( i ),i ); //Qt bug - we must add some empty fields... for ( i = 53; i < 54; ++i ) { wpo->insertItem( "", 52 ); } dummyAllDayRightB->setPopup( wpo ); connect( wpo, SIGNAL( activated(int) ), SIGNAL( selectWeekNum ( int ) ) ); // Create event context menu for all day agenda mAllDayAgendaPopup = eventPopup(); @@ -578,33 +577,33 @@ KOAgendaView::KOAgendaView(Calendar *cal,QWidget *parent,const char *name) : // connect( mAgenda, SIGNAL( cloneIncidenceSignal(Incidence *) ), SIGNAL( cloneIncidenceSignal(Incidence *) ) ); //connect( mAllDayAgenda, SIGNAL( cloneIncidenceSignal(Incidence *) ), SIGNAL( cloneIncidenceSignal(Incidence *) ) ); QFont dlf = KOPrefs::instance()->mTimeLabelsFont; QFontMetrics fm ( dlf ); QString dayTest = "30"; int wid = fm.width( dayTest ); int maxWid = dummyAllDayRight->width(); int fontPoint = dlf.pointSize(); while ( wid > maxWid ) { --fontPoint; dlf.setPointSize( fontPoint ); QFontMetrics f( dlf ); wid = f.width( dayTest ); } mDummyAllDayRightL->setFont( dlf ); - + mDummyAllDayRightL->setAlignment( AlignHCenter ); } void KOAgendaView::toggleAllDay() { if ( mSplitterAgenda->firstHandle() ) mSplitterAgenda->firstHandle()->toggle(); } void KOAgendaView::addToCalSlot(Incidence * inc, Incidence * incOld ) { calendar()->addIncidence( inc ); if ( incOld ) { if ( incOld->type() == "Todo" ) emit todoMoved((Todo*)incOld, KOGlobals::EVENTEDITED ); else emit incidenceChanged(incOld, KOGlobals::EVENTEDITED); |