private void btnAdd_Click(object sender, RoutedEventArgs e) { if (richText == null) { return; } DaoUtils.AddSource("new source", richText); }
private void addSource_Click(object sender, RoutedEventArgs e) { if (EditedDiscussion == null) { return; } DaoUtils.EnsureBgExists(EditedDiscussion); DaoUtils.AddSource(EditedDiscussion.Background); }
private void btnAddSource_Click(object sender, RoutedEventArgs e) { ArgPoint ap = DataContext as ArgPoint; if (ap == null) { return; } DaoUtils.AddSource("New source", ap.Description); }
private void btnAddSrc_Click(object sender, RoutedEventArgs e) { var d = DataContext as Discussion; if (d == null) { return; } DaoUtils.AddSource(txtSource.Text, d.Background); BeginDeferredItemTemplateHandle(); UpdateOrderedSources(); }
void AttachSource() { var ap = DataContext as ArgPoint; if (ap == null) { return; } string url = txtSource.Text.Trim(); if (ap.Description.Source.FirstOrDefault(s => s.Text == url) != null) { return; } if (Validators.UriOk(url)) { DaoUtils.AddSource(txtSource.Text, ap.Description); ap.ChangesPending = true; UISharedRTClient.Instance.clienRt.SendStatsEvent( StEvent.SourceAdded, ap.Person.Id, ap.Topic.Discussion.Id, ap.Topic.Id, DeviceType.Wpf); UpdateOrderedSources(); BeginSrcNumberInjection(); } else if (!string.IsNullOrWhiteSpace(txtSource.Text) && txtSource.Text != ap.RecentlyEnteredSource) { ErrMessages.InvalidUrl(); } }