コード例 #1
0
  void release() {
    if (childRowToIdMap != null) {
      Collection delegates = childRowToIdMap.values();
      Iterator iter = delegates.iterator();
      while (iter.hasNext()) {
        SWTAccessibleDelegate childDelegate = ((Accessible) iter.next()).delegate;
        if (childDelegate != null) {
          childDelegate.internal_dispose_SWTAccessibleDelegate();
          childDelegate.release();
        }
      }

      childRowToIdMap.clear();
      childRowToIdMap = null;
    }

    if (childColumnToIdMap != null) {
      Collection delegates = childColumnToIdMap.values();
      Iterator iter = delegates.iterator();
      while (iter.hasNext()) {
        SWTAccessibleDelegate childDelegate = ((Accessible) iter.next()).delegate;
        if (childDelegate != null) {
          childDelegate.internal_dispose_SWTAccessibleDelegate();
          childDelegate.release();
        }
      }

      childColumnToIdMap.clear();
      childColumnToIdMap = null;
    }
  }
コード例 #2
0
  Accessible childRowToOs(int childID) {
    if (childID == ACC.CHILDID_SELF) {
      return tableAccessible;
    }

    /* Check cache for childID, if found, return corresponding osChildID. */
    AccessibleTableRow childRef =
        (AccessibleTableRow) childRowToIdMap.get(Integer.valueOf(childID));

    if (childRef == null) {
      childRef = new AccessibleTableRow(tableAccessible, childID);
      childRowToIdMap.put(Integer.valueOf(childID), childRef);
    }

    return childRef;
  }