private void Btn_Reuse_Click(object sender, EventArgs e) { NumberEventArgs nea; Int32 number = 0; if (ReuseNumber.StartsWith("+")) { Int32.TryParse(ReuseNumber.Remove(0, 1), out number); nea = new NumberEventArgs(number, NumberEventArgs.Dir.Positive); } else if (ReuseNumber.StartsWith("-")) { Int32.TryParse(ReuseNumber.Remove(0, 1), out number); nea = new NumberEventArgs(number * -1, NumberEventArgs.Dir.Negative); } else { Int32.TryParse(ReuseNumber, out number); nea = new NumberEventArgs(number, NumberEventArgs.Dir.Set); } EventHandler <NumberEventArgs> Handler = OnOk; if (null != Handler) { Handler(this, nea); } }
public void InvokeOnBurst(object a_sender, Vector3EventArgs a_1vector3EventArgs, NumberEventArgs a_2numberEventArgs) { if (OnBurst != null) { OnBurst.Invoke(a_sender, a_1vector3EventArgs, a_2numberEventArgs); } }
private void BtnCancel_Click(object sender, EventArgs e) { UpdateNumber(); string s = StringNumber.ToString(); NumberEventArgs nea; if (s.StartsWith("+")) { nea = new NumberEventArgs(Int32.Parse(StringNumber.ToString()), NumberEventArgs.Dir.Positive); } else if (s.StartsWith("-")) { nea = new NumberEventArgs(Int32.Parse(StringNumber.ToString()), NumberEventArgs.Dir.Negative); } else { nea = new NumberEventArgs(Int32.Parse(StringNumber.ToString()), NumberEventArgs.Dir.Set); } EventHandler <NumberEventArgs> Handler = OnCancel; if (null != Handler) { Handler(this, nea); } }
private void PeriodView_OnPeriodSplitted(object sender, NumberEventArgs e) { BootPeriodSplitForm periodSplitForm = new BootPeriodSplitForm(Schedule.BootPeriods[e.Number]); periodSplitForm.ShowDialog(); Schedule.BootPeriods.RemoveAt(e.Number); Schedule.BootPeriods.InsertRange(e.Number, periodSplitForm.Splitted); InitList(); }
protected override void _enterNumberView_ConfirmNumber(object sender, EventArgs e) { NumberEventArgs card = e as NumberEventArgs; if (card != null) { SendMessage("Подождите, идет обработка данных..."); _waitForm = new WaitForm(); _waitForm.Show(); _bw.RunWorkerAsync(card.Number); } }
private void OnTurnEndEvent(object sender, NumberEventArgs args) { players[args.Number].SetPlayerSteady(); if (args.Number == 3) { players[0].SetPlayerReady(); } else { players[args.Number + 1].SetPlayerReady(); } }
protected override void _enterNumberView_ConfirmNumber(object sender, EventArgs e) { // здесь номер введенного ключа NumberEventArgs number = e as NumberEventArgs; if (number != null) { SendMessage("Подождите, идет обработка данных..."); _waitForm = new WaitForm(); _waitForm.Show(); _bw.RunWorkerAsync(new NumberEventArgs(number.Number)); } }
protected override void _enterNumberView_ConfirmNumber(object sender, EventArgs e) { // здесь номер телефона NumberEventArgs number = e as NumberEventArgs; if (number != null) { SendMessage("Подождите, идет обработка данных..."); _waitForm = new WaitForm(); _waitForm.Show(); _bw.RunWorkerAsync(new Phones() { ClientId = CurrentCard.ClientId, Number = number.Number }); } }
private void Wfv_InsertCard(object sender, EventArgs e) { NumberEventArgs nea = e as NumberEventArgs; if (nea != null) { IEnterCardNumberView enterCardNumberView = new EnterCardNumberView(); _enterCardNumberPresenter = new EnterPinNumberPresenter(new BoolEventArgs("Вставка карты.", new Cards() { CardNumber = nea.Number }, BaseViewsFunctionality.StartPageBaseView), enterCardNumberView); _enterCardNumberPresenter.Confirm += _enterPinNumberPresenter_Confirm; _enterCardNumberPresenter.ToStart += Presenter_ToStart; _mainForm.AddView(enterCardNumberView as EnterCardNumberView); } }
protected override void _enterNumberView_CheckNumber(object sender, EventArgs e) { if (_basePersonalAreaView == null) { return; } NumberEventArgs card = e as NumberEventArgs; if (card != null) { if (CheckNumber(card.Number)) { (_basePersonalAreaView as IEnterCardNumberView).ConfirmSending(card.Number); } else { SendMessage("Вы ввели неправильный номер телефона"); } } }
protected override void _enterNumberView_CheckNumber(object sender, EventArgs e) { if (_basePersonalAreaView == null) { return; } NumberEventArgs pin = e as NumberEventArgs; if (pin != null) { if (CheckNumber(pin.Number)) { (_basePersonalAreaView as IEnterCardNumberView).ConfirmSending(pin.Number); } else { SendMessage("Вы ввели неправильный ПИН-код"); } } }
protected override void _enterNumberView_CheckNumber(object sender, EventArgs e) { if (_basePersonalAreaView == null) { return; } NumberEventArgs sum = e as NumberEventArgs; if (sum != null) { if (CheckNumber(sum.Number)) { (_basePersonalAreaView as IEnterCardNumberView).ConfirmSending(sum.Number); } else { SendMessage("Вы ввели неправильную сумму для снятия"); } } }
protected override void _bw_DoWork(object sender, DoWorkEventArgs e) { NumberEventArgs ph = e.Argument as NumberEventArgs; if (ph != null) { // проверить на валидность полученный ключ if (CheckNumber(ph.Number)) { bool isValidKey = _bankomatLocalService.CheckPhoneKey(CurrentCard.ClientId, _phoneKey); e.Result = isValidKey; } else { e.Result = null; } } else { e.Result = null; } }
private void BtnOk_Click(object sender, EventArgs e) { UpdateNumber(); string s = StringPrefix + StringNumber.ToString(); NumberEventArgs nea; Int32 number = 0; Int32.TryParse(StringNumber.ToString(), out number); if (s.StartsWith("+")) { nea = new NumberEventArgs(number, NumberEventArgs.Dir.Positive); } else if (s.StartsWith("-")) { nea = new NumberEventArgs(number * -1, NumberEventArgs.Dir.Negative); } else { nea = new NumberEventArgs(number, NumberEventArgs.Dir.Set); } EventHandler <NumberEventArgs> Handler = OnOk; if (null != Handler) { Handler(this, nea); } ReuseNumber = s; TxtNumber.Text = "(" + TxtNumber.Text + ")"; StringNumber = new StringBuilder(); StringPrefix = ""; }
void ReadyHandler(object o, NumberEventArgs e) { OnReady(e.ID); }
private void ReservedInfoView_OnReservedForgotten(object sender, NumberEventArgs e) { Reserved.RemoveAt(e.Number); InitList(); }
private void BootPeriodView_OnPeriodDeleted(object sender, NumberEventArgs e) { Schedule.BootPeriods.RemoveAt(e.Number); InitList(); }
protected virtual void OnDiceRolled(NumberEventArgs args) { RaiseDiceRollEvent?.Invoke(this, args); }
// eventhandler Method private void ShowMessage(object sender, NumberEventArgs e) { MessageBox.Show("Hello user your ticket no is:" + e.getNumber().ToString()); }
protected virtual void OnTurnEnd(NumberEventArgs args) { TurnEndEvent?.Invoke(this, args); }
private void OnTokenSelectionEvent(object sender, NumberEventArgs args) { LockTokens(args.Number); tokens[args.Number].MoveSteps(dice.Value); }
private void OnDiceRollEvent(object sender, NumberEventArgs args) { UnlockTokens(args.Number); }
private void NumberCruncher_NumberEvent(object sender, NumberEventArgs e) { SendNotification(e.Number.ToString()); }
protected virtual void OnTokenSelection(NumberEventArgs args) { RaiseTokenSelectionEvent?.Invoke(this, args); }
private async void NumberCruncher_NumberEvent(object sender, NumberEventArgs e) { Debug.WriteLine($"{ApplicationView.GetForCurrentView().Id} is trying to display {e.Id} {e.Number} on {Environment.CurrentManagedThreadId}"); listView.Items.Add($"{e.Id} sent {e.Number}"); }