[etoys-dev] Etoys: Tools-kfr.14.mcz
sthomas1 at gosargon.com
Fri Dec 14 00:14:26 EST 2012
Thanks, so just to ensure my understanding, this is basically allows me to
drop a "tile representing an object" into a textual script and the
referencenName (as opposed to the externalName, which is what the user sees
when you get the halo) is inserted for use in the textual script. This is
needed because the externalName is not necessarily unique and can't be
referenced directly by just using that name in a script.
So this is good and useful.
Now don't shoot me for asking (and please don't do what I am asking, there
are far more important things I am sure), but...
Wouldn't it be simpler and less confusing for the user if the externalName
was the referenceName?
Of course by simpler, I am only referring to the User's viewpoint, not that
of the programmer :D
On Thu, Dec 13, 2012 at 10:05 AM, Bert Freudenberg <bert at freudenbergs.de>wrote:
> On 2012-12-13, at 07:59, commits at source.squeak.org wrote:
> > Karl Ramberg uploaded a new version of Tools to project Etoys:
> > http://source.squeak.org/etoys/Tools-kfr.14.mcz
> > ==================== Summary ====================
> > Name: Tools-kfr.14
> > Author: kfr
> > Time: 13 December 2012, 8:59:15 am
> > UUID: ca9017f6-5c84-284c-a508-fbabbe39c1dd
> > Ancestors: Tools-kfr.13
> > A little better conversion of tiles to code
> > =============== Diff against Tools-kfr.13 ===============
> > Item was changed:
> > ----- Method: MethodHolder>>acceptDroppingMorph:event:inMorph: (in
> category 'drag and drop') -----
> > acceptDroppingMorph: dropee event: evt inMorph: targetMorph
> > "Return the dropee to its old position, and add a reference to it
> at the cursor point."
> > | externalName |
> > (dropee isTileLike)
> > ifTrue:[dropee isTileMorph
> > + ifFalse:[
> externalName := dropee codeString unparenthetically]
> > - ifFalse:[^dropee
> rejectDropMorphEvent: evt. ]
> ifTrue:[externalName := dropee actualObject uniqueNameForReference]]
> > ifFalse:[externalName := dropee
> assuredPlayer uniqueNameForReference].
> > targetMorph correctSelectionWithString: externalName.
> > dropee rejectDropMorphEvent: evt.
> > ^ true "success"
> > !
> It's a bit misleading that you call the temp var "externalName" because
> the #externalName message returns the user-visible name of a player, not
> the unique name for reference. They are sometimes the same, but sometimes
> not. "referenceName" would be better.
> - Bert -
> etoys-dev mailing list
> etoys-dev at squeakland.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the etoys-dev