コード例 #1
0
        public Entry GetEntryAt(long row)
        {
            Entry e = new Entry();

            if (m_RowData[row].isGroupHead())
            {
                e.table      = this;
                e.groupIndex = m_RowData[row].groupIndex;
                e.row        = row;
                return(e);
            }
            var           groupIndex = m_RowData[row].groupIndex;
            ExpandedGroup eg;

            if (m_ExpandedGroup.TryGetValue(groupIndex, out eg))
            {
                if (eg.table is ExpandTable)
                {
                    ExpandTable egSub = (ExpandTable)eg.table;
                    return(egSub.GetEntryAt(m_RowData[row].subGroupIndex));
                }
                else
                {
                    e.table      = eg.table;
                    e.groupIndex = m_RowData[row].subGroupIndex;
                    e.row        = m_RowData[row].subGroupIndex;
                    return(e);
                }
            }
            return(e);
        }
コード例 #2
0
 public override CellPosition Apply(Table t)
 {
     if (t is ExpandTable)
     {
         ExpandTable gt = (ExpandTable)t;
         gt.ExpandGroupByIndex(groupIndex, true);
         if (subLink != null)
         {
             ExpandedGroup eg;
             if (gt.m_ExpandedGroup.TryGetValue(groupIndex, out eg))
             {
                 var  subCellPos = subLink.Apply(eg.table);
                 long row        = gt.m_GroupRowDataRange[groupIndex].First + 1 + subCellPos.row; //+1 to skip the group head
                 return(new CellPosition(row, subCellPos.col));
             }
         }
     }
     return(CellPosition.invalid);
 }
コード例 #3
0
 public GroupUpdater(ExpandTable t)
 {
     m_Table = t;
 }
コード例 #4
0
 public void Initialize(ExpandTable table, Column column, int columnIndex)
 {
     m_Table       = table;
     m_Column      = (ColumnTyped <DataT>)column;
     m_ColumnIndex = columnIndex;
 }