public EndForm(MainForm mainForm, CardInfoForm infoForm) { _mainForm = mainForm; _infoForm = infoForm; InitializeComponent(); _endForm = this; }
private void CardInformation(Card card) { // If it's the same card, but a different picture box do nothing if (CardInfoForm._card?.card_images[0].image_url == card.card_images[0].image_url) { return; } // If there's already a form showing a card info, close it _cardInfoForm?.Close(); _cardInfoForm = new CardInfoForm(card); _cardInfoForm.Show(); _cardInfoForm.StartPosition = FormStartPosition.Manual; _cardInfoForm.SetDesktopLocation(MainFormRef.Right - 10, MainFormRef.Location.Y); }