void ReleaseDesignerOutlets()
        {
            if (AttackButton != null)
            {
                AttackButton.Dispose();
                AttackButton = null;
            }

            if (BackgroundView != null)
            {
                BackgroundView.Dispose();
                BackgroundView = null;
            }

            if (CancelButton != null)
            {
                CancelButton.Dispose();
                CancelButton = null;
            }

            if (CountButton != null)
            {
                CountButton.Dispose();
                CountButton = null;
            }

            if (DamageButton != null)
            {
                DamageButton.Dispose();
                DamageButton = null;
            }

            if (HeaderLabel != null)
            {
                HeaderLabel.Dispose();
                HeaderLabel = null;
            }

            if (HeaderView != null)
            {
                HeaderView.Dispose();
                HeaderView = null;
            }

            if (OKButton != null)
            {
                OKButton.Dispose();
                OKButton = null;
            }

            if (PlusButton != null)
            {
                PlusButton.Dispose();
                PlusButton = null;
            }
        }
示例#2
0
 void ReleaseDesignerOutlets()
 {
     if (AttackButton != null)
     {
         AttackButton.Dispose();
         AttackButton = null;
     }
     if (EnemyDamageLabel != null)
     {
         EnemyDamageLabel.Dispose();
         EnemyDamageLabel = null;
     }
     if (EnemyHealthLabel != null)
     {
         EnemyHealthLabel.Dispose();
         EnemyHealthLabel = null;
     }
     if (RemainingRoundsLabel != null)
     {
         RemainingRoundsLabel.Dispose();
         RemainingRoundsLabel = null;
     }
     if (RemainingRunsLabel != null)
     {
         RemainingRunsLabel.Dispose();
         RemainingRunsLabel = null;
     }
     if (RunButton != null)
     {
         RunButton.Dispose();
         RunButton = null;
     }
     if (UserDamageLabel != null)
     {
         UserDamageLabel.Dispose();
         UserDamageLabel = null;
     }
     if (UserHealthLabel != null)
     {
         UserHealthLabel.Dispose();
         UserHealthLabel = null;
     }
 }