public void TypeSmart(FiveDigitInt digits)
    {
        string number = digits.ToString();

        if (Comp.Numpad.IsEnabled())
        {
            if (Comp.Numpad.input_field.length >= number.Length)
            {
                for (int i = 0; i < (Comp.Numpad.input_field.length - number.Length); i++)
                {
                    number = '0' + number;
                }

                StartCoroutine(Type(number));
            }
            else
            {
                Debug.LogError("Слишком большое число - " + number + "\nМаксимальная длинна - " + Comp.Numpad.input_field.length + "цифр");
            }
        }
        else
        {
            Debug.LogError("Не включен Numpad");
        }
    }
    public void Type(FiveDigitInt digits)
    {
        string number = digits.ToString();

        if (Comp.Numpad.IsEnabled())
        {
            StartCoroutine(Type(number));
        }
        else
        {
            Debug.LogError("Не включен Numpad");
        }
    }
Beispiel #3
0
 private CalculatorItem(CalculatorItem obj_1, CalculatorItem obj_2)
 {
     this.number    = Merge(obj_1, obj_2);
     this.operation = obj_1.operation;
 }
Beispiel #4
0
 public CalculatorItem(string number, char operation)
 {
     this.number    = new FiveDigitInt(number);
     this.operation = Calculator.Operation(operation);
 }
Beispiel #5
0
 public CalculatorItem(FiveDigitInt number, Calculator.operations operation)
 {
     this.number    = number;
     this.operation = operation;
 }
Beispiel #6
0
 public CalculatorItem()
 {
     this.number    = new FiveDigitInt();
     this.operation = Calculator.operations.Plus;
 }