private void button_Click(object sender, RoutedEventArgs e) { button.IsEnabled = false; buttonProgressBar.Visibility = System.Windows.Visibility.Visible; string url = server.address + "/api/account/setdata"; EditInput input; if (newPasswordBox.Password == repNewPasswordBox.Password) { if (newPasswordBox.Password == "") { input = new EditInput(server.login, server.sid, nameBox.Text, mailBox.Text, null); } else { input = new EditInput(server.login, server.sid, nameBox.Text, mailBox.Text, newPasswordBox.Password); } new HttpPostRequest <EditInput, EditOutput>(url, editCallback, input); } else { MessageBox.Show("These passwords are different."); newPasswordBox.Password = repNewPasswordBox.Password = ""; button.IsEnabled = true; } }
public void Edit(EditInput input) { var accessory = _accessoryRepository.Get(input.Id); accessory.Number = input.Number; accessory.Unit = input.Unit; accessory.Name = input.Name; accessory.Model = input.Model; }
public override Empty Edit(EditInput input) { var setInfo = State.NovelSetInfos[input.SetId]; if (setInfo == null) { throw new AssertionException($"Set with Id {input.SetId} not found."); } var novelInfo = State.NovelInfos[input.NovelId]; novelInfo.Text = input.Text; novelInfo.NovelTextHash = input.NovelTestHash; novelInfo.LatestEditTime = Context.CurrentBlockTime; State.NovelInfos[input.NovelId] = novelInfo; return(new Empty()); }
public override void OnSetAction() { if (defaultText == null) { text = Text.Construct(); text.TextString = StringTable.GetString("Text.Default"); text.LineDirection = base.ActiveDrawingPlane.DirectionX; text.GlyphDirection = base.ActiveDrawingPlane.DirectionY; text.TextSize = ConstrDefaults.DefaultTextSize; text.Font = "Arial"; } else { text = defaultText.Clone() as Text; } text.LineAlignment = Text.LineAlignMode.Center; text.Location = ConstrDefaults.DefaultStartPoint; Plane pl = new Plane(text.Location, text.LineDirection, text.GlyphDirection); textDir2D = pl.Project(text.GlyphDirection); textLen = text.LineDirection.Length; base.ActiveObject = text; gPoint = ActionFeedBack.FeedbackPoint(base.Frame); base.FeedBack.Add(gPoint); base.TitleId = "Constr.Text.2Points"; startPointInput = new GeoPointInput("Text.StartPoint"); startPointInput.DefaultGeoPoint = ConstrDefaults.DefaultStartPoint; startPointInput.DefinesBasePoint = true; startPointInput.SetGeoPointEvent += new ConstructAction.GeoPointInput.SetGeoPointDelegate(StartPoint); secondPointInput = new GeoPointInput("Text.SecondPoint"); secondPointInput.SetGeoPointEvent += new ConstructAction.GeoPointInput.SetGeoPointDelegate(SecondPoint); EditInput editInput = new EditInput(text); base.SetInput(startPointInput, secondPointInput, editInput); base.ShowAttributes = true; base.OnSetAction(); }
public override void OnSetAction() { if (defaultText == null) { text = Text.Construct(); text.TextString = StringTable.GetString("Text.Default"); text.LineDirection = base.ActiveDrawingPlane.DirectionX; text.GlyphDirection = base.ActiveDrawingPlane.DirectionY; text.TextSize = ConstrDefaults.DefaultTextSize; text.Font = "Arial"; } else { text = defaultText.Clone() as Text; } if (!Precision.IsPerpendicular(ActiveDrawingPlane.Normal, text.LineDirection, false) || !Precision.IsPerpendicular(ActiveDrawingPlane.Normal, text.GlyphDirection, false)) { // die DrawingPlane wurde seit dem letzten Text geändert text.LineDirection = base.ActiveDrawingPlane.DirectionX; text.GlyphDirection = base.ActiveDrawingPlane.DirectionY; } base.ActiveObject = text; base.TitleId = "Constr.Text.1Point"; GeoPointInput startPointInput = new GeoPointInput("Text.StartPoint"); startPointInput.DefaultGeoPoint = ConstrDefaults.DefaultStartPoint; startPointInput.DefinesBasePoint = true; startPointInput.SetGeoPointEvent += new ConstructAction.GeoPointInput.SetGeoPointDelegate(StartPoint); EditInput editInput = new EditInput(text); base.SetInput(startPointInput, editInput); base.ShowAttributes = true; base.OnSetAction(); }
public TaskItemEditVM() { Input = new EditInput(); }
public MemberNoteEditVM() { Input = new EditInput(); }
public void Edit(EditInput input) { var product = _faultRepository.Get(input.Id); product.Name = input.Name; }
public CorpEditVM() { Input = new EditInput(); }
public UserEditVM() { Input = new EditInput(); }
public DeptEditVM() { Input = new EditInput(); }