MCPcopy Index your code
hub / github.com/BombusMod/BombusMod / ActiveContacts

Method ActiveContacts

src/main/java/Client/ActiveContacts.java:48–67  ·  view source on GitHub ↗

Creates a new instance of ActiveContacts @param current

(Contact current)

Source from the content-addressed store, hash-verified

46 * @param current
47 */
48 public ActiveContacts(Contact current) {
49 super(SR.MS_ACTIVE_CONTACTS, false);
50
51 enableListWrapping(true);
52 for (Enumeration r = sd.roster.hContacts.elements(); r.hasMoreElements();) {
53 Contact c = (Contact) r.nextElement();
54 if (c.active() || c.origin == Contact.ORIGIN_GROUPCHAT) {
55 itemsList.addElement(c);
56 }
57 }
58
59 if (getItemCount() == 0) {
60 return;
61 }
62
63 mainbar = new MainBar(2, String.valueOf(getItemCount()), " ", false);
64 mainbar.addElement(SR.MS_ACTIVE_CONTACTS);
65 show();
66 focusToContact(sd.roster.activeContact);
67 }
68
69 public void eventOk() {
70 if (getItemCount() > 0) {

Callers

nothing calls this directly

Calls 7

activeMethod · 0.95
focusToContactMethod · 0.95
enableListWrappingMethod · 0.80
elementsMethod · 0.80
addElementMethod · 0.80
getItemCountMethod · 0.45
showMethod · 0.45

Tested by

no test coverage detected