Example #1
0
 /// <summary>
 /// Gets the persistence data as int array
 /// </summary>
 /// <returns>The persistence.</returns>
 public void SavePersistence(DockItem item) // TODO early prototype - abolish, implement IPersistable instead!
 {
     mPersistence = new VirtualListPersistenceList();
     ColumnControl.Column[] columns = mColumnControl.GetColumns();
     foreach (ColumnControl.Column c in columns)
     {
         VirtualListPersistence p = new VirtualListPersistence();
         p.Visible = c.Visible;
         p.Width   = c.Width;
         p.Tag     = c.Tag;
         mPersistence.Persistence.Add(p);
     }
     ComponentManager.SaveObject("VirtualListView", mPersistence, this.DockItem);
 }
Example #2
0
 /// <summary>
 /// Sets the persistence previously got with GetPersistence
 /// </summary>
 /// <param name="data">Data.</param>
 public void LoadPersistence(DockItem item)
 {
     mPersistence = (VirtualListPersistenceList)ComponentManager.LoadObject("VirtualListView", typeof(VirtualListPersistenceList), item);
 }