Package net.bnubot.bot.gui.icons

Examples of net.bnubot.bot.gui.icons.BNetIcon


      gridLayout.horizontalSpacing = 1;
      gridLayout.verticalSpacing = 1;
      grpIcons.setLayout(gridLayout);
      grpIcons.setBackground(background);
      for(int i = 0; i < icons.length; i++) {
        BNetIcon bni = icons[i];

        Label label = new Label(grpIcons, SWT.NULL);
        label.setImage(bni.getImage());
        label.pack();

        String text = "";
        if(bni.getProducts() != null)
          text += " " + HexDump.DWordToPretty(bni.getProducts()[0]);
        if(bni.getFlags() != 0)
          text += " 0x" + Integer.toHexString(bni.getFlags());

        label = new Label(grpIcons, SWT.NULL);
        label.setBackground(background);
        label.setForeground(foreground);
        label.setText(Integer.toString(i) + text);
View Full Code Here


    friends.clear();
    validate();
  }
 
  private void setIcon(FriendInfo fi) {
    BNetIcon icons[] = IconsDotBniReader.getIcons();
   
    if(fi.entry.getProduct() != 0) {
      for(int j = 0; j < icons.length; j++) {
        if(icons[j].useFor(0, fi.entry.getProduct())) {
          fi.label.setIcon(icons[j].getIcon());
View Full Code Here

    members.clear();
    validate();
  }
 
  private void setIcon(ClanMemberInfo cmi) {
    BNetIcon iconsWAR3[] = IconsDotBniReader.getIconsWAR3();
    BNetIcon iconsW3XP[] = IconsDotBniReader.getIconsW3XP();

    // 0 - Init - WAR3-W3D3 (2)
    // 1 - Peon - WAR3-W3O1 (10)
    // 2 - Grunt - WAR3-W302 (11)
    // 3 - Shaman - W3XP-W303 (20)
View Full Code Here

    validate();
  }

  private void setIcon(ClanMemberInfo cmi) {
    try {
      BNetIcon icons[] = IconsDotBniReader.getIconsClan();
      Icon icon = icons[cmi.entry.getRank()].getIcon();
      if(icon != null)
        cmi.label.setIcon(icon);
    } catch(Exception e) {
      Out.exception(e);
View Full Code Here

    friends.clear();
    validate();
  }

  private void setIcon(FriendInfo fi) {
    BNetIcon icons[] = IconsDotBniReader.getIcons();
    if(icons == null)
      return;

    if(fi.entry.getProduct() != 0) {
      for(BNetIcon element : icons) {
View Full Code Here

      ui.ping.setForeground(fg);
    }*/

    BNetIcon[] icons = IconsDotBniReader.getIcons();
    if(icons != null) {
      BNetIcon icon = icons[4]; // Glasses

      /* A = superuser, can perform any administrative action
       * B = broadcast, may use talk-to-all
       * C = connection, may administer botnet connectivity
       * D = database, may create and maintain databases
       * I = ID control, may create and modify hub IDs
       * S = botnet service
       */
      String flags = user.getZTFF();
      if(flags.contains("B"))
        icon = icons[3]; // Speaker
      if(flags.contains("S"))
        icon = icons[1]; // B.net
      if(flags.contains("C"))
        icon = icons[2]; // Oper
      if(flags.contains("A"))
        icon = icons[0]; // Blizzard

      if(icon != null)
        ui.label.setIcon(icon.getIcon());
    }

    users.put(user.getNumber(), ui);
    validate();
  }
View Full Code Here

TOP

Related Classes of net.bnubot.bot.gui.icons.BNetIcon

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.