Ejemplo n.º 1
0
        public SymbolBarcodeScanner(TERM_TYPE nT, ConfigData cfgD, string OEM)
        {
            base.nTermType = nT;
            m_OEM          = OEM;

            switch (cfgD.KEYBOARD)
            {
            case ((int)KeyboardTypes.MC3000_28KEY_FP):
            case ((int)KeyboardTypes.MC3000_28KEY):
                base.nKeys              = 28;
                xSymKeyPad              = new KeyPad();
                xSymKeyPad.AlphaNotify += new KeyPad.KeyboardEventHandler(ALPNotify);
                break;

            case ((int)KeyboardTypes.MC3000_48KEY):
                // спецрежим актуален только для 48 клавиш
                base.nKeys                 = 48;
                xSymKeyPad                 = new KeyPad();
                xSymKeyPad.AlphaNotify    += new KeyPad.KeyboardEventHandler(ALPNotify);
                xSymKeyPad.KeyStateNotify += new KeyPad.KeyboardEventHandler(Sym48_KeyStateNotify);
                break;

            default:
                break;
            }
        }
Ejemplo n.º 2
0
        public MainPage()
        {
            this.InitializeComponent();
            webCam = WebCam.Create();
            webCam.StartLiveStreamAsync(liveStreamElement);  // display camera's live stream in UI

            keypad          = new KeyPad();
            keypad.OnPress += UpdateApartmentTextBoxAsync;  // UI
            keypad.OnRing  += HandleVisitorAsync;
            keypad.OnReset += ResetApartmentTextBoxAsync;   // UI

            doorLock = DoorLock.Create();

            httpClient   = new HttpClient();
            baseUri      = "https://intellidoorfunctionapp.azurewebsites.net/api/open?code=pZcJ7JYaB/mUL873qU4ge8AFTPhZvr0ZJ2vTrIrXQdTI3WOD7zBQ5A==";
            httpResponse = new HttpResponseMessage();

            // wait for a visitor to enter an apartment number
            Task a = Task.Run(() => {
                while (true)
                {
                    resetEvent.Reset();
                    keypad.GetAparmentNumber();
                    resetEvent.WaitOne();
                }
            }
                              );
        }
Ejemplo n.º 3
0
        public QuizContent(KeyPad keyPad)
        {
            //Delegate[] clientList = QuizManager.GuessWasCorrect.GetInvocationList();
            //if (QuizManager.GuessWasCorrect != null)
            //    foreach (var d in QuizManager.GuessWasCorrect.GetInvocationList())
            //        QuizManager.GuessWasCorrect -= (d as this.GuessWasCorrect);
            InitializeComponent();
            keyPad.VerticalOptions = LayoutOptions.FillAndExpand;
            keyPad.ButtonPressed  += GetPressedButtonText;
            ContainerForKeyPad.Children.Add(keyPad);
            QuizGameManager.GuessWasCorrect   += GuessWasCorrect;
            QuizGameManager.GameIsOver        += GameOver;
            QuizGameManager.SecondPassed      += GameSecondPassed;
            QuizGameManager.isCountingGameTime = false;

            if (!QuizGameManager.SubscribedTimer)
            {
                QuizGameManager.aTimer.Elapsed += QuizGameManager.TimerSecondIsPassed;
                QuizGameManager.SubscribedTimer = true;
            }

            QuizGameManager.aTimer.AutoReset = true;
            QuizGameManager.aTimer.Enabled   = true;
            QuizGameManager.TotalTimeLeft    = new TimeSpan();
            QuizGameManager.RoundTimeLeft    = new TimeSpan(0, 0, 10);
        }
 //入口
 public void Goin(Action nextStep_)
 {
     nextStep = nextStep_;
     tb.Text  = "";
     KeyPad.startInput(input, Delete, clear, OK, Back_, this);
     CD.business1.setBusinessValue(this);
 }
Ejemplo n.º 5
0
        public MainPage()
        {
            this.InitializeComponent();

            webCam = WebCam.Create();
            webCam.StartLiveStreamAsync(liveStreamElement);  // display camera's live stream in UI
            imgurClient = new ImgurApi();

            keypad = new KeyPad();
            Debug.WriteLine("keypad created");
            keypad.OnPress += UpdateApartmentTextBoxAsync;  // UI
            keypad.OnRing  += HandleVisitorAsync;
            keypad.OnReset += ResetApartmentTextBoxAsync;   // UI

            doorLock = DoorLock.Create();

            httpClient   = new HttpClient();
            baseUri      = "https://prod-07.northeurope.logic.azure.com:443/workflows/b6551691604a461db4a0c06801cf0df3/triggers/manual/paths/invoke?api-version=2016-10-01&sp=%2Ftriggers%2Fmanual%2Frun&sv=1.0&sig=xcu2NJIVZXpy-AxTEP3tkk-Gei_P08uoyOP-hpr7RNc";
            httpResponse = new HttpResponseMessage();

            deviceClient = DeviceClient.Create(iotHubUri, new DeviceAuthenticationWithRegistrySymmetricKey(deviceId, deviceKey), TransportType.Mqtt);

            // wait for a visitor to enter an apartment number
            Task a = Task.Run(() => {
                while (true)
                {
                    resetEvent.Reset();
                    keypad.GetAparmentNumber();
                    resetEvent.WaitOne();
                }
            }
                              );
        }
Ejemplo n.º 6
0
 public CodesContent(KeyPad keyPad)
 {
     InitializeComponent();
     keyPad.VerticalOptions = LayoutOptions.FillAndExpand;
     keyPad.ButtonPressed  += GetPressedButtonText;
     ContainerForKeyPad.Children.Add(keyPad);
 }
Ejemplo n.º 7
0
 public KeyPadUI(KeyPad keypad, Serial serial)
 {
     this.keypad = keypad;
     this.serial = serial;
     InitializeComponent();
     this.DataContext = keypad;
 }
Ejemplo n.º 8
0
        public static void getDeviceInfor(CANPacket e, GlobalData globalData)
        {
            string UUID = null;
            int    short_address;

            int packet_idx = 0;

            CANPacket.Device_Types_t deviceType = (CANPacket.Device_Types_t)e.Buffer[packet_idx++];
            int dev_catogory = e.Buffer[packet_idx++];

            for (int i = 0; i < 16; i++)
            {
                UUID += e.Buffer[packet_idx++].ToString("X2");
            }
            short_address = e.Buffer[packet_idx++];


            if (deviceType == CANPacket.Device_Types_t.Device_Type_Keypad)
            {
                KeyPad keypad = new KeyPad();
                keypad.uuid         = UUID;
                keypad.shortAddress = short_address;
                keypad.numOfKeys    = e.Buffer[packet_idx++];
                keypad.type         = (KEYPAD_TYPE)dev_catogory;
                int index = globalData.deviceInfo.keyPads.FindIndex(x => x.uuid == UUID);
                if (index == -1)
                {
                    globalData.deviceInfo.keyPads.Add(keypad);
                }
                else
                {
                    globalData.deviceInfo.keyPads[index] = keypad;
                }
                Console.WriteLine("key pad found");
            }
            else if (deviceType == CANPacket.Device_Types_t.Device_Type_Mainboard)
            {
                ECU ecu = new ECU();
                ecu.uuid                    = UUID;
                ecu.shortAddress            = short_address;
                ecu.numberOFPOsitiveOutputs = e.Buffer[packet_idx++];
                ecu.numberOFNEgativeOutputs = e.Buffer[packet_idx++];
                ecu.numberOFAnalogInput     = e.Buffer[packet_idx++];
                ecu.numberOFExternalOutputs = e.Buffer[packet_idx++];
                ecu.type                    = (ECU_TYPE)dev_catogory;
                int index = globalData.deviceInfo.ecus.FindIndex(x => x.uuid == UUID);
                if (index == -1)
                {
                    globalData.deviceInfo.ecus.Add(ecu);
                }
                else
                {
                    globalData.deviceInfo.ecus[index] = ecu;
                }
                Console.WriteLine("mainboard found");
            }

            Console.Write("done");
        }
Ejemplo n.º 9
0
 private void p2_GotFocus(object sender, RoutedEventArgs e)
 {
     show();
     tip2.Visibility     = Visibility.Visible;
     keyboard.Visibility = Visibility.Collapsed;
     input.Content       = "输入";
     KeyPad.startInput(KeyPad.normal_Input, KeyPad.normal_Delete, null, null, null, this);
 }
Ejemplo n.º 10
0
        private void keypadList_MouseUp(object sender, MouseButtonEventArgs e)
        {
            var    item    = sender as ListViewItem;
            string text    = item.Content.ToString();
            KeyPad current = keybadList.Find(o => o.uuid == text);

            drawKeypad(current);
        }
Ejemplo n.º 11
0
 private void Window_KeyDown(object sender, KeyEventArgs e)
 {
     KeyPad.Hit(e);
     if (!e.Handled)
     {
         Verbiage.Hit(e);
     }
     Focus();
 }
Ejemplo n.º 12
0
        public string ExampleLinePartII(string startingButton, string instructionLine)
        {
            var pad = new KeyPad();

            pad.InitDesignKeyPad();
            pad.SetStartingButton(startingButton);

            pad.ProcessSequence(instructionLine);
            return(pad.Sequence);
        }
Ejemplo n.º 13
0
 //入口
 public void Goin(NextStepPar1 nextStepPar1, int inputStyle, string title)
 {
     newPsw            = "";
     this.title.Text   = title;
     inputTime         = 0;
     this.inputStyle   = inputStyle;
     this.nextStepPar1 = nextStepPar1;
     reset();
     KeyPad.startInput(input, Delete, clear, OK, Back_, this);
 }
Ejemplo n.º 14
0
 public void show()
 {
     KeyPad.startInput(KeyPad.normal_Input, KeyPad.normal_Delete, clear, ok_, null, this);
     BackExit.LetNextClickToMain();
     p1.Password = "";
     p2.Password = "";
     p3.Password = "";
     p1.Focus();
     Business2.Init("社保密码修改");
     CD.business2.setBusinessValue(this);
 }
Ejemplo n.º 15
0
        public string GetAnswerB(bool animate = false)
        {
            var keypad = new KeyPad('5', false);

            foreach (var move in File.ReadAllLines("Day2_input.txt"))
            {
                keypad.Move(move);
            }

            return(keypad.KeysPressed);
        }
Ejemplo n.º 16
0
 public static void Goin(Action nextStep_)
 {
     nextStep = nextStep_;
     if (cp == null)
     {
         cp = new CheckPassword2();
     }
     CD.business1.setBusinessValue(cp);
     cp.canBeChange = true;
     KeyPad.startInput(cp.input, cp.delete, null, null, null, cp);
 }
Ejemplo n.º 17
0
        private void DumpResults(KeyPad results)
        {
            for (Int32 outer = 0; outer < results.GetRowCount(); outer++)
            {
                Debug.Write($"{outer}: ");

                for (Int32 inner = 0; inner < results.GetColumnCount(outer); inner++)
                {
                    Debug.Write($"{results[outer, inner].LowerKey} ");
                }

                Debug.WriteLine(String.Empty);
            }
        }
Ejemplo n.º 18
0
        public char FindKey(string input)
        {
            foreach (var item in input)
            {
                _endingKey = FindRelativeKeyDiamond(GetInputKeyDirection(item.ToString()));
            }

            var combinationValue = GetKeyPadValue(_endingKey);

            _combination.Add(combinationValue);
            Combination = _combination.ToArray();

            return(combinationValue);
        }
Ejemplo n.º 19
0
        public KeyPad Build(IEnumerable <KeyMap> source)
        {
            if (source == null)
            {
                throw new ArgumentNullException(nameof(source));
            }

            List <KeyMap> keys = source.Where(x => !this.IsExcluded(x)).ToList();

            keys.Sort(KeyMap.CompareByScanCode);

            List <List <KeyMap> > matrix = new List <List <KeyMap> >
            {
                new List <KeyMap>(),
                new List <KeyMap>(),
                new List <KeyMap>(),
                new List <KeyMap>()
            };

            Int32 index = 0;

            foreach (KeyMap key in keys)
            {
                // As seen by examples, it seems to be that each keyboard
                // uses 'q' and 'a' and ('y' or 'z') as first key in their
                // related rows.

                if (key.LowerKey == 'q')
                {
                    index = 1;
                }
                else if (key.LowerKey == 'a')
                {
                    index = 2;
                }
                else if (index != 1 && (key.LowerKey == 'y' || key.LowerKey == 'z'))
                {
                    index = 3;
                }

                matrix[index].Add(key);
            }

            KeyPad results = KeyPad.Create(matrix);

            this.DumpResults(results);

            return(results);
        }
Ejemplo n.º 20
0
        private char GetKeyPadValue(KeyPad input)
        {
            switch (input)
            {
            case KeyPad.One:
                return('1');

            case KeyPad.Two:
                return('2');

            case KeyPad.Three:
                return('3');

            case KeyPad.Four:
                return('4');

            case KeyPad.Five:
                return('5');

            case KeyPad.Six:
                return('6');

            case KeyPad.Seven:
                return('7');

            case KeyPad.Eight:
                return('8');

            case KeyPad.Nine:
                return('9');

            case KeyPad.A:
                return('A');

            case KeyPad.B:
                return('B');

            case KeyPad.C:
                return('C');

            case KeyPad.D:
                return('D');

            default:
                return('0');
            }
        }
Ejemplo n.º 21
0
 public static void ProcessApplication()
 {
     try
     {
         try
         {
             ProcessCmd.InstallFont();                  //安装字体
             ProcessCmd.HideWindowDesk();               //隐藏桌面
             ProcessCmd.HideLogicalDriver();            //隐藏驱动器
             ProcessCmd.NoUsedTaskMgrForm();            //关闭任务管理器
             if (ProcessCmd.SetSystytemLoadShell())     //设置启动项目
             {
                 ProcessCmd.SetProcessAutoStart(false); //删除重启项目
             }
             else
             {
                 ProcessCmd.SetProcessAutoStart();//如果设置失败就设置自动启动
             }
         }
         finally
         {
             Process.GetCurrentProcess().PriorityClass = ProcessPriorityClass.RealTime;
             Application.ThreadException += Application_ThreadException;
             Application.ApplicationExit += Application_ApplicationExit;
             Application.EnableVisualStyles();
             Application.SetCompatibleTextRenderingDefault(false);
             keyPad1    = new UI.Ctr.KeyPad();
             keyMessage = new KeyMessageFilter();
             Application.AddMessageFilter(keyMessage);
             Common.LoadSysConfigFile();
             Application.Run(new MainForm());
             Application.RemoveMessageFilter(keyMessage);
             keyPad1.Close();
         }
     }
     catch (Exception ex)
     {
         MessageBox.Show(ex.ToString());
         Common.SystemExit(true, false);
     }
     finally
     {
     }
 }
Ejemplo n.º 22
0
        //todo: list item click fill

        private void drawKeypad(KeyPad keyapd)
        {
            Label uuid = new Label();

            uuid.Content = "UUID : " + keyapd.uuid;

            Label label = new Label();

            label.Content = "Custom label : " + keyapd.label;

            Label keypads = new Label();

            keypads.Content = "Number of Keypads : " + keyapd.keys.Count.ToString();

            detalPanel.Children.Clear();
            detalPanel.Children.Add(uuid);
            detalPanel.Children.Add(label);
            detalPanel.Children.Add(keypads);
        }
Ejemplo n.º 23
0
    void Start()
    {
        _okDialog.SetActive(false);
        _yesNoDialog.SetActive(false);
        _footItemCommandWindow.SetActive(false);
        _footTrapCommandWindow.SetActive(false);

        LayerManager.CreateAllLayer();

        _itemWindow.SetActive(false);
        _btnItem.onClick.AddListener(() => {
            if (_gameState != GameState.InputWait)
            {
                return;
            }

            ChangeGameState(GameState.DisplayItemWindow);
            _itemWindow.SetActive(true);

            var sc = GameObject.Find("Canvas/ScrollView/Panel/Content").GetComponent <ScrollController>();
            sc.Init(_player.Items);

            sc.SetCloseCallback(() => {
                ChangeGameState(GameState.InputWait);
            });
            sc.SetItemActionCallback((ItemActionType actionType, Item item) => {
                Debug.Log("callback = " + actionType);
                Debug.Log("item = " + item);

                ExecutePlayerItemAction(actionType, item);
            });
        });

        _btnFoot.onClick.AddListener(() => {
            if (_gameState != GameState.InputWait)
            {
                return;
            }

            Debug.Log("足下ボタンが押されました");

            // 足下アイテム
            var fieldItem = FindFieldItem(_player.Loc);
            if (fieldItem != null)
            {
                ChangeGameState(GameState.DisplayFootItemCommandWindow);
                var c = _footItemCommandWindow.GetComponent <FootItemCommandWindow>();
                c.Init(fieldItem, (ItemActionType actionType, FieldItem fitem) => {
                    Debug.LogFormat("--> type:{0} fieldItem:{1}", actionType, fitem);

                    ExecutePlayerFootItemAction(actionType, fitem);
                });
                _footItemCommandWindow.SetActive(true);
                return;
            }

            // 足下ワナ
            var trap = _floor.FindTrap(_player.Loc);
            if (trap != null)
            {
                ChangeGameState(GameState.DisplayFootTrapCommandWindow);
                var c = _footTrapCommandWindow.GetComponent <FootTrapCommandWindow>();
                c.Init(trap, (TrapActionType actionType, Trap t) => {
                    Debug.LogFormat("--> type:{0} trap:{1}", actionType, t);
                    ExecutePlayerFootTrapAction(actionType, t);
                });

                _footTrapCommandWindow.SetActive(true);
                return;
            }

            // 足下階段
            if (_player.Loc == _floor.StairsLoc)
            {
                ConfirmDownStairs(GameState.InputWait);
                ChangeGameState(GameState.ConfirmStairsDialog);
                return;
            }
        });

        _btnGiveup.onClick.AddListener(() => {
            if (_gameState != GameState.InputWait)
            {
                return;
            }
            ChangeGameState(GameState.ConfirmGiveup);
        });

        _btnChangeDir.onClick.AddListener(() => {
            if (_gameState != GameState.InputWait)
            {
                return;
            }

            Debug.Log("方向転換します");
            _player.ShowDirectionAll();
            ChangeGameState(GameState.ChangeDirWaitPress);
        });

        DLog.Enable = false;
        _keyPad     = new KeyPad();
        _banner     = new FloorBanner();
        _gm         = new GameManager();
        _mm         = new MessageManager(this);

        _player = _gm.CreatePlayer(new Loc(3, 3));
        _player.setCallback(OnPlayerStatusAdded, OnPlayerStatusRemoved);

        var camera = GameObject.Find("Main Camera");

        camera.GetComponent <Camera>().orthographicSize = _cameraManager.CurrentSize;

        // Zoom ボタンのクリックイベント
        var btnZoom = GameObject.Find("Button_Zoom");

        btnZoom.GetComponent <Button>().onClick.AddListener(() => {
            if (_gameState == GameState.InputWait)
            {
                camera.GetComponent <Camera>().orthographicSize = _cameraManager.NextSize();
            }
        });
        btnZoom.SetActive(false);

        ChangeGameState(GameState.NextFloorTransition);
        StartCoroutine(NextFloor(true));
    }
Ejemplo n.º 24
0
        public IEnumerable <String> Build(KeyPad source, KeyType type)
        {
            if (source == null)
            {
                throw new ArgumentNullException(nameof(source));
            }

            Char[,] matrix = source.ToMatrix(type, out Int32 rows, out Int32 cols);

            List <String> results = new List <String>();
            String        current = String.Empty;

            // NOTE: Some of the resulting strings may contain duplicates in case of
            //       processing the data of the NUM pad (e.g. double zeros). This is
            //       actually not perfect but it doesn't really matter.

            current = this.GetHorizontalFirstToLast(matrix, rows, cols);

            results.Add(current);
            results.Add(this.Reverse(current));

            current = this.Clear(current);

            results.Add(current);
            results.Add(this.Reverse(current));

            current = this.GetHorizontalLastToFirst(matrix, rows, cols);

            results.Add(current);
            results.Add(this.Reverse(current));

            current = this.Clear(current);

            results.Add(current);
            results.Add(this.Reverse(current));

            current = this.GetOrthogonalLeftToRight(matrix, rows, cols);

            results.Add(current);
            results.Add(this.Reverse(current));

            current = this.Clear(current);

            results.Add(current);
            results.Add(this.Reverse(current));

            current = this.GetOrthogonalRightToLeft(matrix, rows, cols);

            results.Add(current);
            results.Add(this.Reverse(current));

            current = this.Clear(current);

            results.Add(current);
            results.Add(this.Reverse(current));

            if (!source.IsNumPad)
            {
                current = this.GetAlphabet(type);

                results.Add(current);
                results.Add(this.Reverse(current));
            }

            results = results.Where(x => !String.IsNullOrWhiteSpace(x)).Distinct().ToList();

            this.DumpResults(results);

            return(results);
        }
Ejemplo n.º 25
0
 public IEnumerable <String> Build(KeyPad source)
 {
     return(Build(source, KeyType.Lower));
 }
Ejemplo n.º 26
0
 public override void ResisterObject(UI obj)
 {
     this.pad = obj as KeyPad;
 }
 private void returnToMain_Click(object sender, RoutedEventArgs e)
 {
     BackExit.Exit();
     KeyPad.stop();
     ReadIDCar.stop();
 }
Ejemplo n.º 28
0
        static bool Play()
        {
            Font     f        = new Font("tahoma", 25);
            SnakePit snakePit = new SnakePit();
            Random   rnd      = new Random();
            int      delay    = 300;

            ASnake snake = new ASnake(snakePit, 5, snakePit.Centre, Color.Black);

            CrashType crashType;

            for (; ;)
            {
                Thread.Sleep(delay);
                KeyPadKey key;
                if (KeyPad.LatestKeyDown(out key))
                {
                    switch (key)
                    {
                    case KeyPadKey.B6:                     // Left
                        snake.SetDirection(-1, 0);
                        break;

                    case KeyPadKey.B7:                     // Down
                        snake.SetDirection(0, 1);
                        break;

                    case KeyPadKey.B8:                     // Up
                        snake.SetDirection(0, -1);
                        break;

                    case KeyPadKey.B9:                     // Right
                        snake.SetDirection(1, 0);
                        break;

                    case KeyPadKey.C:
                        return(false);
                    }
                }
                crashType = snake.Move();
                bool finish = false;
                switch (crashType)
                {
                case CrashType.None:
                    break;

                case CrashType.Self:
                case CrashType.Wall:
                default:
                    finish = true;
                    break;

                case CrashType.Food:
                    bool levelUp = snakePit.EatFood();
                    if (levelUp)
                    {
                        delay = (delay * 3) / 4;
                    }
                    snake.IncreaseLength(4);
                    break;
                }
                snake.DrawHead();
                if (finish)
                {
                    break;
                }

                int r = rnd.Next(1000);
                if (r < 50)
                {
                    snakePit.CreateFood(r < 5);
                }
                r = rnd.Next(1000);
                if (r < 20)
                {
                    snakePit.AddObsticle();
                }
            }
            snakePit.Msg(crashType.ToString());
            Thread.Sleep(5000);

            return(true);
        }
Ejemplo n.º 29
0
 /// <summary>
 /// Required method for Designer support - do not modify
 /// the contents of this method with the code editor.
 /// </summary>
 private void InitializeComponent()
 {
     this.label1 = new System.Windows.Forms.Label();
     this.label3 = new System.Windows.Forms.Label();
     this.label4 = new System.Windows.Forms.Label();
     this.button2 = new System.Windows.Forms.Button();
     this.txt_amount = new System.Windows.Forms.TextBox();
     this.btn_confirm = new System.Windows.Forms.Button();
     this.lst_transferFrom = new System.Windows.Forms.ListBox();
     this.lst_transferTo = new System.Windows.Forms.ListBox();
     this.pnl_accounts = new System.Windows.Forms.Panel();
     this.keypad_transfer = new BankMachine.KeyPad();
     this.pnl_accounts.SuspendLayout();
     this.SuspendLayout();
     //
     // label1
     //
     this.label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 21.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
     this.label1.Location = new System.Drawing.Point(0, 22);
     this.label1.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
     this.label1.Name = "label1";
     this.label1.Size = new System.Drawing.Size(583, 56);
     this.label1.TabIndex = 0;
     this.label1.Text = "Enter an amount to transfer";
     this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
     //
     // label3
     //
     this.label3.AutoSize = true;
     this.label3.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
     this.label3.Location = new System.Drawing.Point(12, 42);
     this.label3.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
     this.label3.Name = "label3";
     this.label3.Size = new System.Drawing.Size(198, 24);
     this.label3.TabIndex = 2;
     this.label3.Text = "Transfer from account:";
     //
     // label4
     //
     this.label4.AutoSize = true;
     this.label4.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
     this.label4.Location = new System.Drawing.Point(337, 42);
     this.label4.Margin = new System.Windows.Forms.Padding(2, 0, 2, 0);
     this.label4.Name = "label4";
     this.label4.Size = new System.Drawing.Size(176, 24);
     this.label4.TabIndex = 3;
     this.label4.Text = "Transfer to account:";
     //
     // button2
     //
     this.button2.Location = new System.Drawing.Point(11, 511);
     this.button2.Margin = new System.Windows.Forms.Padding(2);
     this.button2.Name = "button2";
     this.button2.Size = new System.Drawing.Size(100, 40);
     this.button2.TabIndex = 9;
     this.button2.Text = "Back to home";
     this.button2.UseVisualStyleBackColor = true;
     this.button2.Click += new System.EventHandler(this.button2_Click);
     //
     // txt_amount
     //
     this.txt_amount.BackColor = System.Drawing.SystemColors.Window;
     this.txt_amount.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
     this.txt_amount.Location = new System.Drawing.Point(141, 92);
     this.txt_amount.Margin = new System.Windows.Forms.Padding(2);
     this.txt_amount.Name = "txt_amount";
     this.txt_amount.ReadOnly = true;
     this.txt_amount.Size = new System.Drawing.Size(276, 38);
     this.txt_amount.TabIndex = 19;
     this.txt_amount.Text = "Press to enter amount";
     this.txt_amount.MouseClick += new System.Windows.Forms.MouseEventHandler(this.txt_amount_MouseClick);
     //
     // btn_confirm
     //
     this.btn_confirm.Enabled = false;
     this.btn_confirm.Font = new System.Drawing.Font("Microsoft Sans Serif", 14.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
     this.btn_confirm.Location = new System.Drawing.Point(387, 263);
     this.btn_confirm.Margin = new System.Windows.Forms.Padding(2);
     this.btn_confirm.Name = "btn_confirm";
     this.btn_confirm.Size = new System.Drawing.Size(96, 57);
     this.btn_confirm.TabIndex = 21;
     this.btn_confirm.Text = "Continue";
     this.btn_confirm.UseVisualStyleBackColor = true;
     this.btn_confirm.Click += new System.EventHandler(this.button4_Click);
     //
     // lst_transferFrom
     //
     this.lst_transferFrom.Font = new System.Drawing.Font("Microsoft Sans Serif", 21.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
     this.lst_transferFrom.FormattingEnabled = true;
     this.lst_transferFrom.ItemHeight = 33;
     this.lst_transferFrom.Location = new System.Drawing.Point(12, 69);
     this.lst_transferFrom.Name = "lst_transferFrom";
     this.lst_transferFrom.Size = new System.Drawing.Size(198, 136);
     this.lst_transferFrom.TabIndex = 24;
     this.lst_transferFrom.SelectedIndexChanged += new System.EventHandler(this.lst_transferFrom_SelectedIndexChanged);
     //
     // lst_transferTo
     //
     this.lst_transferTo.Font = new System.Drawing.Font("Microsoft Sans Serif", 21.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
     this.lst_transferTo.FormattingEnabled = true;
     this.lst_transferTo.ItemHeight = 33;
     this.lst_transferTo.Location = new System.Drawing.Point(315, 69);
     this.lst_transferTo.Name = "lst_transferTo";
     this.lst_transferTo.Size = new System.Drawing.Size(198, 136);
     this.lst_transferTo.TabIndex = 25;
     this.lst_transferTo.SelectedIndexChanged += new System.EventHandler(this.lst_transferTo_SelectedIndexChanged);
     //
     // pnl_accounts
     //
     this.pnl_accounts.Controls.Add(this.lst_transferTo);
     this.pnl_accounts.Controls.Add(this.btn_confirm);
     this.pnl_accounts.Controls.Add(this.label4);
     this.pnl_accounts.Controls.Add(this.label3);
     this.pnl_accounts.Controls.Add(this.lst_transferFrom);
     this.pnl_accounts.Location = new System.Drawing.Point(24, 149);
     this.pnl_accounts.Name = "pnl_accounts";
     this.pnl_accounts.Size = new System.Drawing.Size(534, 348);
     this.pnl_accounts.TabIndex = 26;
     //
     // keypad_transfer
     //
     this.keypad_transfer.AllowDot = false;
     this.keypad_transfer.CancelText = "X";
     this.keypad_transfer.Location = new System.Drawing.Point(192, 158);
     this.keypad_transfer.Name = "keypad_transfer";
     this.keypad_transfer.Size = new System.Drawing.Size(169, 286);
     this.keypad_transfer.TabIndex = 23;
     this.keypad_transfer.TextMode = false;
     this.keypad_transfer.Submit += new BankMachine.KeyPad.SubmitEventHandler(this.keypad_transfer_Submit);
     //
     // Transfer
     //
     this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
     this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
     this.ClientSize = new System.Drawing.Size(584, 562);
     this.Controls.Add(this.keypad_transfer);
     this.Controls.Add(this.txt_amount);
     this.Controls.Add(this.button2);
     this.Controls.Add(this.label1);
     this.Controls.Add(this.pnl_accounts);
     this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
     this.Margin = new System.Windows.Forms.Padding(2);
     this.MaximizeBox = false;
     this.MinimizeBox = false;
     this.Name = "Transfer";
     this.ShowIcon = false;
     this.Text = "Bank Machine";
     this.pnl_accounts.ResumeLayout(false);
     this.pnl_accounts.PerformLayout();
     this.ResumeLayout(false);
     this.PerformLayout();
 }
 private void back_Click(object sender, RoutedEventArgs e)
 {
     BackExit.Back();
     ReadIDCar.stop();
     KeyPad.stop();
 }
Ejemplo n.º 31
0
 private void Start()
 {
     _keyPad = GetComponentInParent <KeyPad>();
 }