Is it possible to attach AnActionListener for a specific AnAction?

Lets say, my plugin defined  AnAction ProjectRefresh and I would like to attach AnActionListener (which does some post processing as part of afterActionPerformed) which listens only to this event. Is there a way to do this?
Is there any performance hit if my AnActionListener listens to all events triggered and acts only when action is same as ProjectRefresh. I saw, most of the AnActionListeners are related to editor and thought AnActionListener seems to ideal for editor related events.

1 comment
Comment actions Permalink

Hello chandra,

Lets say, my plugin defined  AnAction ProjectRefresh and I would like
to attach AnActionListener (which does some post processing as part of
afterActionPerformed) which listens only to this event. Is there a way
to do this?


No.

Is there any performance hit if my AnActionListener listens to all
events triggered and acts only when action is same as ProjectRefresh.
I saw, most of the AnActionListeners are related to editor and thought
AnActionListener seems to ideal for editor related events.


I don't think this could be a performance problem.

--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"


0

Please sign in to leave a comment.