on idle is getting defined as a function rather than..idling?
Quite simply, when using on idle, it gets defined as a function. I have no idea why this is, but comparing my syntax to that of examples proves no error on my part, and using Apple provided scripts using on idle still yield it being defined as a function. Sensitive portions of this are removed, but yes.
No. You're declaring a handler for "idle" events with the "on" keyword just like "on run" or "on quit". If none are received that handler will never be called.