Hi Frederico, Do you want to verify that a particular instance of GTPlayground is opened or if there is just any GTPlayground opened in the current image? For the first case a playground knows it's window. So you can check if there is a window and the window is in the world: aPlayground window ifNotNil: [ :aWindow | aWindow isInWorld ] ifNil: [ false ] For the second case something like the following script should work: (World submorphs select: [ :aMorph | aMorph isSystemWindow ]) detect: [ :aWindow | aWindow model class = GTPlayground ] ifFound: [ true ] ifNone: [ false ] Cheers, Andrei On Tue, Aug 30, 2016 at 8:51 PM, Federico.Balaguer < federico.balaguer@gmail.com> wrote:
Hello,
BotArena is a tool for teaching objects that we are using in my University. The tool allow students to enter Smalltalk expressions using an instance of GTPlayground.
There is a "reset" scenario where BotArena needs to know if there is a Playground open so it does refresh bindings to given objects.
So how can someone check whether a Playground is open or closed?
Thanks! Federico
-- View this message in context: http://forum.world.st/ GTPlayground-status-open-or-close-tp4913257.html Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.