APS Excellence in Physics Education Award
November 2019

Education Prize Logo
Science SPORE Prize
November 2011

NSF Logo
The Open Source Physics Project is supported by NSF DUE-0442581.

Question about dragable and interactive Objects

Return to the EJS Modeling forum
Login to post to this thread

Interactive 2D shapes question
Eduardo Garcia
13 Posts

Hello again:

I am trying to do some interactive 2D shapes, like buttons that change color for example, in EJS.

I am having a problem with making them "clickable". If I choose the 2DShape to not be dragable, the object I make cannot be made clickable, so I can't execute functions when the user clicks on it.

The only way I have found to make them clickable is to make them dragable in either direction. If I choose "Dragable: ENABLED_NONE" they become not clickable.

Is there a way to make them clickable but not dragable?

Thank you for your time and patience.

Current Replies - View all
Re: Interactive 2D shapes...   (Francisco Esquembre - )
Re: Re: Interactive 2D sh...   (Eduardo Garcia - )
Re: Interactive 2D shapes...   (Geraggelos Thanasis - )
Re: Re: Interactive 2D sh...   (Francisco Esquembre - )
OSP Projects:
Open Source Physics - EJS Modeling
Physlet Physics
Physlet Quantum Physics
STP Book