forked from qt-creator/qt-creator
debugger: handle "bad" characters when d&d'ing new watchers
Change-Id: I9847a1e22d9dc384658972c1462c4f6d42654daa Reviewed-by: hjk <qthjk@ovi.com>
This commit is contained in:
@@ -550,7 +550,11 @@ void WatchTreeView::dragMoveEvent(QDragMoveEvent *ev)
|
||||
void WatchTreeView::dropEvent(QDropEvent *ev)
|
||||
{
|
||||
if (ev->mimeData()->hasText()) {
|
||||
watchExpression(ev->mimeData()->text());
|
||||
QString exp;
|
||||
QString data = ev->mimeData()->text();
|
||||
foreach (const QChar c, data)
|
||||
exp.append(c.isPrint() ? c : QChar(QLatin1Char(' ')));
|
||||
watchExpression(exp);
|
||||
//ev->acceptProposedAction();
|
||||
ev->setDropAction(Qt::CopyAction);
|
||||
ev->accept();
|
||||
|
||||
Reference in New Issue
Block a user