Drop a component on a Spreadsheet

Hi there,

I have a palette of Buttons of which I want to drag & drop one onto a Spreadsheet component. This doesn’t seem to work. Of course I wrapped the Spreadsheet in a DragAndDropWrapper - and I am able to drop (for examples) Excel files that I drag from the desktop. But if I drag a Button to the spreadsheet - nothing happens.

I made sure that the button can actually be dragged - i.e. I wrapped the button into a DragAndDropDropWrapper()

The “Drag side”

Button b = new Button("Drag me");
DragAndDropWrapper wrapper=new DragAndDropWrapper(b);
wrapper.setDragStartMode(DragStartMode.COMPONENT);
//the drop side
Spreadsheet spreadsheet=...;
DragAndDropWrapper wrapper = new DragAndDropWrapper(spreadsheet);    
wrapper.setDropHandler(...someDropHandler);

Button dropOnMe = new Button("Drop a component");
DragAndDropWrapper dw = new DragAndDropWrapper(dropOnMe);    
dw.setDropHandler(...someDropHandler);

Using that I can drop on the “DropOnMe” Button, but not on the spreadsheet. Am I doing anything wroing here?

Any help is highly appreciated

Matthias