summaryrefslogtreecommitdiffabout
path: root/korganizer
Side-by-side diff
Diffstat (limited to 'korganizer') (more/less context) (ignore whitespace changes)
-rw-r--r--korganizer/koagenda.cpp3
-rw-r--r--korganizer/koeditorgeneral.cpp15
-rw-r--r--korganizer/koeditorgeneral.h1
3 files changed, 15 insertions, 4 deletions
diff --git a/korganizer/koagenda.cpp b/korganizer/koagenda.cpp
index 5420822..2820ca2 100644
--- a/korganizer/koagenda.cpp
+++ b/korganizer/koagenda.cpp
@@ -548,6 +548,9 @@ bool KOAgenda::eventFilter_mouse(QObject *object, QMouseEvent *me)
break;
case QEvent::MouseButtonDblClick:
+ blockMoving = false;
+ leftMouseDown = false;
+ rightMouseDown = false;
if (object == viewport()) {
selectItem(0);
int x,y;
diff --git a/korganizer/koeditorgeneral.cpp b/korganizer/koeditorgeneral.cpp
index 496f125..4ee5292 100644
--- a/korganizer/koeditorgeneral.cpp
+++ b/korganizer/koeditorgeneral.cpp
@@ -225,6 +225,7 @@ void KOEditorGeneral::initAlarm(QWidget *parent,QBoxLayout *topLayout)
void KOEditorGeneral::pickAlarmSound()
{
+ qDebug("KOEditorGeneral::pickAlarmSound() %d",mAlarmSoundButton->isOn() );
//QString prefix = mAlarmSound;
if (!mAlarmSoundButton->isOn()) {
//mAlarmSound = "";
@@ -232,6 +233,7 @@ void KOEditorGeneral::pickAlarmSound()
QToolTip::add(mAlarmSoundButton, i18n("No sound set"));
mAlarmProgramButton->setOn(true);
mAlarmSoundButton->setOn(false);
+ pickAlarmProgram();
} else {
QString fileName(KFileDialog::getOpenFileName(mAlarmSound,
i18n("*.wav|Wav Files"), 0));
@@ -252,7 +254,7 @@ void KOEditorGeneral::pickAlarmSound()
if (mAlarmProgramButton->isOn())
((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Proc.Al.: ") + getFittingPath(mAlarmProgram) );
if ( mAlarmSoundButton->isOn())
- ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Audio.Al.: ") + getFittingPath(mAlarmSound) );
+ ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Audio Al.: ") + getFittingPath(mAlarmSound) );
}
void KOEditorGeneral::pickAlarmProgram()
@@ -263,8 +265,9 @@ void KOEditorGeneral::pickAlarmProgram()
QToolTip::add(mAlarmProgramButton, i18n("No program set"));
mAlarmProgramButton->setOn(false);
mAlarmSoundButton->setOn(true);
+ pickAlarmSound();
} else {
- QString fileName(KFileDialog::getOpenFileName(mAlarmProgram,i18n("Procedure Alarm.: ") , 0));
+ QString fileName(KFileDialog::getOpenFileName(mAlarmProgram,i18n("Procedure Alarm: ") , 0));
if (!fileName.isEmpty()) {
mAlarmProgram = fileName;
QToolTip::remove(mAlarmProgramButton);
@@ -280,7 +283,7 @@ void KOEditorGeneral::pickAlarmProgram()
if (mAlarmProgramButton->isOn())
((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Proc.Al.: ") + getFittingPath(mAlarmProgram) );
if ( mAlarmSoundButton->isOn())
- ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Sound.Al.: ") + getFittingPath(mAlarmSound) );
+ ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Audio Al.: ") + getFittingPath(mAlarmSound) );
}
@@ -317,7 +320,9 @@ void KOEditorGeneral::enableAlarmEdit(bool enable)
((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Audio Al.: ") + getFittingPath(mAlarmSound) );
}
else {
- ((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Alarm disabled for this item"));
+ ((QWidget*)parent())->topLevelWidget()->setCaption(mAlarmMessage);
+ //((QWidget*)parent())->topLevelWidget()->setCaption(i18n("Edit item: ") + mSummaryEdit->currentText());
+
}
mAlarmTimeEdit->setEnabled(enable);
@@ -363,6 +368,7 @@ void KOEditorGeneral::setDefaults(bool allDay)
mOwnerLabel->setText(i18n("Owner: ") + KOPrefs::instance()->fullName());
#endif
+ mAlarmMessage = i18n("Edit new item");
enableAlarmEdit( !allDay );
// TODO: Implement a KPrefsComboItem to solve this in a clean way.
@@ -394,6 +400,7 @@ void KOEditorGeneral::setSecrecy( int num )
void KOEditorGeneral::readIncidence(Incidence *event)
{
+ mAlarmMessage = i18n("Edit") +" "+event->summary();
mAlarmIncrCombo->setCurrentItem(0);
mSummaryEdit->setEditText(event->summary());
mLocationEdit->setEditText(event->location());
diff --git a/korganizer/koeditorgeneral.h b/korganizer/koeditorgeneral.h
index de8edaf..f4728c7 100644
--- a/korganizer/koeditorgeneral.h
+++ b/korganizer/koeditorgeneral.h
@@ -108,6 +108,7 @@ class KOEditorGeneral : public QObject
QString getFittingPath( const QString ) ;
QString mAlarmSound;
QString mAlarmProgram;
+ QString mAlarmMessage;
};
#endif