Drag and Drop - drag from hook

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

Drag and Drop - drag from hook

Sean P. DeNigris
Administrator
Is there a hook sent to the containing morph when one of its submorphs gets dragged out? I don't see one.

Thanks.
Sean
Cheers,
Sean
Reply | Threaded
Open this post in threaded view
|

Re: Drag and Drop - drag from hook

Hilaire Fernandes
You can achieve the effect with the message #justGrabbedFrom: sent to
the grabbed morph

Hilaire

Le 10/01/2012 17:49, Sean P. DeNigris a écrit :

> Is there a hook sent to the containing morph when one of its submorphs gets
> dragged out? I don't see one.
>
> Thanks.
> Sean
>
> --
> View this message in context: http://forum.world.st/Drag-and-Drop-drag-from-hook-tp4282507p4282507.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
>


--
Dr. Geo -- http://www.drgeo.eu


Reply | Threaded
Open this post in threaded view
|

Re: Drag and Drop - drag from hook

Sean P. DeNigris
Administrator
Hilaire Fernandes wrote
You can achieve the effect with the message #justGrabbedFrom: sent to
the grabbed morph
Thanks Hilaire. I saw that one, but I'm wanting to notify the containing morph (i.e. former owner)
Cheers,
Sean
Reply | Threaded
Open this post in threaded view
|

Re: Drag and Drop - drag from hook

Stéphane Ducasse
In reply to this post by Sean P. DeNigris
long time ago I did a simple drag and drop example to understand how it works.



On Jan 10, 2012, at 5:49 PM, Sean P. DeNigris wrote:

> Is there a hook sent to the containing morph when one of its submorphs gets
> dragged out? I don't see one.
>
> Thanks.
> Sean
>
> --
> View this message in context: http://forum.world.st/Drag-and-Drop-drag-from-hook-tp4282507p4282507.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>


DragAndDropRepel.3.cs (2K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Drag and Drop - drag from hook

Stéphane Ducasse
In reply to this post by Hilaire Fernandes
Ok my example was different. I wanted to know how I can  control dropping.

Stef

On Jan 10, 2012, at 6:22 PM, Hilaire Fernandes wrote:

> You can achieve the effect with the message #justGrabbedFrom: sent to
> the grabbed morph
>
> Hilaire
>
> Le 10/01/2012 17:49, Sean P. DeNigris a écrit :
>> Is there a hook sent to the containing morph when one of its submorphs gets
>> dragged out? I don't see one.
>>
>> Thanks.
>> Sean
>>
>> --
>> View this message in context: http://forum.world.st/Drag-and-Drop-drag-from-hook-tp4282507p4282507.html
>> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>>
>>
>
>
> --
> Dr. Geo -- http://www.drgeo.eu
>
>


Reply | Threaded
Open this post in threaded view
|

Re: Drag and Drop - drag from hook

Hilaire Fernandes
In reply to this post by Sean P. DeNigris
Yes you have to use dispatching. I did no see message sent to the owner
morph by the system.

Hilaire


Le 10/01/2012 18:26, Sean P. DeNigris a écrit :

>
> Hilaire Fernandes wrote
>>
>> You can achieve the effect with the message #justGrabbedFrom: sent to
>> the grabbed morph
>>
>
> Thanks Hilaire. I saw that one, but I'm wanting to notify the containing
> morph (i.e. former owner)
>
> --
> View this message in context: http://forum.world.st/Drag-and-Drop-drag-from-hook-tp4282507p4282654.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
>


--
Dr. Geo -- http://www.drgeo.eu


Reply | Threaded
Open this post in threaded view
|

Re: Drag and Drop - drag from hook

Sean P. DeNigris
Administrator
Hilaire Fernandes wrote
Yes you have to use dispatching.
You mean call a custom method from justGrabbedFrom:? The problem is that the grabbed morph is not a part of my project, and I want the behavior for *any* morph grabbed out of this container.

Hilaire Fernandes wrote
I did no see message sent to the owner
morph by the system.
Yes, I will add a hook and submit to inbox. What should it be called? It's a weird passive-voice situation... #justGrabbedFromMe: aMorph? #justLost:? Ugly, but I can't think of anything better.
Cheers,
Sean
Reply | Threaded
Open this post in threaded view
|

Re: Drag and Drop - drag from hook

ncalexan
Sean P. DeNigris wrote
Hilaire Fernandes wrote
I did no see message sent to the owner
morph by the system.
Yes, I will add a hook and submit to inbox. What should it be called? It's a weird passive-voice situation... #justGrabbedFromMe: aMorph? #justLost:? Ugly, but I can't think of anything better.
#submorphJustGrabbed: aMorph?

Nick