[wxPython] wxListBox and Drag & Drop bug?

Hi,

   I'm having some problems with implementing drag & drop from a wxListBox
widget. What happens is that once the "DoDragDrop()" call has been made,
everything goes strange. :slight_smile: More precisely the derived wxListBox widget never
gets a mouse up event, and just moving the mouse over the items in the list is
selecting them (this also when trying to drag from the widget, but only on
wxGTK not wxWIN, everything else applies to both). After the mouse button has
been released, no other widgets in the program are functioning properly until I
have clicked once in the ListBox or 2 or 3 times on other widgets in the
application. The following is a snippet from the code of my derived widget:

class DnDListBox(wxListBox):
  def __init__(self,parent,choices,name):
    wxListBox.__init__(self,parent,-1,choices=choices,name=name)
    EVT_MOTION(self,self.OnMouseMove)

  def OnMouseMove(self,event):
    if event.LeftIsDown():
      dob = wxTextDataObject('Dnd test data')
      ds = wxDropSource(self)
      ds.SetData(dob)
      ds.DoDragDrop()
    else:
      event.Skip()

Is there something else I have to do, that I have forgotten? I tried the same
but with wxButton and it worked just great. How can I block selections from the
ListBox widget when I'm in the process of doing a drag operation (visually) ?

Any tips or hints anyone?