Skip to content

Commit 549f44d

Browse files
committed
Fix copying of single cless in Browse Data tab
This was broken in 4b34eb7.
1 parent 3f8fc34 commit 549f44d

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/ExtendedTableWidget.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,6 @@ void ExtendedTableWidget::reloadSettings()
327327

328328
void ExtendedTableWidget::copyMimeData(const QModelIndexList& fromIndices, QMimeData* mimeData, const bool withHeaders, const bool inSQL)
329329
{
330-
331330
QModelIndexList indices = fromIndices;
332331

333332
// Remove all indices from hidden columns, because if we don't we might copy data from hidden columns as well which is very
@@ -356,7 +355,7 @@ void ExtendedTableWidget::copyMimeData(const QModelIndexList& fromIndices, QMime
356355
if (img.loadFromData(data.toByteArray()))
357356
{
358357
// If it's an image, copy the image data to the clipboard
359-
qApp->clipboard()->setImage(img);
358+
mimeData->setImageData(img);
360359
return;
361360
} else {
362361
// It it's not an image, check if it's an empty field
@@ -370,7 +369,7 @@ void ExtendedTableWidget::copyMimeData(const QModelIndexList& fromIndices, QMime
370369
}
371370

372371
// The field isn't empty. Copy the text to the clipboard without quoting (for general plain text clipboard)
373-
qApp->clipboard()->setText(data.toByteArray());
372+
mimeData->setText(data.toByteArray());
374373
return;
375374
}
376375
}

0 commit comments

Comments
 (0)