Exemple #1
0
 partial void EditingDidEnd(UITextField sender)
 {
     if (SymbolChecker.CheckInput(Symbol.Text, InputText.Text))
     {
         Symbol.Text        = SymbolChecker.NewSymbol();
         InputText.Text     = "";
         StatusImage.Hidden = true;
         Score.Text         = (int.Parse(Score.Text) + 1).ToString();
         if (int.Parse(Score.Text) > int.Parse(BestScore.Text))
         {
             BestScore.Text = Score.Text;
         }
     }
     else
     {
         if (InputText.Text.Length >= SymbolChecker.NeededLength(Symbol.Text))
         {
             StatusImage.Hidden = false;
             Score.Text         = 0.ToString();
         }
         else
         {
             StatusImage.Hidden = true;
         }
     }
 }
Exemple #2
0
 public override void ViewDidLoad()
 {
     base.ViewDidLoad();
     // Perform any additional setup after loading the view, typically from a nib.
     //SymbolChecker.UseNumbers();
     Symbol.Text        = SymbolChecker.NewSymbol();
     InputText.Text     = "";
     StatusImage.Hidden = true;
 }