Esempio n. 1
0
        void app_FeedSourceAdded(object sender, FeedSourceEventArgs e)
        {
            UnreadItemsNodePerSource child = new UnreadItemsNodePerSource(
                e.Entry, itemsFeed, ImageIndex, SelectedImageIndex, p_popup);

            this.Nodes.Add(child);
            childrenBySourceID.Add(e.Entry.ID, child);
        }
Esempio n. 2
0
        public UnreadItemsNode(LocalFeedsFeed itemStore, int imageIndex, int selectedImageIndex, ContextMenuStrip menu) :
            base(itemStore, imageIndex, selectedImageIndex, menu)
        {
            // TODO: we should extend the interface ICoreApplication
            app = (RssBanditApplication)IoC.Resolve <ICoreApplication>();

            app.FeedSourceAdded   += app_FeedSourceAdded;
            app.FeedSourceChanged += app_FeedSourceChanged;
            app.FeedSourceDeleted += app_FeedSourceDeleted;

            if (app.FeedSources.Count > 1)
            {
                foreach (FeedSourceEntry e in app.FeedSources.Sources)
                {
                    UnreadItemsNodePerSource child = new UnreadItemsNodePerSource(
                        e, itemStore, imageIndex, selectedImageIndex, menu);
                    this.Nodes.Add(child);
                    childrenBySourceID.Add(e.ID, child);
                }
            }
        }