Exemplo n.º 1
0
 protected void Page_Load(object sender, EventArgs e)
 {
     foreach (Class c in Docs.GetNamespaceByName("Ra.Behaviors").Classes)
     {
         LinkButton classLink = new LinkButton {
             Text = c.FullName, Xtra = c.ID
         };
         classLink.Click += classLink_Click;
         typesPanel.Controls.Add(classLink);
         typesPanel.Controls.Add(new System.Web.UI.LiteralControl("<br />"));
     }
 }
Exemplo n.º 2
0
    private void classLink_Click(object sender, EventArgs e)
    {
        Namespace raWidgets = Docs.GetNamespaceByName("Ra.Behaviors");

        SelectedClass = (from c2 in raWidgets.Classes
                         where c2.ID == ((LinkButton)sender).Xtra
                         select c2).Single() as Class;

        if (SelectedClass == null)
        {
            return;
        }

        descriptionLabel.Text = SelectedClass.Description;
        members.LoadControls();
    }