summaryrefslogtreecommitdiffabout
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/koagenda.cpp35
-rw-r--r--korganizer/kodaymatrix.cpp7
-rw-r--r--korganizer/kotodoview.cpp4
-rw-r--r--korganizer/koviewmanager.cpp4
-rw-r--r--korganizer/kowhatsnextview.cpp1
5 files changed, 29 insertions, 22 deletions
diff --git a/korganizer/koagenda.cpp b/korganizer/koagenda.cpp
index 0aef929..ffa2678 100644
--- a/korganizer/koagenda.cpp
+++ b/korganizer/koagenda.cpp
@@ -439,15 +439,5 @@ bool KOAgenda::eventFilter_mouse(QObject *object, QMouseEvent *me)
if (me->button() == RightButton ) {
blockNewEvent = true;
- //qDebug("right ");
- int x,y;
- viewportToContents(viewportPos.x(),viewportPos.y(),x,y);
- int gx,gy;
- contentsToGrid(x,y,gx,gy);
- mStartCellX = gx;
- mStartCellY = gy;
- mCurrentCellX = gx;
- mCurrentCellY = gy;
- mNewItemPopup->popup( viewport()->mapToGlobal( me->pos() ) );
-
+ block = false;
} else {
blockNewEvent = false;
@@ -459,6 +449,22 @@ bool KOAgenda::eventFilter_mouse(QObject *object, QMouseEvent *me)
case QEvent::MouseButtonRelease:
- //qDebug("QEvent::MouseButtonRelease: ");
- if (me->button() == RightButton && block ) {
+ //qDebug("QEvent::MouseButtonRelease: %d",blockNewEvent );
+ if (me->button() == RightButton && blockNewEvent && !block) {
+ int x,y;
+ viewportToContents(viewportPos.x(),viewportPos.y(),x,y);
+ int gx,gy;
+ contentsToGrid(x,y,gx,gy);
+ if ( mCurrentCellY < mStartCellY +1 ) {
+ //qDebug("mCurrentCellY %d mStartCellY %d ", mCurrentCellY,mStartCellY);
+ mCurrentCellX = gx;
+ mCurrentCellY = gy;
+ mStartCellX = gx;
+ mStartCellY = gy;
+ mNewItemPopup->popup( viewport()->mapToGlobal( me->pos() ) );
+ break;
+ } else {
+ blockNewEvent = false;
+ }
+ } else if (me->button() == RightButton && block ) {
if (object != viewport()) {
mClickedItem = (KOAgendaItem *)object;
@@ -490,7 +496,6 @@ bool KOAgenda::eventFilter_mouse(QObject *object, QMouseEvent *me)
}
endItemAction();
- } else if ( mActionType == SELECT ) {
+ } else if ( mActionType == SELECT ) {
if (me->button() == RightButton ) {
-
} else {
endSelectAction( !blockNewEvent );
diff --git a/korganizer/kodaymatrix.cpp b/korganizer/kodaymatrix.cpp
index 060b4c4..faa2c21 100644
--- a/korganizer/kodaymatrix.cpp
+++ b/korganizer/kodaymatrix.cpp
@@ -149,6 +149,5 @@ void KODayMatrix::setStartDate(QDate start)
void KODayMatrix::addSelectedDaysTo(DateList& selDays)
{
- kdDebug() << "KODayMatrix::addSelectedDaysTo() - " << "mSelStart:" << mSelStart << endl;
-
+
if (mSelStart == NOSELECTION) {
return;
@@ -290,7 +289,7 @@ void KODayMatrix::updateView(QDate actdate)
mDayChanged = true;
}
- qDebug("restart Timer %d", mDayChanged );
+ qDebug("restart Timer %d vis: %d", mDayChanged, isVisible() );
static int iii = 0;
- if ( iii < 5 ) {
+ if ( iii < 2 ) {
++iii;
updateViewTimed();
diff --git a/korganizer/kotodoview.cpp b/korganizer/kotodoview.cpp
index 2f5259f..8d8fc2a 100644
--- a/korganizer/kotodoview.cpp
+++ b/korganizer/kotodoview.cpp
@@ -754,5 +754,5 @@ void KOTodoView::showItem(QListViewItem *item,const QPoint &,int)
}
-void KOTodoView::popupMenu(QListViewItem *item,const QPoint &,int column)
+void KOTodoView::popupMenu(QListViewItem *item,const QPoint &p,int column)
{
pendingSubtodo = 0;
@@ -770,5 +770,5 @@ void KOTodoView::popupMenu(QListViewItem *item,const QPoint &,int column)
getCategoryPopupMenu((KOTodoViewItem *)item)->popup(QCursor::pos ()); break;
default:
- mItemPopupMenu->popup(QCursor::pos());
+ mItemPopupMenu->popup(QCursor::pos());
}
} else mPopupMenu->popup(QCursor::pos());
diff --git a/korganizer/koviewmanager.cpp b/korganizer/koviewmanager.cpp
index 4c03f9a..35774d6 100644
--- a/korganizer/koviewmanager.cpp
+++ b/korganizer/koviewmanager.cpp
@@ -118,7 +118,9 @@ void KOViewManager::showDateView( int view, QDate date)
mMainView->dateNavigator()->selectDates( date, 14);
} else if (view == 6 ) {
- showMonthView();
+ mMainView->dateNavigator()->blockSignals( true );
mMainView->dateNavigator()->selectMonthByDate( date );
mMainView->dateNavigator()->selectDate( date );
+ mMainView->dateNavigator()->blockSignals( false );
+ showMonthView();
} else if (view == 7 ) {
mMainView->dateNavigator()->selectDate( date );
diff --git a/korganizer/kowhatsnextview.cpp b/korganizer/kowhatsnextview.cpp
index d7ff9f2..10665f4 100644
--- a/korganizer/kowhatsnextview.cpp
+++ b/korganizer/kowhatsnextview.cpp
@@ -178,4 +178,5 @@ void KOWhatsNextView::restartTimer()
void KOWhatsNextView::updateView()
{
+ //qDebug("KOWhatsNextView::updateView() ");
if ( mTimer->isActive() )
restartTimer();