Пример #1
0
  private void addButtonActionPerformed(ActionEvent e) {
    AddHUDPanel addHUDPanel =
        new AddHUDPanel(client, session, myPresenceInfo, myPresenceInfo, group, Mode.ADD);

    addHUDPanel.setPrivacy(addUserPanel.getPrivacy());

    HUD mainHUD = HUDManagerFactory.getHUDManager().getHUD("main");
    addModeAddHUDComponent = mainHUD.createComponent(addHUDPanel);
    addHUDPanel.setHUDComponent(addModeAddHUDComponent);

    addModeAddHUDComponent.setName("Add to Voice Chat");

    addHUDPanel.setPreferredLocation(Layout.EAST);

    mainHUD.addComponent(addModeAddHUDComponent);

    inProgressButtonPanel.setEnabledAddButton(false);

    addModeAddHUDComponent.addEventListener(
        new HUDEventListener() {

          public void HUDObjectChanged(HUDEvent e) {
            if (e.getEventType().equals(HUDEventType.DISAPPEARED)) {
              inProgressButtonPanel.setEnabledAddButton(true);
            }
          }
        });

    PropertyChangeListener plistener =
        new PropertyChangeListener() {

          public void propertyChange(PropertyChangeEvent pe) {
            String name = pe.getPropertyName();
            if (name.equals("ok") || name.equals("cancel")) {
              addModeAddHUDComponent.setVisible(false);
            }
          }
        };

    addHUDPanel.addPropertyChangeListener(plistener);
    addModeAddHUDComponent.setVisible(true);
  }
Пример #2
0
 public void setTitleOfViewWindow(String title) {
   if (userListHUDComponent != null) {
     userListHUDComponent.setName(title);
   }
 }