Ben Coman wrote:
I am trying to combine interactions with subviews in
Mondrian but it
is not working as expected. This is with a fresh Moose 4.6 downloaded
today plus ConfigurationOfMondrian (AlexandreBergel.345) and [
ConfigurationOfMondrian project lastVersion load ].
As a test case, from ( World > Moose > Mondrian Easel ) I combine:
Examples > interaction > variation in node size
Examples > subviews > simple
to produce the following example:
----8<----- view nodes: (1 to: 5) forEach: [:each | view
interaction strongHighlightWhenOver: [ :v | v ]. view shape
rectangle withText; size: 20. view nodes: (1 to: each). view
gridLayout ]. ----8<-----
However executing this in Mondrian Easel you will notice that (taking
for example the third group) hovering over small squares 1 & 2 does
not highlight these and hovering over small square 3 highlights the
large square rather than its small square.
I get my expected/required behaviour by modifying
MOAnnouncer>>registerForEvent: forNodes: updateShape: updateLayout:
to replace...
domainNodes := (aBlockOrSymbol moValue: ann element model).
nodes := ann viewRenderer nodeForDomainValues: domainNodes.
by...
nodes := OrderedCollection new add: ann element ; yourself.
...but I don't know what else that breaks or another way to get my
required behaviour. How should I proceed?
cheers, -ben
An architectural question regarding the five methods starting
MOAnnouncer>>registerForEvent...
what is the difference in purpose between these with following in their
method name...
updateNode
updateShape
updateGraphNode
cheers, -ben