author | zautrix <zautrix> | 2005-05-24 19:56:05 (UTC) |
---|---|---|
committer | zautrix <zautrix> | 2005-05-24 19:56:05 (UTC) |
commit | bebdc6ca63f4bcbfb735c3d75710ca53959ef48f (patch) (side-by-side diff) | |
tree | ed755ca04104d571799e91a31443fe94bbf00fdd /korganizer | |
parent | b441ef64338079e3e29c07d8884a02588050a54a (diff) | |
download | kdepimpi-bebdc6ca63f4bcbfb735c3d75710ca53959ef48f.zip kdepimpi-bebdc6ca63f4bcbfb735c3d75710ca53959ef48f.tar.gz kdepimpi-bebdc6ca63f4bcbfb735c3d75710ca53959ef48f.tar.bz2 |
menu fix
-rw-r--r-- | korganizer/koagenda.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/korganizer/koagenda.cpp b/korganizer/koagenda.cpp index 355f4bb..99009a5 100644 --- a/korganizer/koagenda.cpp +++ b/korganizer/koagenda.cpp @@ -381,7 +381,7 @@ bool KOAgenda::eventFilter ( QObject *object, QEvent *event ) void KOAgenda::popupMenu() { mPopupTimer->stop(); - if ( mPopupKind == 1 ) { + if ( mPopupKind == 1 || mPopupKind == 3 ) { if (mActionItem ) { endItemAction(); } @@ -389,17 +389,17 @@ void KOAgenda::popupMenu() if (mPopupItem) { //mClickedItem = mPopupItem; selectItem(mPopupItem); - if ( mAllAgendaPopup && KOPrefs::instance()->mBlockPopupMenu ) + if ( mAllAgendaPopup && KOPrefs::instance()->mBlockPopupMenu && mPopupKind == 1 ) mAllAgendaPopup->installEventFilter( this ); emit showIncidencePopupSignal(mPopupItem->incidence()); } - } else if ( mPopupKind == 2 ) { + } else if ( mPopupKind == 2 || mPopupKind == 4 ) { if ( mLeftMouseDown ) { // we have a simulated right click - clear left mouse action endSelectAction( false ); // do not emit new event signal mLeftMouseDown = false; // no more leftMouse computation } - if ( KOPrefs::instance()->mBlockPopupMenu ) + if ( KOPrefs::instance()->mBlockPopupMenu && mPopupKind == 2 ) mNewItemPopup->installEventFilter( this ); mNewItemPopup->popup( mPopupPos); @@ -470,6 +470,7 @@ bool KOAgenda::eventFilter_mouse(QObject *object, QMouseEvent *me) mPopupItem = (KOAgendaItem *)object; mPopupKind = 1; if (me->button() == RightButton) { + mPopupKind = 3; popupMenu(); } else if (me->button() == LeftButton) { mActionItem = (KOAgendaItem *)object; @@ -499,6 +500,7 @@ bool KOAgenda::eventFilter_mouse(QObject *object, QMouseEvent *me) mCurrentCellY = gy; mStartCellX = gx; mStartCellY = gy; + mPopupKind = 4; popupMenu(); } else if (me->button() == LeftButton) { setCursor(arrowCursor); |