From 0a7c82c2cf866a6f0c7673b2136dd478fa755415 Mon Sep 17 00:00:00 2001 From: kushagra Date: Fri, 10 Apr 2015 23:52:11 +0530 Subject: [PATCH] Right clicking anywhere wont unhighlight text, fixes #1517 --- src/chatlog/chatlog.cpp | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/src/chatlog/chatlog.cpp b/src/chatlog/chatlog.cpp index 7a3795912..45a9a293d 100644 --- a/src/chatlog/chatlog.cpp +++ b/src/chatlog/chatlog.cpp @@ -177,33 +177,17 @@ void ChatLog::mousePressEvent(QMouseEvent* ev) { QGraphicsView::mousePressEvent(ev); - QPointF scenePos = mapToScene(ev->pos()); - if(ev->button() == Qt::LeftButton) { clickPos = ev->pos(); clearSelection(); } - - if(ev->button() == Qt::RightButton) - { - if(!isOverSelection(scenePos)) - clearSelection(); - } } void ChatLog::mouseReleaseEvent(QMouseEvent* ev) { QGraphicsView::mouseReleaseEvent(ev); - QPointF scenePos = mapToScene(ev->pos()); - - if(ev->button() == Qt::RightButton) - { - if(!isOverSelection(scenePos)) - clearSelection(); - } - selectionScrollDir = NoDirection; }