author | zautrix <zautrix> | 2005-02-02 21:31:25 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-02-02 21:31:25 (UTC) |
commit | 279354f19275e5e654636acb87c465edf652eeae (patch) (side-by-side diff) | |
tree | 1721c6201fa28392cb02a80510c47a12ae4e0d4c | |
parent | f79d089ec5c44a27f9005da76e452b4574eae27f (diff) | |
download | kdepimpi-279354f19275e5e654636acb87c465edf652eeae.zip kdepimpi-279354f19275e5e654636acb87c465edf652eeae.tar.gz kdepimpi-279354f19275e5e654636acb87c465edf652eeae.tar.bz2 |
fifix
-rw-r--r-- | bin/kdepim/korganizer/germantranslation.txt | 4 | ||||
-rw-r--r-- | korganizer/koagendaview.cpp | 25 | ||||
-rw-r--r-- | korganizer/navigatorbar.cpp | 22 |
3 files changed, 34 insertions, 17 deletions
diff --git a/bin/kdepim/korganizer/germantranslation.txt b/bin/kdepim/korganizer/germantranslation.txt index 00f5c28..ec08321 100644 --- a/bin/kdepim/korganizer/germantranslation.txt +++ b/bin/kdepim/korganizer/germantranslation.txt @@ -1207,4 +1207,4 @@ { "Default todo done color:","Standard Todo erledigt Farbe" }, -{ "","" }, -{ "","" }, +{ "Select week %1-%2","Selektiere Woche %1-%2" }, +{ "Select Week","Selektiere Woche" }, { "","" }, diff --git a/korganizer/koagendaview.cpp b/korganizer/koagendaview.cpp index 918931a..1908b1c 100644 --- a/korganizer/koagendaview.cpp +++ b/korganizer/koagendaview.cpp @@ -435,13 +435,22 @@ KOAgendaView::KOAgendaView(Calendar *cal,QWidget *parent,const char *name) : dummyAllDayRightB->setFixedHeight( (dummyAllDayRightB->sizeHint().height()/4)*3 ); + QPopupMenu * wpo = new QPopupMenu (this); - wpo->insertItem( i18n("W#"), 0 ); + QPopupMenu * all = new QPopupMenu (this); + //wpo->insertItem( i18n("W#"), 0 ); + int first = 1; int i; - for ( i = 1; i < 53; i++ ) + for ( i = 1; i < 50; ++i ) { + if ( !(i%10) ) { + all->insertItem( i18n("Select week %1-%2" ).arg(first).arg( i-1) ,wpo ); + connect( wpo, SIGNAL( activated(int) ), SIGNAL( selectWeekNum ( int ) ) ); + first = i; + wpo = new QPopupMenu (this); + } 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 ); - + for ( i = 50; i < 53; ++i ) { + wpo->insertItem( QString::number(i), i); + } + all->insertItem( i18n("Select week %1-%2" ).arg(first).arg( i-1) ,wpo ); + dummyAllDayRightB->setPopup( all ); connect( wpo, SIGNAL( activated(int) ), SIGNAL( selectWeekNum ( int ) ) ); @@ -583,3 +592,3 @@ KOAgendaView::KOAgendaView(Calendar *cal,QWidget *parent,const char *name) : int wid = fm.width( dayTest ); - int maxWid = dummyAllDayRight->width(); + int maxWid = dummyAllDayRight->width()-2; int fontPoint = dlf.pointSize(); diff --git a/korganizer/navigatorbar.cpp b/korganizer/navigatorbar.cpp index 2406bb5..24de01f 100644 --- a/korganizer/navigatorbar.cpp +++ b/korganizer/navigatorbar.cpp @@ -138,13 +138,21 @@ NavigatorBar::NavigatorBar( const QDate & date, QWidget *parent, const char *nam if ( insertWeek ) { - //shit : bug in Qt. after inserting 53 item, only 51 are shown... QPopupMenu * wpo = new QPopupMenu (this); - wpo->insertItem( i18n("W#"), 0 ); - for ( i = 1; i < 53; ++i ) { + QPopupMenu * all = new QPopupMenu (this); + //wpo->insertItem( i18n("W#"), 0 ); + int first = 1; + for ( i = 1; i < 50; ++i ) { + if ( !(i%10) ) { + all->insertItem( i18n("Select week %1-%2" ).arg(first).arg( i-1) ,wpo ); + connect( wpo, SIGNAL( activated(int) ), SIGNAL( selectWeek ( int ) ) ); + first = i; + wpo = new QPopupMenu (this); + } wpo->insertItem( QString::number(i), i ); } - for ( i = 53; i < 54; ++i ) { - wpo->insertItem( "", 52 ); + for ( i = 50; i < 53; ++i ) { + wpo->insertItem( QString::number(i), i); } - selWeek->setPopup( wpo ); - selWeek->setFixedWidth( (size/4)*3 ); + all->insertItem( i18n("Select week %1-%2" ).arg(first).arg( i-1) ,wpo ); + selWeek->setPopup( all ); + selWeek->setFixedWidth( (size/5)*4 ); selWeek->setFixedHeight( size ); |