mirror of
https://github.com/linuxdeepin/dde-dock.git
synced 2025-06-04 09:23:03 +00:00
fix crash when drag in other item
Change-Id: I0c29d39d72aad0be96cfde83b2c3f13e5eb45225
This commit is contained in:
parent
8d63061963
commit
197d10471c
@ -80,10 +80,13 @@ void MainPanel::resizeEvent(QResizeEvent *e)
|
|||||||
|
|
||||||
void MainPanel::dragEnterEvent(QDragEnterEvent *e)
|
void MainPanel::dragEnterEvent(QDragEnterEvent *e)
|
||||||
{
|
{
|
||||||
// TODO: check
|
DockItem *dragSourceItem = qobject_cast<DockItem *>(e->source());
|
||||||
|
if (!dragSourceItem)
|
||||||
|
return;
|
||||||
|
|
||||||
e->accept();
|
e->accept();
|
||||||
|
|
||||||
if (qobject_cast<DockItem *>(e->source()))
|
if (dragSourceItem)
|
||||||
DragingItem->show();
|
DragingItem->show();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user