01: package tijmp.actions;
02:
03: import java.awt.event.ActionEvent;
04: import javax.swing.AbstractAction;
05: import tijmp.ProfilerHandler;
06: import tijmp.ui.Translator;
07:
08: /** A class to show owners for all objects of a given class.
09: */
10: public class ShowOwners extends AbstractAction {
11: private ProfilerHandler ph;
12: private Class<?> clz;
13:
14: public ShowOwners(ProfilerHandler ph, Class<?> clz) {
15: super ("Show owners for all " + Translator.translate(clz));
16: this .ph = ph;
17: this .clz = clz;
18: }
19:
20: public void actionPerformed(ActionEvent e) {
21: ph.submitTask(new Runnable() {
22: public void run() {
23: ph.showOwners(clz);
24: }
25: });
26: }
27: }
|