-rw-r--r-- | korganizer/komonthview.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/korganizer/komonthview.cpp b/korganizer/komonthview.cpp index d825493..940d288 100644 --- a/korganizer/komonthview.cpp +++ b/korganizer/komonthview.cpp @@ -125,4 +125,5 @@ void KNoScrollListBox::keyPressEvent(QKeyEvent *e) break; } + if ( count() ) { setCurrentItem((currentItem()+count()-1)%count()); if(!itemVisible(currentItem())) { @@ -133,4 +134,5 @@ void KNoScrollListBox::keyPressEvent(QKeyEvent *e) } } + } break; case Key_Down: @@ -139,4 +141,5 @@ void KNoScrollListBox::keyPressEvent(QKeyEvent *e) break; } + if ( count () ) { setCurrentItem((currentItem()+1)%count()); if(!itemVisible(currentItem())) { @@ -147,4 +150,5 @@ void KNoScrollListBox::keyPressEvent(QKeyEvent *e) } } + } break; case Key_I: @@ -163,4 +167,5 @@ void KNoScrollListBox::keyPressEvent(QKeyEvent *e) void KNoScrollListBox::oneDown() { + if ( count () ) { setCurrentItem((currentItem()+1)%count()); if(!itemVisible(currentItem())) { @@ -172,4 +177,5 @@ void KNoScrollListBox::oneDown() } } +} void KNoScrollListBox::keyReleaseEvent(QKeyEvent *e) { |