[squeak-dev] Modelling a drag & drop between two Browsers

Chris Muller asqueaker at gmail.com
Wed Jul 3 01:37:45 UTC 2013


I hate to ask, but could the old selection _index_ have help here?

Besides that, I don't know whether something could be done in
TransferMorph>>#justDroppedInto:event:.  TransferMorph knows his
"source" is that the source browser?  If so, maybe it could be told to
do some kind of post-op?

On Tue, Jul 2, 2013 at 2:34 PM, Frank Shearar <frank.shearar at gmail.com> wrote:
> The problem is this: I like having my Browser remember its place, more
> or less, when things disappear.
>
> Say I have two Browsers open. I want to move a class between system
> categories so I click on my victim and drag it to the other Browser's
> system category list. I drop it there, and the move takes place. But I
> lose my place in the source Browser. I want the source Browser to
> select the class either immediately before the removed class or
> immediately after. Not fussed which.
>
> Now the process starts in #dragFromClassList: in the source Browser
> and ends in #dropOnSystemCategories:at: in the target Browser.
>
> Calling #selectClassNamed: in the source Browser in
> #dragFromClassList: is premature because the drag hasn't happened yet,
> and things get weird. But how can I tell the source Browser "ok, the
> drag's done; select the class next to where the moved class was" ?
>
> frank
>


More information about the Squeak-dev mailing list