[Panel-devel] Drop not working for plasmoids?

Friedrich W. H. Kossebau kossebau at kde.org
Thu Aug 16 07:41:13 CEST 2007


Am Donnerstag, 16. August 2007, schrieb Aaron J. Seigo:
> On Wednesday 15 August 2007, Friedrich W. H. Kossebau wrote:
> > is it a known problem that drop events are eaten by someone and never
> > reach a plasmoid? (move and leave events do, enter events don't, too). Or
> > did I do something wrong? The plasmoids in playground seem to ignore
> > drops, too.
>
> a quick look at the code says that this is a bug in Corona. the same fix
> that was applied to DesktopView::wheelEvent needs to be applied to
> Corona::dropEvent. i'll fix this as soon as i'm back at my sister's place
> again this evening unless someone beats me to it =)

Having this pointer I tried a fix by calling the default handler for events 
over items in Corona::dropEvent:
    if (itemAt(event->scenePos())) {
        QGraphicsScene::dropEvent(event);
        return;
    }

Honestly I did not know whether to use event->scenePos() or event->pos() 
(where is the difference?). Tried scenePos() and... Works form me (tm), so 
committed :)

Thanks
Friedrich


More information about the Panel-devel mailing list