Esempio n. 1
0
        private LinkViewWidget AddItem(MovieLink video)
        {
            //create links
            var widget = new LinkViewWidget(video);

            widget.Anchor = AnchorStyles.Left | AnchorStyles.Right;
            widget.Width  = this.Width;
            this.tableLayoutPanel.Controls.Add(widget);
            Application.DoEvents();
            widget.ViewSelected += delegate(object sender, GalleryItemSelectedEventArgs e)
            {
                OnItemSelected(sender, e);
            };
            widget.DownloadClicked += delegate(object sender, GalleryItemSelectedEventArgs e)
            {
                OnDownloadClicked(sender, e);
            };
            return(widget);
        }
 private LinkViewWidget AddItem(MovieLink video)
 {
     //create links
     var widget = new LinkViewWidget(video);
     widget.Anchor = AnchorStyles.Left | AnchorStyles.Right;
     widget.Width = this.Width;
     this.tableLayoutPanel.Controls.Add(widget);
     Application.DoEvents();
     widget.ViewSelected += delegate(object sender, GalleryItemSelectedEventArgs e)
     {
         OnItemSelected(sender, e);
     };
     widget.DownloadClicked += delegate(object sender, GalleryItemSelectedEventArgs e)
     {
         OnDownloadClicked(sender, e);
     };
     return widget;
 }