Forward port of:

SVN commit 706484 by tilladam:

Change nasty hack causing re-entrancy when pasting and thus tight loops with clean delegation.
Fixed kolab/issue1923.


svn path=/trunk/KDE/kdepim/; revision=706490
wilder-work
Till Adam 19 years ago
parent ab4c83a924
commit 7f3e787bef
  1. 9
      kmcomposewin.cpp
  2. 4
      kmedit.cpp

@ -383,8 +383,6 @@ KMComposeWin::KMComposeWin( KMMessage *aMsg, uint id )
connect( mEditor, SIGNAL(spellcheck_done(int)),
this, SLOT(slotSpellcheckDone (int)) );
connect( mEditor, SIGNAL( pasteImage() ),
this, SLOT(slotPaste() ) );
connect( mEditor, SIGNAL( attachPNGImageData(const QByteArray &) ),
this, SLOT( slotAttachPNGImageData(const QByteArray &) ) );
connect( mEditor, SIGNAL( focusChanged(bool) ),
@ -3638,9 +3636,10 @@ void KMComposeWin::slotPaste()
}
break;
}
} else {
QKeyEvent k( QEvent::KeyPress, Qt::Key_V, Qt::ControlModifier );
qApp->notify( fw, &k );
} else if ( QTextDrag::canDecode( mimeSource ) ) {
QString s;
if ( QTextDrag::decode( mimeSource, s ) )
mEditor->insert( s );
}
}

@ -619,10 +619,6 @@ void KMEdit::del()
void KMEdit::paste()
{
if ( ! QApplication::clipboard()->image().isNull() ) {
emit pasteImage();
}
else
mComposer->slotPaste();
}

Loading…
Cancel
Save