>>>>> "Chris" == Chris Coat <[email protected]> writes:

 Chris> Thanks, it's what I was looking for.  Any idea how i can get the
 Chris> observer object ? Tries "frame.world.observer();" but got a null
 Chris> pointer exception

Are you sure that's precisely what you tried?  I don't think that would
even compile; AppFrame doesn't have a field or method called `world`.

This should work:

  org.nlogo.app.App.app.workspace.world.observer

except that's Scala; in Java you'll need to sprinkle () here and there
depending on whether something is a field or method.  (In Scala it
doesn't matter.)

(Also note that in extension code, it's better to get to the workspace
object by going through your ExtensionContext, rather than resorting to
accessing the App.app global.)

--
Seth Tisue | Northwestern University | http://tisue.net
developer, NetLogo: http://ccl.northwestern.edu/netlogo/

-- 
You received this message because you are subscribed to the Google Groups 
"netlogo-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to