[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: KDE/kdenetwork/kopete/kopete/chatwindow
From: Roman Jarosz <kedgedev () gmail ! com>
Date: 2009-12-23 22:18:38
Message-ID: 1261606718.450347.24231.nullmailer () svn ! kde ! org
[Download RAW message or body]
SVN commit 1065637 by rjarosz:
Use also alternative (all) shortcut for sending text in the textedit.
BUG: 208444
M +1 -1 kopetechatwindow.cpp
M +9 -6 kopeterichtextwidget.cpp
M +1 -1 kopeterichtextwidget.h
--- trunk/KDE/kdenetwork/kopete/kopete/chatwindow/kopetechatwindow.cpp #1065636:1065637
@@ -354,7 +354,7 @@
if ( !sendMessage || !m_activeView )
return;
- m_activeView->editPart()->textEdit()->setSendKeySequence( sendMessage->shortcut() );
+ m_activeView->editPart()->textEdit()->setSendKeySequenceList( sendMessage->shortcuts() );
}
void KopeteChatWindow::initActions(void)
--- trunk/KDE/kdenetwork/kopete/kopete/chatwindow/kopeterichtextwidget.cpp #1065636:1065637
@@ -58,7 +58,7 @@
KopeteRichTextWidget *q;
KActionCollection *actionCollection;
- QKeySequence sendKeySequence;
+ QList<QKeySequence> sendKeySequenceList;
const Kopete::Protocol::Capabilities protocolCaps;
@@ -445,19 +445,22 @@
if (keyEvent)
{
QKeySequence keyEventSequance(keyEvent->modifiers() + keyEvent->key());
- if (keyEventSequance.matches(d->sendKeySequence))
+ foreach(const QKeySequence& sendKeySequence, d->sendKeySequenceList)
{
- // Don't handle the shortcut for sending text in the textedit
- return false;// QWidget::event(event);
+ if (keyEventSequance.matches(sendKeySequence))
+ {
+ // Don't handle the shortcut for sending text in the textedit
+ return false;// QWidget::event(event);
+ }
}
}
}
return KRichTextWidget::event(event);
}
-void KopeteRichTextWidget::setSendKeySequence(QKeySequence keySequence)
+void KopeteRichTextWidget::setSendKeySequenceList(const QList<QKeySequence>& keySequenceList)
{
- d->sendKeySequence = keySequence;
+ d->sendKeySequenceList = keySequenceList;
}
void KopeteRichTextWidget::setDefaultPlainCharFormat(const QTextCharFormat& format)
--- trunk/KDE/kdenetwork/kopete/kopete/chatwindow/kopeterichtextwidget.h #1065636:1065637
@@ -76,7 +76,7 @@
void setTextItalic(bool italic);
void setTextUnderline(bool underline);
void setTextStrikeOut(bool strikeout);
- void setSendKeySequence(QKeySequence keySequence);
+ void setSendKeySequenceList(const QList<QKeySequence>& keySequenceList);
void slotResetFontAndColor();
void slotCheckSpellingChanged(bool b);
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic