public void Equals_button_click(View v)
        {
            if (ChristmasClicked)
            {
                return;
            }
            string BigNum = Calc.EqualsPress();

            BigNum = BigNum == "" ? "0" : BigNum;
            CurrentNumberText.Text = BigNum;
            FullEquationText.Text  = "";
            hsvBig.ScrollBy(int.MinValue, 0);
            hsvTotal.ScrollBy(int.MinValue, 0);
        }
Пример #2
0
        private void DigitPressed(object sender, EventArgs e)
        {
            Button digit = (Button)sender;

            _twOut.Text += digit.Text;
            if (_twOut.Text.Length > 10)
            {
                _scrollView.ScrollBy((int)_twOut.TextSize - 10, 0);
            }
        }
Пример #3
0
        public bool OnTouch(View v, MotionEvent evt)
        {
            if (v == hScroller)
            {
                return(false);
            }
            else
            {
                curX = evt.GetX();
                curY = evt.GetY();
                int dx = (int)(mx - curX);
                int dy = (int)(my - curY);
                switch (evt.Action)
                {
                case MotionEventActions.Move:
                    if (started)
                    {
                        vScroller.ScrollBy(0, dy);
                        hScroller.ScrollBy(dx, 0);
                    }
                    else
                    {
                        started = true;
                    }
                    mx = curX;
                    my = curY;
                    break;

                case MotionEventActions.Up:
                    vScroller.ScrollBy(0, dy);
                    hScroller.ScrollBy(dx, 0);
                    started = false;
                    break;
                }
                return(true);
            }
        }