active state

Apr 27, 2010 at 11:21am

active state

Is there a JavaScript method capable of querying the active state of a parent patcher? Say, I have a bpatcher and want to know whether its patcher window is frontmost, but don’t want to create an active object in the parent patcher.

#50030
Apr 30, 2010 at 8:51pm

No offense, but this sounds like poor encapsulation to me. Why not let the bpatcher support an active message and let users issue it from the parent patcher?

#179595
May 4, 2010 at 7:45pm

I had the Max for Idiots kind of person in mind. That’s why…

Actually, there was a time when there was no JavaScript at all, and my patches were all running just fine…

Georg

#179596
May 7, 2010 at 1:44am

Try checking the current filepath against the frontmost filepath as shown below.

lh

max.frontpatcher.filepath == this.patcher.filepath

#179597

You must be logged in to reply to this topic.