public void Initialize([NotNull] TemplateFieldSorter templateFieldSorter, [NotNull] TemplateFieldSorter.TemplateFields templateFields, [NotNull] string sectionName, int sectionSortOrder, [NotNull] string sectionId) { Assert.ArgumentNotNull(templateFieldSorter, nameof(templateFieldSorter)); Assert.ArgumentNotNull(templateFields, nameof(templateFields)); Assert.ArgumentNotNull(sectionName, nameof(sectionName)); Assert.ArgumentNotNull(sectionId, nameof(sectionId)); TemplateFieldSorter = templateFieldSorter; TemplateFields = templateFields; SectionSortOrder.Text = sectionSortOrder.ToString(); SectionName.Text = sectionName; SectionId = sectionId; }
public void Initialize([NotNull] TemplateFieldSorter templateFieldSorter, [NotNull] TemplateFieldSorter.TemplateFields template, bool isCloseButtonVisible) { Assert.ArgumentNotNull(templateFieldSorter, nameof(templateFieldSorter)); Assert.ArgumentNotNull(template, nameof(template)); TemplateFields = template; ItemName.Text = template.Name; Icon.Source = template.Icon.GetSource(); TemplateFieldSorter = templateFieldSorter; CloseButton.Visibility = isCloseButtonVisible ? Visibility.Visible : Visibility.Collapsed; // this.ItemId.Text = template.TemplateUri.ItemId.ToString(); template.TemplateUri.Site.DataService.ExecuteAsync("Links.GetTemplateInstances", RenderInstances, template.TemplateUri.DatabaseName.ToString(), template.TemplateUri.ItemId.ToString()); }
public void Initialize([NotNull] TemplateFieldSorter templateFieldSorter, [NotNull] TemplateFieldSorter.Field field) { Assert.ArgumentNotNull(templateFieldSorter, nameof(templateFieldSorter)); Assert.ArgumentNotNull(field, nameof(field)); TemplateFieldSorter = templateFieldSorter; Field = field; FieldName.Content = Field.Name; SortOrder.Text = field.SortOrder.ToString(); FieldType.Text = field.Type; TemplateName.Text = field.TemplateName; Icon.Source = field.TemplateIcon.GetSource(); if (field.IsInherited) { Details.Foreground = SystemColors.GrayTextBrush; } }
public TemplateFieldSorterContext([NotNull] TemplateFieldSorter templateFieldSorter) { Assert.ArgumentNotNull(templateFieldSorter, nameof(templateFieldSorter)); TemplateFieldSorter = templateFieldSorter; }