예제 #1
0
  /**
   * Set the group ID.
   *
   * <p>Group ID values must be in the range: [1-9]
   *
   * @param groupID The new group ID or (0) for no group assignment.
   */
  @Override
  public void setGroupID(int groupID) {
    UIMaster master = UIMaster.getInstance();

    PanelGroup<JNodeFilesPanel> panels = master.getNodeFilesPanels();

    if (pGroupID > 0) panels.releaseGroup(pGroupID);

    pGroupID = 0;
    if ((groupID > 0) && panels.isGroupUnused(groupID)) {
      panels.assignGroup(this, groupID);
      pGroupID = groupID;
    }

    master.updateOpsBar();
  }
예제 #2
0
 /** Is the given group currently unused for this type of panel. */
 @Override
 public boolean isGroupUnused(int groupID) {
   PanelGroup<JNodeFilesPanel> panels = UIMaster.getInstance().getNodeFilesPanels();
   return panels.isGroupUnused(groupID);
 }