X-Git-Url: https://git.quassel-irc.org/?a=blobdiff_plain;ds=sidebyside;f=src%2Fqtui%2Fchatitem.cpp;h=9e7e1eb687f41cf14d2e2e0fd1702b659bd99130;hb=e7494078ad676d9fd14fab0396f51608a3ad46dc;hp=ed24bbaf72ce687f284fddf2a44c0d31229c56ff;hpb=0125cf23d570d2b8ee4d3fd5407364cf6c5769df;p=quassel.git diff --git a/src/qtui/chatitem.cpp b/src/qtui/chatitem.cpp index ed24bbaf..9e7e1eb6 100644 --- a/src/qtui/chatitem.cpp +++ b/src/qtui/chatitem.cpp @@ -289,9 +289,7 @@ void ChatItem::mousePressEvent(QGraphicsSceneMouseEvent *event) { void ChatItem::mouseReleaseEvent(QGraphicsSceneMouseEvent *event) { if(_selectionMode != NoSelection && !event->buttons() & Qt::LeftButton) { - QString selection - = data(MessageModel::DisplayRole).toString().mid(qMin(_selectionStart, _selectionEnd), qAbs(_selectionStart - _selectionEnd)); - chatScene()->putToClipboard(selection); + chatScene()->selectionToClipboard(QClipboard::Selection); event->accept(); } else event->ignore(); @@ -559,6 +557,7 @@ void ContentsChatItem::hoverMoveEvent(QGraphicsSceneHoverEvent *event) { event->accept(); } +/* void ContentsChatItem::contextMenuEvent(QGraphicsSceneContextMenuEvent *event) { qint16 idx = posToCursor(event->pos()); for(int i = 0; i < privateData()->clickables.count(); i++) { @@ -581,6 +580,7 @@ void ContentsChatItem::contextMenuEvent(QGraphicsSceneContextMenuEvent *event) { } } } +*/ void ContentsChatItem::showWebPreview(const Clickable &click) { #ifndef HAVE_WEBKIT