@Documented @Retention(value=RUNTIME) @Target(value=TYPE) public @interface ProxyActions
The proxy actions perform their action not on the component they're bound to (menu items and toolbar buttons), but on the component that currently has the keyboard focus. Their enabled state tracks the selection value of the component with the keyboard focus, as well as the contents of the system clipboard. The proxy actions work in conjunction with the action map associated with the component that has focus.
So you can create an action in any object (whether it is a component or not), and use that action anywhere. But as the focus changes, that one action binds itself to the same named action in the component tree that the focused control has.
For example, in the case of Copy, the proxy action can be created anywhere in the application and attached to menus, buttons, or whatever you want. When the focus is on a control that has an ActionMap that contains a 'copy' entry, the proxy action will bind to that action and the menu/button/whatever will invoke the action of the component with focus.
public abstract String[] value
Copyright © 2009–2014. All rights reserved.