mirror of
https://gitee.com/vnotex/vnote.git
synced 2025-07-05 13:59:52 +08:00
DirectoryTree: warn if user does not drop on a folder item
This commit is contained in:
parent
b6b73c3f82
commit
5b996654cf
@ -1245,6 +1245,17 @@ bool VDirectoryTree::dropMimeData(QTreeWidgetItem *p_parent,
|
||||
{
|
||||
Q_UNUSED(p_index);
|
||||
|
||||
if (!p_parent) {
|
||||
VUtils::showMessage(QMessageBox::Warning,
|
||||
tr("Warning"),
|
||||
tr("Please drop it on a folder item."),
|
||||
"",
|
||||
QMessageBox::Ok,
|
||||
QMessageBox::Ok,
|
||||
this);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (p_data->hasFormat(ClipboardConfig::c_format)) {
|
||||
VDirectory *dir = getVDirectory(p_parent);
|
||||
if (!dir) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user