示例#1
0
        private void loadBackground(object options)
        {
            foreach (FilteredTitleCollection dateAdded in TitleCollectionManager.GetAllDateAddedGrouped(m_filters))
            {
                Library.Code.V3.YearBrowseGroup testGroup2 = new Library.Code.V3.YearBrowseGroup(new List <Title>(dateAdded.Titles));

                testGroup2.Owner        = this;
                testGroup2.Description  = dateAdded.Name;
                testGroup2.DefaultImage = null;// new Image("resx://Library/Library.Resources/Genre_Sample_mystery");
                testGroup2.Invoked     += delegate(object sender, EventArgs args)
                {
                    OMLProperties properties = new OMLProperties();
                    properties.Add("Application", OMLApplication.Current);
                    properties.Add("I18n", I18n.Instance);
                    Command CommandContextPopOverlay = new Command();
                    properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);

                    List <TitleFilter> newFilter = new List <TitleFilter>(m_filters);
                    newFilter.Add(new TitleFilter(TitleFilterType.DateAdded, dateAdded.Name));

                    Library.Code.V3.GalleryPage gallery = new Library.Code.V3.GalleryPage(newFilter, testGroup2.Description);

                    properties.Add("Page", gallery);
                    OMLApplication.Current.Session.GoToPage(@"resx://Library/Library.Resources/V3_GalleryPage", properties);
                };
                testGroup2.ContentLabelTemplate = Library.Code.V3.BrowseGroup.StandardContentLabelTemplate;
                this.m_listContent.Add(testGroup2);
            }

            this.IsBusy = false;
        }
示例#2
0
        public GenreItem(Library.GalleryItem title, IModelItem owner, List<TitleFilter> filter)
            : base(owner)
        {
            this.Description = title.Name;
            this.DefaultImage=title.MenuCoverArt;
            this.Metadata = string.Format("{0} titles", title.ForcedCount);
            this.Invoked += delegate(object sender, EventArgs args)
            {
                //am I being silly here copying this?
                List<TitleFilter> newFilter = new List<TitleFilter>();
                foreach (TitleFilter filt in filter)
                {
                    newFilter.Add(filt);
                }
                newFilter.Add(new TitleFilter(title.Category.FilterType, title.Name));
                OMLProperties properties = new OMLProperties();
                properties.Add("Application", OMLApplication.Current);
                properties.Add("I18n", I18n.Instance);
                Command CommandContextPopOverlay = new Command();
                properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);

                Library.Code.V3.GalleryPage gallery = new Library.Code.V3.GalleryPage(newFilter, title.Description);

                properties.Add("Page", gallery);
                OMLApplication.Current.Session.GoToPage(@"resx://Library/Library.Resources/V3_GalleryPage", properties);
            };
        }
示例#3
0
        public FilterItem(Library.GalleryItem title, IModelItem owner, List <TitleFilter> filter)
            : base(owner)
        {
            this.Description = title.Caption;

            this.Invoked += delegate(object sender, EventArgs args)
            {
                //am I being silly here copying this?
                List <TitleFilter> newFilter = new List <TitleFilter>();
                foreach (TitleFilter filt in filter)
                {
                    newFilter.Add(filt);
                }
                newFilter.Add(new TitleFilter(title.Category.FilterType, title.Name));
                OMLProperties properties = new OMLProperties();
                properties.Add("Application", OMLApplication.Current);
                properties.Add("I18n", I18n.Instance);
                Command CommandContextPopOverlay = new Command();
                properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);

                Library.Code.V3.GalleryPage gallery = new Library.Code.V3.GalleryPage(newFilter, title.Description);

                properties.Add("Page", gallery);
                OMLApplication.Current.Session.GoToPage(@"resx://Library/Library.Resources/V3_GalleryPage", properties);
            };
        }
示例#4
0
        //private void GoToWizard(List<OMLEngine.TitleFilter> filters, string name)
        //{
        //    OMLProperties properties = new OMLProperties();
        //    properties.Add("Application", this);
        //    properties.Add("I18n", I18n.Instance);
        //    //v3 main gallery
        //    Library.Code.V3.WizardGalleryPage gallery = new Library.Code.V3.WizardGalleryPage(filters, name);
        //    //description
        //    gallery.Description = name;
        //    Command CommandContextPopOverlay = new Command();
        //    properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);
        //    properties.Add("Page", gallery);
        //    _session.GoToPage(@"resx://Library/Library.Resources/V3_WizardGalleryPage", properties);
        //}

        private void GoHome(List <OMLEngine.TitleFilter> filters, string name)
        {
            OMLProperties properties = new OMLProperties();

            properties.Add("Application", this);
            properties.Add("I18n", I18n.Instance);
            //v3 main gallery
            Library.Code.V3.GalleryPage gallery = new Library.Code.V3.GalleryPage(filters, name);
            //description
            gallery.Description = name;
            Command CommandContextPopOverlay = new Command();

            properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);
            properties.Add("Page", gallery);
            _session.GoToPage(@"resx://Library/Library.Resources/V3_GalleryPage", properties);
        }
示例#5
0
        public GenreItem(UserFilter title, IModelItem owner, List<TitleFilter> filter)
            : base(owner)
        {
            this.Description = title.Name;

            this.Invoked += delegate(object sender, EventArgs args)
            {
                OMLProperties properties = new OMLProperties();
                properties.Add("Application", OMLApplication.Current);
                properties.Add("I18n", I18n.Instance);
                Command CommandContextPopOverlay = new Command();
                properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);

                Library.Code.V3.GalleryPage gallery = new Library.Code.V3.GalleryPage(filter, title.Name);

                properties.Add("Page", gallery);
                OMLApplication.Current.Session.GoToPage(@"resx://Library/Library.Resources/V3_GalleryPage", properties);
            };
        }
示例#6
0
        public FilterItem(UserFilter title, IModelItem owner, List <TitleFilter> filter)
            : base(owner)
        {
            this.Description = title.Name;

            this.Invoked += delegate(object sender, EventArgs args)
            {
                OMLProperties properties = new OMLProperties();
                properties.Add("Application", OMLApplication.Current);
                properties.Add("I18n", I18n.Instance);
                Command CommandContextPopOverlay = new Command();
                properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);

                Library.Code.V3.GalleryPage gallery = new Library.Code.V3.GalleryPage(filter, title.Name);

                properties.Add("Page", gallery);
                OMLApplication.Current.Session.GoToPage(@"resx://Library/Library.Resources/V3_GalleryPage", properties);
            };
        }
示例#7
0
        private void loadBackground(object options)
        {
            foreach (FilteredTitleCollection year in TitleCollectionManager.GetAllYearsGrouped(m_filters))
            {
                Library.Code.V3.YearBrowseGroup testGroup2 = new Library.Code.V3.YearBrowseGroup(new List <Title>(year.Titles));
                testGroup2.Owner = this;
                //tmp hack for unknown dates
                if (year.Name == "1900")
                {
                    testGroup2.Description = "UNKNOWN";
                }
                else
                {
                    testGroup2.Description = year.Name;
                }

                testGroup2.DefaultImage = null;
                testGroup2.Invoked     += delegate(object sender, EventArgs args)
                {
                    OMLProperties properties = new OMLProperties();
                    properties.Add("Application", OMLApplication.Current);
                    properties.Add("I18n", I18n.Instance);
                    Command CommandContextPopOverlay = new Command();
                    properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);

                    List <TitleFilter> newFilter = new List <TitleFilter>(m_filters);
                    newFilter.Add(new TitleFilter(TitleFilterType.Year, year.Name));

                    Library.Code.V3.GalleryPage gallery = new Library.Code.V3.GalleryPage(newFilter, testGroup2.Description);

                    properties.Add("Page", gallery);
                    OMLApplication.Current.Session.GoToPage(@"resx://Library/Library.Resources/V3_GalleryPage", properties);
                };

                testGroup2.ContentLabelTemplate = Library.Code.V3.BrowseGroup.StandardContentLabelTemplate;
                m_listContent.Add(testGroup2);
            }

            this.IsBusy = false;
        }
        //private void GoToWizard(List<OMLEngine.TitleFilter> filters, string name)
        //{
        //    OMLProperties properties = new OMLProperties();
        //    properties.Add("Application", this);
        //    properties.Add("I18n", I18n.Instance);
        //    //v3 main gallery
        //    Library.Code.V3.WizardGalleryPage gallery = new Library.Code.V3.WizardGalleryPage(filters, name);
        //    //description
        //    gallery.Description = name;
        //    Command CommandContextPopOverlay = new Command();
        //    properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);
        //    properties.Add("Page", gallery);
        //    _session.GoToPage(@"resx://Library/Library.Resources/V3_WizardGalleryPage", properties);
        //}

        private void GoHome(List<OMLEngine.TitleFilter> filters, string name)
        {
            OMLProperties properties = new OMLProperties();
            properties.Add("Application", this);
            properties.Add("I18n", I18n.Instance);
            //v3 main gallery
            Library.Code.V3.GalleryPage gallery = new Library.Code.V3.GalleryPage(filters, name);
            //description
            gallery.Description = name;
            Command CommandContextPopOverlay = new Command();
            properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);
            properties.Add("Page", gallery);
            _session.GoToPage(@"resx://Library/Library.Resources/V3_GalleryPage", properties);
        }
        private void loadBackground(object options)
        {
            foreach (FilteredTitleCollection dateAdded in TitleCollectionManager.GetAllDateAddedGrouped(m_filters))
            {
                Library.Code.V3.YearBrowseGroup testGroup2 = new Library.Code.V3.YearBrowseGroup(new List<Title>(dateAdded.Titles));

                testGroup2.Owner = this;
                testGroup2.Description = dateAdded.Name;
                testGroup2.DefaultImage = null;// new Image("resx://Library/Library.Resources/Genre_Sample_mystery");
                testGroup2.Invoked += delegate(object sender, EventArgs args)
                {
                    OMLProperties properties = new OMLProperties();
                    properties.Add("Application", OMLApplication.Current);
                    properties.Add("I18n", I18n.Instance);
                    Command CommandContextPopOverlay = new Command();
                    properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);

                    List<TitleFilter> newFilter = new List<TitleFilter>(m_filters);
                    newFilter.Add(new TitleFilter(TitleFilterType.DateAdded, dateAdded.Name));

                    Library.Code.V3.GalleryPage gallery = new Library.Code.V3.GalleryPage(newFilter, testGroup2.Description);

                    properties.Add("Page", gallery);
                    OMLApplication.Current.Session.GoToPage(@"resx://Library/Library.Resources/V3_GalleryPage", properties);
                };
                testGroup2.ContentLabelTemplate = Library.Code.V3.BrowseGroup.StandardContentLabelTemplate;
                this.m_listContent.Add(testGroup2);
            }

            this.IsBusy = false;
        }
示例#10
0
        private void loadBackground(object options)
        {
            foreach (FilteredTitleCollection year in TitleCollectionManager.GetAllYearsGrouped(m_filters))
            {
                Library.Code.V3.YearBrowseGroup testGroup2 = new Library.Code.V3.YearBrowseGroup(new List<Title>(year.Titles));
                testGroup2.Owner = this;
                //tmp hack for unknown dates
                if (year.Name == "1900")
                    testGroup2.Description = "UNKNOWN";
                else
                    testGroup2.Description = year.Name;

                testGroup2.DefaultImage = null;
                testGroup2.Invoked += delegate(object sender, EventArgs args)
                {
                    OMLProperties properties = new OMLProperties();
                    properties.Add("Application", OMLApplication.Current);
                    properties.Add("I18n", I18n.Instance);
                    Command CommandContextPopOverlay = new Command();
                    properties.Add("CommandContextPopOverlay", CommandContextPopOverlay);

                    List<TitleFilter> newFilter = new List<TitleFilter>(m_filters);
                    newFilter.Add(new TitleFilter(TitleFilterType.Year, year.Name));

                    Library.Code.V3.GalleryPage gallery = new Library.Code.V3.GalleryPage(newFilter, testGroup2.Description);

                    properties.Add("Page", gallery);
                    OMLApplication.Current.Session.GoToPage(@"resx://Library/Library.Resources/V3_GalleryPage", properties);
                };

                testGroup2.ContentLabelTemplate = Library.Code.V3.BrowseGroup.StandardContentLabelTemplate;
                m_listContent.Add(testGroup2);
            }

            this.IsBusy = false;
        }