fix arbitrary content being dragged and dropped causing errors

Fixes #2630
This commit is contained in:
Ugur Ilter
2024-08-29 11:04:33 +03:00
committed by Uğur İLTER
parent 7b5c95213f
commit 3892dfc78c
8 changed files with 32 additions and 0 deletions

View File

@@ -56,6 +56,10 @@ class CommandViewDrop(wx.DropTarget):
def OnData(self, x, y, t):
if self.GetData():
dragged_data = DragDropHelper.data
if dragged_data is None:
return t
data = dragged_data.split(':')
self.dropFn(x, y, data)
return t