Exemplo n.º 1
0
 public LinkItemControl(LinkEntry entry)
 {
     InitializeComponent();
     lblTitle.Content = entry.Name;
     tblkDescription.Text = entry.Description;
     foreach (LinkItem link in entry.Links)
     {
         tblkLinks.Inlines.Add(new Hyperlink(new Run(link.Name))
         {
             CommandParameter = link.Link,
             Command = new LinkCommand()
         });
         tblkLinks.Inlines.Add(new Run(Environment.NewLine));
     }
 }
Exemplo n.º 2
0
 /// <summary>
 /// Creates a new link entry.
 /// </summary>
 /// <param name="name">The name.</param>
 /// <param name="description">The description.</param>
 /// <returns></returns>
 public LinkEntry NewLinkEntry(string name, string description)
 {
     LinkEntry entry = new LinkEntry(name, description);
     Entries.Add(entry);
     return entry;
 }