public override bool Equals(object obj) { if (obj == null || GetType() != obj.GetType()) return false; Resolution resItem = (Resolution)obj; return resItem.Width == Width && resItem.Height == Height; }