/* */ package NET.worlds.console; /* */ /* */ import java.awt.Dimension; /* */ import java.awt.Event; /* */ import java.awt.Frame; /* */ import java.awt.GridBagConstraints; /* */ import java.awt.GridBagLayout; /* */ import java.awt.List; /* */ import java.awt.Point; /* */ import java.awt.Window; /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ /* */ public class StatisticsWindow /* */ extends Frame /* */ implements MainCallback, MainTerminalCallback, TreeCallback /* */ { /* */ private static final long serialVersionUID = 2184104724858956037L; /* 36 */ Tree _tree = new Tree(this); /* 37 */ List _list = new List(10, false); /* */ StatMan _lastStat; /* */ /* */ public StatisticsWindow(Window parent) { /* 41 */ super("Statistics Manager"); /* */ /* 43 */ GridBagLayout gbag = new GridBagLayout(); /* 44 */ setLayout(gbag); /* 45 */ GridBagConstraints c = new GridBagConstraints(); /* 46 */ c.fill = 1; /* 47 */ c.weightx = 0.4D; /* 48 */ c.weighty = 1.0D; /* 49 */ c.gridwidth = 1; /* 50 */ c.gridheight = 0; /* 51 */ gbag.setConstraints(this._tree, c); /* 52 */ add(this._tree); /* 53 */ c.weightx = 0.6D; /* 54 */ c.gridwidth = 0; /* 55 */ gbag.setConstraints(this._list, c); /* 56 */ add(this._list); /* */ /* */ /* 59 */ pack(); /* 60 */ Point loc = parent.getLocation(); /* 61 */ Dimension size = parent.getSize(); /* 62 */ setBounds(loc.x + (size.width - 512) / 2, /* 63 */ loc.y + (size.height - 240) / 2, 512, 240); /* */ /* 65 */ setVisible(true); /* 66 */ StatisticsRoot root = StatisticsRoot.getNode(); /* 67 */ root.setTree(this._tree); /* 68 */ StatTreeNode rootNode = new StatTreeNode(root, null); /* 69 */ this._tree.change(rootNode, rootNode.getObject()); /* */ /* */ /* 72 */ StatMemNode.getNode(); /* 73 */ StatNetRefNode.getNode(); /* */ /* */ /* */ /* 77 */ this._tree.change(rootNode, StatRateNode.getNode()); /* */ /* 79 */ Main.register(this); /* */ } /* */ /* */ @Deprecated /* */ public boolean handleEvent(Event ev) /* */ { /* 85 */ switch (ev.id) { /* */ case 201: /* 87 */ if (this._lastStat != null) /* 88 */ this._lastStat.releaseList(false); /* 89 */ this._lastStat = null; /* 90 */ dispose(); /* 91 */ return true; /* */ } /* 93 */ return super.handleEvent(ev); /* */ } /* */ /* */ /* */ public void treeChange(Object obj) /* */ { /* 99 */ if (this._lastStat != null) /* 100 */ this._lastStat.releaseList(false); /* 101 */ this._lastStat = ((StatMan)obj); /* 102 */ this._lastStat.grabList(this._list); /* */ } /* */ /* */ /* */ /* */ public void treeFocusChanged(boolean hasFocus) {} /* */ /* */ /* */ public void mainCallback() {} /* */ /* */ /* */ public void terminalCallback() /* */ { /* 115 */ if (this._lastStat != null) /* 116 */ this._lastStat.releaseList(true); /* 117 */ this._lastStat = null; /* 118 */ Main.unregister(this); /* */ } /* */ } /* Location: C:\Program Files (x86)\Worlds Inc\WorldsPlayer - Win7\lib\worlds.jar!\NET\worlds\console\StatisticsWindow.class * Java compiler version: 6 (50.0) * JD-Core Version: 0.7.1 */