Example #1
0
 /// <summary>
 /// Create a deep clone of this card
 /// </summary>
 /// <returns>Card that is a deep clone of this one</returns>
 public Card Clone()
 {
     Card card = new Card();
     card.BackImage = new BackgroundImage();
     card.CopyCardProperties(this);
     card.BackImage = new BackgroundImage();
     card.BackImage.CopyImageProperties(card, BackImage);
     foreach(SecondaryImage si in SecondaryImages)
     {
         SecondaryImage si2 = new SecondaryImage();
         si2.CopyImageProperties(card, si);
         card.SecondaryImages.Add(si2);
     }
     foreach(TextItem ti in TextItems)
     {
         TextItem ti2 = new TextItem();
         ti2.CopyTextItem(card, ti);
         card.TextItems.Add(ti2);
     }
     if(QsosBox != null)
     {
         card.QsosBox = new QsosBox();
         card.QsosBox.CopyQsosBoxProperties(card, QsosBox);
     }
     return card;
 }