Generic group data model.
Inheritance: SampleDataCommon
 /// <summary>
 /// 巡覽期間以傳遞的內容填入頁面。從之前的工作階段
 /// 重新建立頁面時,也會提供儲存的狀態。
 /// </summary>
 /// <param name="navigationParameter">最初要求這個頁面時,傳遞到
 /// <see cref="Frame.Navigate(Type, Object)"/> 的參數。
 /// </param>
 /// <param name="pageState">這個頁面在先前的工作階段期間保留的
 /// 狀態字典。第一次瀏覽頁面時,這一項是 null。</param>
 protected override void LoadState(Object navigationParameter, Dictionary<String, Object> pageState)
 {
     // TODO: 為您的問題領域建立適合的資料模型,以取代資料範例
     group = SampleDataSource.GetGroup((String)navigationParameter);
     this.DefaultViewModel["Group"] = group;
     this.DefaultViewModel["Items"] = group.Items;
     groupId = group.UniqueId;
     if (pageState == null)
     {
         this.itemListView.SelectedItem = null;
         // 當這是新頁面時,自動選取第一個項目,除非正在使用
         // 邏輯頁面巡覽 (參閱底下的邏輯頁面巡覽 #region)。
         if (!this.UsingLogicalPageNavigation() && this.itemsViewSource.View != null)
         {
             this.itemsViewSource.View.MoveCurrentToFirst();
         }
     }
     else
     {
         // 還原之前儲存、與這個頁面關聯的狀態
         if (pageState.ContainsKey("SelectedItem") && this.itemsViewSource.View != null)
         {
             var selectedItem = SampleDataSource.GetItem((String)pageState["SelectedItem"]);
             this.itemsViewSource.View.MoveCurrentTo(selectedItem);
         }
     }
 }
        public SampleDataSource(Frame frame)
        {
            this.frame = frame;
            String ITEM_CONTENT = String.Format("Item Content: {0}\n\n{0}\n\n{0}\n\n{0}\n\n{0}\n\n{0}\n\n{0}",
                        "Curabitur class aliquam vestibulum nam curae maecenas sed integer cras phasellus suspendisse quisque donec dis praesent accumsan bibendum pellentesque condimentum adipiscing etiam consequat vivamus dictumst aliquam duis convallis scelerisque est parturient ullamcorper aliquet fusce suspendisse nunc hac eleifend amet blandit facilisi condimentum commodo scelerisque faucibus aenean ullamcorper ante mauris dignissim consectetuer nullam lorem vestibulum habitant conubia elementum pellentesque morbi facilisis arcu sollicitudin diam cubilia aptent vestibulum auctor eget dapibus pellentesque inceptos leo egestas interdum nulla consectetuer suspendisse adipiscing pellentesque proin lobortis sollicitudin augue elit mus congue fermentum parturient fringilla euismod feugiat");

            var group1 = new SampleDataGroup(this.frame, "Group-1",
                    "Group Title: 1",
                    "Group Subtitle: 1",
                    "Assets/DarkGray.png",
                    "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group1.Items.Add(new SampleDataItem(this.frame, "Group-1-Item-1",
                    "Item Title: 1",
                    "Item Subtitle: 1",
                    "Assets/LightGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group1));
            this.AllGroups.Add(group1);
            var group2 = new SampleDataGroup(this.frame, "Group-2",
                    "Group Title: 2",
                    "Group Subtitle: 2",
                    "Assets/DarkGray.png",
                    "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group2.Items.Add(new SampleDataItem(this.frame, "Group-2-Item-1",
                    "Item Title: 2",
                    "Item Subtitle: 2",
                    "Assets/LightGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group2));
            this.AllGroups.Add(group2);
            var group3 = new SampleDataGroup(this.frame, "Group-3",
                    "Group Title: 3",
                    "Group Subtitle: 3",
                    "Assets/DarkGray.png",
                    "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group3.Items.Add(new SampleDataItem(this.frame, "Group-3-Item-1",
                    "Item Title: 3",
                    "Item Subtitle: 3",
                    "Assets/LightGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group3));
            this.AllGroups.Add(group3);
            var group4 = new SampleDataGroup(this.frame, "Group-4",
                    "Group Title: 4",
                    "Group Subtitle: 4",
                    "Assets/DarkGray.png",
                    "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group4.Items.Add(new SampleDataItem(this.frame, "Group-4-Item-1",
                    "Item Title: 4",
                    "Item Subtitle: 4",
                    "Assets/LightGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group4));
            this.AllGroups.Add(group4);
            var group5 = new SampleDataGroup(this.frame, "Group-5",
                    "Group Title: 5",
                    "Group Subtitle: 5",
                    "Assets/DarkGray.png",
                    "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group5.Items.Add(new SampleDataItem(this.frame, "Group-5-Item-1",
                    "Item Title: 5",
                    "Item Subtitle: 5",
                    "Assets/LightGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group5));
            this.AllGroups.Add(group5);
            var group6 = new SampleDataGroup(this.frame, "Group-6",
                    "Group Title: 6",
                    "Group Subtitle: 6",
                    "Assets/DarkGray.png",
                    "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group6.Items.Add(new SampleDataItem(this.frame, "Group-6-Item-1",
                    "Item Title: 6",
                    "Item Subtitle: 6",
                    "Assets/LightGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group6));
            this.AllGroups.Add(group6);
            var group7 = new SampleDataGroup(this.frame, "Group-7",
                    "Group Title: 7",
                    "Group Subtitle: 7",
                    "Assets/DarkGray.png",
                    "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group7.Items.Add(new SampleDataItem(this.frame, "Group-7-Item-1",
                    "Item Title: 7",
                    "Item Subtitle: 7",
                    "Assets/LightGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group7));
            this.AllGroups.Add(group7);
            var group8 = new SampleDataGroup(this.frame, "Group-8",
                   "Group Title: 8",
                   "Group Subtitle: 8",
                   "Assets/DarkGray.png",
                   "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group8.Items.Add(new SampleDataItem(this.frame, "Group-8-Item-1",
                    "Item Title: 8",
                    "Item Subtitle: 8",
                    "Assets/DarkGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group8));
            this.AllGroups.Add(group8);
            var group9 = new SampleDataGroup(this.frame, "Group-9",
                   "Group Title: 9",
                   "Group Subtitle: 9",
                   "Assets/DarkGray.png",
                   "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group9.Items.Add(new SampleDataItem(this.frame, "Group-9-Item-1",
                    "Item Title: 9",
                    "Item Subtitle: 9",
                    "Assets/DarkGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group9));
            this.AllGroups.Add(group9);
            var group10 = new SampleDataGroup(this.frame, "Group-10",
                   "Group Title: 10",
                   "Group Subtitle: 10",
                   "Assets/DarkGray.png",
                   "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group10.Items.Add(new SampleDataItem(this.frame, "Group-10-Item-1",
                    "Item Title: 10",
                    "Item Subtitle: 10",
                    "Assets/DarkGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group10));
            this.AllGroups.Add(group10);
            var group11 = new SampleDataGroup(this.frame, "Group-11",
                   "Group Title: 11",
                   "Group Subtitle: 11",
                   "Assets/DarkGray.png",
                   "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group11.Items.Add(new SampleDataItem(this.frame, "Group-11-Item-1",
                    "Item Title: 11",
                    "Item Subtitle: 11",
                    "Assets/DarkGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group11));
            this.AllGroups.Add(group11);

            var group12 = new SampleDataGroup(this.frame, "Group-12",
                   "Group Title: 12",
                   "Group Subtitle: 12",
                   "Assets/DarkGray.png",
                   "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group12.Items.Add(new SampleDataItem(this.frame, "Group-12-Item-1",
                    "Item Title: 12",
                    "Item Subtitle: 12",
                    "Assets/DarkGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group12));
            this.AllGroups.Add(group12);

            var group13 = new SampleDataGroup(this.frame, "Group-13",
                   "Group Title: 13",
                   "Group Subtitle: 13",
                   "Assets/DarkGray.png",
                   "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group13.Items.Add(new SampleDataItem(this.frame, "Group-13-Item-1",
                    "Item Title: 13",
                    "Item Subtitle: 13",
                    "Assets/DarkGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group13));
            this.AllGroups.Add(group13);

            var group14 = new SampleDataGroup(this.frame, "Group-14",
                   "Group Title: 14",
                   "Group Subtitle: 14",
                   "Assets/DarkGray.png",
                   "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");
            group14.Items.Add(new SampleDataItem(this.frame, "Group-14-Item-1",
                    "Item Title: 14",
                    "Item Subtitle: 14",
                    "Assets/DarkGray.png",
                    "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                    ITEM_CONTENT,
                    group14));
            this.AllGroups.Add(group14);

            ShowCommand = new DelegateCommand(x => true, x => this.Show());
        }
Ejemplo n.º 3
0
        private async Task GetSampleDataAsync()
        {
            if (this._groups.Count != 0)
                return;

            Uri dataUri = new Uri("ms-appx:///DataModel/SampleData.json");

            StorageFile file = await StorageFile.GetFileFromApplicationUriAsync(dataUri);
            string jsonText = await FileIO.ReadTextAsync(file);
            JsonObject jsonObject = JsonObject.Parse(jsonText);
            JsonArray jsonArray = jsonObject["Groups"].GetArray();

            foreach (JsonValue groupValue in jsonArray)
            {
                JsonObject groupObject = groupValue.GetObject();
                SampleDataGroup group = new SampleDataGroup(groupObject["UniqueId"].GetString(),
                                                            groupObject["Title"].GetString(),
                                                            groupObject["Subtitle"].GetString(),
                                                            groupObject["ImagePath"].GetString(),
                                                            groupObject["Description"].GetString());

                foreach (JsonValue itemValue in groupObject["Items"].GetArray())
                {
                    JsonObject itemObject = itemValue.GetObject();
                    group.Items.Add(new SampleDataItem(itemObject["UniqueId"].GetString(),
                                                       itemObject["Title"].GetString(),
                                                       itemObject["Subtitle"].GetString(),
                                                       itemObject["ImagePath"].GetString(),
                                                       itemObject["Description"].GetString(),
                                                       itemObject["Content"].GetString()));
                }
                this.Groups.Add(group);
            }
        }
        public SampleDataSource()
        {
            String ITEM_CONTENT = String.Format("Item Content: {0}\n\n{0}\n\n{0}\n\n{0}\n\n{0}\n\n{0}\n\n{0}",
                        "?");

            var group1 = new SampleDataGroup("1",
                    "所有旅行的書",
                    "一覽,目前流浪等待浪漫的所有書籍。",
                    "Assets/AllBooks.png",
                    "no use :(");
            group1.Items.Add(new SampleDataItem("1-1",
                    "書名",
                    "作者/書的資料",
                    "Assets/LightGray.png",
                    "多行簡介",
                    "超多字的內文~~~在這裡~~~吼吼吼",
                    group1));
            this.AllGroups.Add(group1);

            var group2 = new SampleDataGroup("2",
                    "我家書櫃",
                    "您的書想旅行嗎?",
                    "Assets/MyBooks.png",
                    "no use :(");
            group2.Items.Add(new SampleDataItem("2-1",
                    "我有新的書想旅行!",
                    "新增成員進書櫃",
                    "Assets/MediumGray.png",
                    "請輸入書名、作者、書況等各種資料",
                    "啦啦啦",
                    group2));
            group2.Items.Add(new SampleDataItem("2-2",
                    "樓下的房客",
                    "一行說明",
                    "Assets/MediumGray.png",
                    "多行說明",
                    "好多內文在這裡",
                    group2));

            this.AllGroups.Add(group2);

            var group3 = new SampleDataGroup("3",
                    "旅行的初衷",
                    "旅行和夢想都是無遠弗屆的!",
                    "Assets/Idea.png",
                    "here no use :P");
            group3.Items.Add(new SampleDataItem("3-1",
                    "初衷 - 起點",
                    "旅行的最開始的理念",
                    "Assets/DarkGray.png",
                    "旅行,有一個起點,帶著期望,等待邂逅。",
                    "在這個電子化的世代,你還理解書籍的本質嗎?\n再也不看的書是否已經逐漸淪為丟也不捨、留也無用的遺憾?\n\n讓你的夢想和書一同往世界的各個角落去吧!\n地球不如以往健康的環境,正需要我們重視森林和大氣的重要性,\n書本的重要性正因為電子化逐漸下滑,書不再需要被出版,\n這是我們體諒環境的方式,也是忘卻紙張觸感的遺憾,\n那些你再也不翻,卻又捨不得丟棄的書,請讓我們賦予他旅行的義務,\n\n帶著一份體諒在另外一個人手上復活。\n以交換的方式,重新珍惜書籍。\n\n\n由四個愛看書的女孩子共同研究開發,\n與其讓你的櫃子裡的書沾滿灰塵,不如就夾張漂亮的書籤,\n將這本書曾經帶給你的感動,旅行到下一個愛書人士的心理吧!\n\n\n",
                    group3));
            group3.Items.Add(new SampleDataItem("3-2",
                    "旅行的機票",
                    "如何讓你的書去旅行?幫他訂張機票吧!",
                    "Assets/DarkGray.png",
                    "旅行的方式有很多種,請讓我為您敘述其中奧妙!",
                    "【行前說明會】\n我們訂作這個個平台,\n讓你可以更新自己擁有的書籍、\n搜尋他人擁有的書籍\n或搜尋所在地附近有何種書籍,\n\n並且附上書評和推薦度,\n讓不常看書的你,可以透過大眾的評價謹慎選擇適合自己的讀物,\n而書籍狂熱者的你,可以為你所愛的類別撰寫,邂逅身處他方的同好。\n\n\n【注意事項】\n這是一個基於交流、捐獻二手書而成立的平台!\n\n01. 以捐贈為主。可自由做協議,需取得共識。\n02. 請對自己的二手書負責!將摺痕和汙損確實寫明!\n03. 約定交換請不要隨意變更,本系統設有黑名單。\n04.\n05.\n06.\n\n\n",
                    group3));
            group3.Items.Add(new SampleDataItem("3-3",
                    "以自由為主的行程表",
                    "旅行即將開始,你準備好了嗎?",
                    "Assets/DarkGray.png",
                    "讓我一一為你說明!",
                    "【我家書櫃】\n由此處新增你擁有的書籍,你家的書出去旅行的各個停駐點,都會更新在此處。\n\n\n【所有旅行的書】\n平台上所有的書籍都在這裡,\n誰更新了書籍?目前有多少書?\n通通都會在這裡即時顯示,\n你可以從這裡挑選喜歡的書目,進而去詢問這本書目前旅行到哪裡?\n\n\n【尋找旅行中的書!】\n在外旅行,突然有點想看看附近的書,\n這邊可以幫你搜尋喔!\n\n\n",
                    group3));
            group3.Items.Add(new SampleDataItem("3-4",
                    "個人資料設定",
                    "旅行是隨興的,但希望各位行事順利!",
                    "Assets/DarkGray.png",
                    "為了讓你的書旅行順利,這邊需要部分聯繫資料唷",
                    "【暱稱】\n【信箱】\n【個人書庫位置】\n\n\n",
                    group3));
            this.AllGroups.Add(group3);

            var group4 = new SampleDataGroup("4",
                    "尋找旅行中的書!",
                    "究竟有多少書等著你的邂逅呢?:P",
                    "Assets/Search.png",
                    "here no use :P");
            group4.Items.Add(new SampleDataItem("4-1",
                    "這裡有旅行書嗎?",
                    "看看身邊,有多少書等著呢!",
                    "Assets/DarkGray.png",
                    "用地圖定位,搜尋附近有哪些書籍在等待邂逅呢?",
                    "等待更新\n\n",
                    group4));
            group4.Items.Add(new SampleDataItem("4-2",
                    "問題回報",
                    "您好,有以下問題這邊可以回報!",
                    "Assets/LightGray.png",
                    "我們將盡快為你處理:)",
                    "【有以下狀況請回報給我們,讓系統改善的更加好用:D】\n01. 無法遵守旅行約定者。\n02. 書籍多處損壞無據實以報。\n03.出言不遜、態度惡劣者。\n04.資料錯誤\n05.系統問題\n06.\n\n\n",
                    group4));

            this.AllGroups.Add(group4);
        }
        public SampleDataItem(Frame frame, String uniqueId, String title, String subtitle, String imagePath, String description, String content, SampleDataGroup group)
            : base(uniqueId, title, subtitle, imagePath, description)
        {
            this.frame = frame;

            this._content = content;
            this._group = group;

            NavigateItemCommand = new DelegateCommand(x => true, x => this.NavigateItem(x));
        }
 public SampleDataItem(String uniqueId, String title, String subtitle, String imagePath, String description, String content, SampleDataGroup group)
     : base(uniqueId, title, subtitle, imagePath, description)
 {
     this._content = content;
     this._group = group;
 }
Ejemplo n.º 7
0
        public SampleDataSource()
        {
            String ApHpRunes = "Masteries are 21/0/9.\nGreat Mark of Magic Penetration for reds.\nGreater Seal of Scaling Health for yellows.\nGreater Glyph of Scaling Ability Power for blues.\nGreater Quintessence of Ability Power for quints.\nIf you wish yellows can be switched out for mana regeneration and blues for magic resist if you feel like the lane will be tough.";
            String ADCRunes =
                "Masteries are 21/9/0.\nRune set up is Greater Mark of Attack Damage for reds.\nGreater Seal of Armor for yellow\nGreater Glypg of Scaling Magic Resist for blues.\nGreater Quintessence of Attack Damage for quints.";
            String Olaf =
                "Masteries are 9/21/0.\n7 Greater Mark of Armor Penetration and 2 Greater Mark of Attack Damage for reds.\nGreater Seal of Armor for yellows.\nGreater Glyph of Magic Resist for blues. Greater Quintessence of Attack Damage for quints.";
            String ApMana =
                "Masteries are 21/0/9.\nGreater Mark of Insight for reds.\nGreater Seal of Replenishment for yellows.\nGreater Glyph of Warding for blues.\nGreater Quintessence of Ability Power for quints";
            String FlashIgnite = "Flash and Ignite are the optimal choices";
            String FlashSmite = "Flash and Smite are the optimal choices";

            String ApHpMSRunes = "Masteries are 21/0/9.\nGreat Mark of Magic Penetration for reds.\nGreater Seal of Scaling Health for yellows.\nGreater Glyph of Scaling Ability Power for blues.\nGreater Quintessence of Swiftness for quints.";
            String ArmorMS = "Masteries are 0/21/9.\nGreat Mark of Magic Penetration for reds.\nGreater Seal of Armor for yellows.\nGreater Glyph of Magic Resist for blues.\nGreater Quintessence of Swiftness for quints.";

            var group1 = new SampleDataGroup("Group-1",
                    "Gragas",
                    "Mid Lane",
                    "Assets/gragas.png",
                    "Group Description: ");
            group1.Items.Add(new SampleDataItem("Group-1-Item-1",
                    "Runes, Masteries and Summoner Spells",
                    "",
                    "Assets/Ignite.png",
                    FlashIgnite,
                    ApHpRunes,
                    group1));
            group1.Items.Add(new SampleDataItem("Group-1-Item-2",
                    "Items",
                    "",
                    "Assets/rabadons-deathcap.png",
                    "Recommended Build Order",
                    "1. Boots+ 3 pots \n" +
                    "2. Dorans Ring x2\n" +
                    "3. Haunting Guise\n" +
                    "4. Death Cap\n" +
                    "5. Zhonya's Hourglass\n" +
                    "6. Void Staff\n" +
                    "7. Upgrade Haunting Guise to Liandry\n" +
                    "8. Sell Dorans for either more damage or GA\n",
                    group1));
            group1.Items.Add(new SampleDataItem("Group-1-Item-3",
                   "Counter Picks",
                    "",
                    "Assets/akali.png",
                    "Counters",
                    "Brand, Akali, and Fizz counter Gragas well.",
                    group1));

            this.AllGroups.Add(group1);

            var group2 = new SampleDataGroup("Group-2",
                     "Tristana",
                     "AD Carry Bot Lane",
                     "Assets/tristana.jpg",
                     "Group Description: ");
            group2.Items.Add(new SampleDataItem("Group-2-Item-1",
                    "Runes, Masteries and Summoner Spells",
                    "",
                    "Assets/Ignite.png",
                    "Flash and ignite are the optimal choices. Ignite can be swapped out for Heal or Cleanse.",
                    ADCRunes,
                    group2));
            group2.Items.Add(new SampleDataItem("Group-2-Item-2",
                    "Items",
                    "",
                    "Assets/Infinity_Edge.jpg",
                    "Recommended Build Order",
                    "1. Boots+ 3 pots \n" +
                    "2.(First Back): Dorans Ring + Vampiric Scepter\n" +
                    "3. Infinity Edge\n" +
                    "4. Phantom Dancer\n" +
                    "5. Last Whisper\n" +
                    "6. Quicksilver Sash\n" +
                    "7. Bloodthrister\n" +
                    "8. Upgrade QSS\n" +
                    "9. Sell Dorans for GA",

                    group2));
            group2.Items.Add(new SampleDataItem("Group-2-Item-3",
                   "Counter Picks",
                    "",
                    "Assets/mf.jpg",
                    "Counters",
                    "Miss Fortune, Caitlyn, and Sivir counter Tristana early.",
                    group2));
            this.AllGroups.Add(group2);

            var group3 = new SampleDataGroup("Group-3",
                "Olaf",
                "Top Lane Bruiser",
                "Assets/olaf.jpg",
                "Group Description: ");
            group3.Items.Add(new SampleDataItem("Group-3-Item-1",
                    "Runes, Masteries and Summoner Spells",
                    "",
                    "Assets/teleport.jpg",
                    "Ghost and Teleport should be used for top lane. You can switch out Ignite for Teleport if you want more early kill pressure.",
                    Olaf,
                    group3));
            group3.Items.Add(new SampleDataItem("Group-3-Item-2",
                    "Items",
                    "",
                    "Assets/warmogs-armor.png",
                    "Recommended Build Order",
                    "1. Boots+ 3 pots \n" +
                    "2.(First Back): Dorans Bladex2 OR Phage OR Brutalizer\n" +
                    "3. Shurelias\n" +
                    "4. Black Cleaver\n" +
                    "5. Warmogs\n" +
                    "6. Frozen Mallet\n" +
                    "7. Randuins\n" +
                    "8. Maw of Malmortius\n" +
                    "9. Sell Dorans for GA",

                    group3));
            group3.Items.Add(new SampleDataItem("Group-3-Item-3",
                   "Counter Picks",
                    "",
                    "Assets/darius.jpg",
                    "Counters",
                    "Olaf is hard to beat in lane. Darius and Riven put up tougher matchups.",
                    group3));
            this.AllGroups.Add(group3);

            var group4 = new SampleDataGroup("Group-4",
                      "Lee Sin",
                      "Jungle",
                      "Assets/leesin.jpg",
                      "Group Description: ");
            group4.Items.Add(new SampleDataItem("Group-4-Item-1",
                    "Runes, Masteries and Summoner Spells",
                    "",
                    "Assets/smite.jpg",
                    "Smite and Flash are standard. Can swap out flash for exhaust if desired.",
                    Olaf,
                    group4));
            group4.Items.Add(new SampleDataItem("Group-4-Item-2",
                    "Items",
                    "",
                    "Assets/wriggles.png",
                    "Recommended Build Order",
                    "1. Hunter's Machete+ 5 pots \n" +
                    "2. Wriggle's Lantern\n" +
                    "3. Randuins\n" +
                    "4. Black Cleaver\n" +
                    "5. Frozen Mallet\n" +
                    "6. Maw of Malmortius\n" +
                    "7. Black Cleaver\n" +
                    "8. GA\n",

                    group4));
            group4.Items.Add(new SampleDataItem("Group-4-Item-3",
                   "Counter Picks",
                    "",
                    "Assets/riven.png",
                    "Counters",
                    "Lee Sin is a very strong duelist. Played correctly he can win almost all 1v1s. Riven does give him a hard time though.",
                    group4));
            this.AllGroups.Add(group4);

            var group5 = new SampleDataGroup("Group-5",
                        "Orianna",
                        "Mid Lane",
                        "Assets/orianna.jpg",
                        "Group Description: ");
            group5.Items.Add(new SampleDataItem("Group-5-Item-1",
                    "Runes, Masteries and Summoner Spells",
                    "",
                    "Assets/Ignite.png",
                    FlashIgnite,
                    ApMana,
                    group5));
            group5.Items.Add(new SampleDataItem("Group-5-Item-2",
                    "Items",
                    "",
                    "Assets/athenes.png",
                    "Recommended Build Order",
                    "1. Boots + 3 pots \n" +
                    "2. Athene's Unholy Grail\n" +
                    "3. Rabadon's Deathcap\n" +
                    "4. Haunting Guise\n" +
                    "5. Void Staff\n" +
                    "6. Zhonya's Hourglass\n" +
                    "7. Upgrade Haunting Guise to Liandry's Torment\n",

                    group5));
            group5.Items.Add(new SampleDataItem("Group-5-Item-3",
                   "Counter Picks",
                    "",
                    "Assets/kassadin.png",
                    "Counters",
                    "Kassadin, Cassiopeia, Leblanc, and Ahri are all good counters to Orianna",
                    group5));
            this.AllGroups.Add(group5);

            var group6 = new SampleDataGroup("Group-6",
              "Nunu",
              "Support",
              "Assets/nunuf.jpg",
              "Group Description: ");
            group6.Items.Add(new SampleDataItem("Group-6-Item-1",
                    "Runes, Masteries and Summoner Spells",
                    "",
                    "Assets/exhaust.png",
                    "Flash and Exhaust are standard. Can also go with Flash and Heal.",
                    "For Masteries go 1/12/17.\nGreater Mark of Resilience on reds.\nGreater Seal of Avarice on yellows.\nGreater Glyph of Warding on blues.\nGreater Quintessence of Avarice on quints.",
                    group6));
            group6.Items.Add(new SampleDataItem("Group-6-Item-2",
                    "Items",
                    "",
                    "Assets/aegis.png",
                    "Recommended Build Order",
                    "1. Boots + wards \n" +
                    "2. Sightstone\n" +
                    "3. Shurelias\n" +
                    "4. Aegis\n" +
                    "5. Zeke's Herald\n" +
                    "6. Locket of Iron Solari\n" +
                    "7. Kage's Last Breath\n",

                    group6));
            group6.Items.Add(new SampleDataItem("Group-6-Item-3",
                   "Counter Picks",
                    "",
                    "Assets/soraka.jpg",
                    "Counters",
                    "Soraka, Sona, Janna and Sivir",
                    group6));
            this.AllGroups.Add(group6);

            var group7 = new SampleDataGroup("Group-7",
                      "Ziggs",
                      "Mid Lane",
                      "Assets/Ziggs.jpg",
                      "Group Description: ");
            group7.Items.Add(new SampleDataItem("Group-7-Item-1",
                    "Runes, Masteries and Summoner Spells",
                    "",
                    "Assets/Ignite.png",
                    FlashIgnite,
                    ApMana,
                    group7));
            group7.Items.Add(new SampleDataItem("Group-7-Item-2",
                    "Items",
                    "",
                    "Assets/athenes.png",
                    "Recommended Build Order",
                    "1. Boots + 3 pots \n" +
                    "2. Dorans Ringx2\n" +
                    "3. Athene's Unholy Grail\n" +
                    "4. Rabadon's Deathcap\n" +
                    "5. Rylai's Crystal Scepter\n" +
                    "6. Void Staff\n" +
                    "7. Zhonya's Hourglass\n",

                    group7));
            group7.Items.Add(new SampleDataItem("Group-7-Item-3",
                   "Counter Picks",
                    "",
                    "Assets/ahri.png",
                    "Counters",
                    "Kassadin, Leblanc, and Ahri",
                    group7));
            this.AllGroups.Add(group7);

            var group8 = new SampleDataGroup("Group-8",
                     "Twisted Fate",
                     "Mid Lane",
                     "Assets/tf.jpg",
                     "Group Description: ");
            group8.Items.Add(new SampleDataItem("Group-8-Item-1",
                    "Runes, Masteries and Summoner Spells",
                    "",
                    "Assets/Ignite.png",
                    FlashIgnite,
                    ApHpMSRunes,
                    group8));
            group8.Items.Add(new SampleDataItem("Group-8-Item-2",
                    "Items",
                    "",
                    "Assets/lich.png",
                    "Recommended Build Order",
                    "1. Cystalline Flak + HP potx2 + Mana pot \n" +
                    "2. Dorans Ringx2\n" +
                    "3. Lich Bane\n" +
                    "4. Rabadon's Deathcap\n" +
                    "5. Zhonya's Hourglass\n" +
                    "6. Void Staff\n" +
                    "7. Guardian Angel\n",

                    group8));
            group8.Items.Add(new SampleDataItem("Group-8-Item-3",
                   "Counter Picks",
                    "",
                    "Assets/lb.png",
                    "Counters",
                    "Kassadin, Leblanc, and Talon are all good counters to Twisted Fate.\nAlso, when TF leaves lane with ult, push to his tower to make him xp and cs.",
                    group8));
            this.AllGroups.Add(group8);

            var group9 = new SampleDataGroup("Group-9",
                    "Amumu",
                    "Jungle",
                    "Assets/mummy.jpg",
                    "Group Description: ");
            group9.Items.Add(new SampleDataItem("Group-9-Item-1",
                    "Runes, Masteries and Summoner Spells",
                    "",
                    "Assets/smite.jpg",
                    FlashSmite,
                    ArmorMS,
                    group9));
            group9.Items.Add(new SampleDataItem("Group-9-Item-2",
                    "Items",
                    "",
                    "Assets/sunfire.png",
                    "Recommended Build Order",
                    "1. Hunter's Machete + HP potsx5\n" +
                    "2. Spirit Stone + Boots\n" +
                    "3. Sunfire Cape\n" +
                    "4. Abyssal Scepter\n" +
                    "5. Frozen Heart\n" +
                    "6. Randuin's Omen\n" +
                    "7. Zhonya's Hourglass\n",

                    group9));
            group9.Items.Add(new SampleDataItem("Group-9-Item-3",
                   "Counter Picks",
                    "",
                    "Assets/mundo.png",
                    "Counters",
                    "Dr. Mundo, Lee Sin, Nocturne.\nInvade his blue level 1.",
                    group9));
            this.AllGroups.Add(group9);
        }
Ejemplo n.º 8
0
        public SampleDataSource()
        {
            String ITEM_CONTENT = String.Format("Item Content: {0}\n\n{0}\n\n{0}\n\n{0}\n\n{0}\n\n{0}\n\n{0}",
                                                "Curabitur class aliquam vestibulum nam curae maecenas sed integer cras phasellus suspendisse quisque donec dis praesent accumsan bibendum pellentesque condimentum adipiscing etiam consequat vivamus dictumst aliquam duis convallis scelerisque est parturient ullamcorper aliquet fusce suspendisse nunc hac eleifend amet blandit facilisi condimentum commodo scelerisque faucibus aenean ullamcorper ante mauris dignissim consectetuer nullam lorem vestibulum habitant conubia elementum pellentesque morbi facilisis arcu sollicitudin diam cubilia aptent vestibulum auctor eget dapibus pellentesque inceptos leo egestas interdum nulla consectetuer suspendisse adipiscing pellentesque proin lobortis sollicitudin augue elit mus congue fermentum parturient fringilla euismod feugiat");

            var group1 = new SampleDataGroup("Group-1",
                                             "Group Title: 1",
                                             "Group Subtitle: 1",
                                             "Assets/DarkGray.png",
                                             "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");

            group1.Items.Add(new SampleDataItem("Group-1-Item-1",
                                                "Item Title: 1",
                                                "Item Subtitle: 1",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group1));
            group1.Items.Add(new SampleDataItem("Group-1-Item-2",
                                                "Item Title: 2",
                                                "Item Subtitle: 2",
                                                "Assets/DarkGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group1));
            group1.Items.Add(new SampleDataItem("Group-1-Item-3",
                                                "Item Title: 3",
                                                "Item Subtitle: 3",
                                                "Assets/MediumGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group1));
            group1.Items.Add(new SampleDataItem("Group-1-Item-4",
                                                "Item Title: 4",
                                                "Item Subtitle: 4",
                                                "Assets/DarkGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group1));
            group1.Items.Add(new SampleDataItem("Group-1-Item-5",
                                                "Item Title: 5",
                                                "Item Subtitle: 5",
                                                "Assets/MediumGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group1));
            this.AllGroups.Add(group1);

            var group2 = new SampleDataGroup("Group-2",
                                             "Group Title: 2",
                                             "Group Subtitle: 2",
                                             "Assets/LightGray.png",
                                             "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");

            group2.Items.Add(new SampleDataItem("Group-2-Item-1",
                                                "Item Title: 1",
                                                "Item Subtitle: 1",
                                                "Assets/DarkGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group2));
            group2.Items.Add(new SampleDataItem("Group-2-Item-2",
                                                "Item Title: 2",
                                                "Item Subtitle: 2",
                                                "Assets/MediumGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group2));
            group2.Items.Add(new SampleDataItem("Group-2-Item-3",
                                                "Item Title: 3",
                                                "Item Subtitle: 3",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group2));
            this.AllGroups.Add(group2);

            var group3 = new SampleDataGroup("Group-3",
                                             "Group Title: 3",
                                             "Group Subtitle: 3",
                                             "Assets/MediumGray.png",
                                             "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");

            group3.Items.Add(new SampleDataItem("Group-3-Item-1",
                                                "Item Title: 1",
                                                "Item Subtitle: 1",
                                                "Assets/MediumGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group3));
            group3.Items.Add(new SampleDataItem("Group-3-Item-2",
                                                "Item Title: 2",
                                                "Item Subtitle: 2",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group3));
            group3.Items.Add(new SampleDataItem("Group-3-Item-3",
                                                "Item Title: 3",
                                                "Item Subtitle: 3",
                                                "Assets/DarkGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group3));
            group3.Items.Add(new SampleDataItem("Group-3-Item-4",
                                                "Item Title: 4",
                                                "Item Subtitle: 4",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group3));
            group3.Items.Add(new SampleDataItem("Group-3-Item-5",
                                                "Item Title: 5",
                                                "Item Subtitle: 5",
                                                "Assets/MediumGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group3));
            group3.Items.Add(new SampleDataItem("Group-3-Item-6",
                                                "Item Title: 6",
                                                "Item Subtitle: 6",
                                                "Assets/DarkGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group3));
            group3.Items.Add(new SampleDataItem("Group-3-Item-7",
                                                "Item Title: 7",
                                                "Item Subtitle: 7",
                                                "Assets/MediumGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group3));
            this.AllGroups.Add(group3);

            var group4 = new SampleDataGroup("Group-4",
                                             "Group Title: 4",
                                             "Group Subtitle: 4",
                                             "Assets/LightGray.png",
                                             "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");

            group4.Items.Add(new SampleDataItem("Group-4-Item-1",
                                                "Item Title: 1",
                                                "Item Subtitle: 1",
                                                "Assets/DarkGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group4));
            group4.Items.Add(new SampleDataItem("Group-4-Item-2",
                                                "Item Title: 2",
                                                "Item Subtitle: 2",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group4));
            group4.Items.Add(new SampleDataItem("Group-4-Item-3",
                                                "Item Title: 3",
                                                "Item Subtitle: 3",
                                                "Assets/DarkGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group4));
            group4.Items.Add(new SampleDataItem("Group-4-Item-4",
                                                "Item Title: 4",
                                                "Item Subtitle: 4",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group4));
            group4.Items.Add(new SampleDataItem("Group-4-Item-5",
                                                "Item Title: 5",
                                                "Item Subtitle: 5",
                                                "Assets/MediumGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group4));
            group4.Items.Add(new SampleDataItem("Group-4-Item-6",
                                                "Item Title: 6",
                                                "Item Subtitle: 6",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group4));
            this.AllGroups.Add(group4);

            var group5 = new SampleDataGroup("Group-5",
                                             "Group Title: 5",
                                             "Group Subtitle: 5",
                                             "Assets/MediumGray.png",
                                             "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");

            group5.Items.Add(new SampleDataItem("Group-5-Item-1",
                                                "Item Title: 1",
                                                "Item Subtitle: 1",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group5));
            group5.Items.Add(new SampleDataItem("Group-5-Item-2",
                                                "Item Title: 2",
                                                "Item Subtitle: 2",
                                                "Assets/DarkGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group5));
            group5.Items.Add(new SampleDataItem("Group-5-Item-3",
                                                "Item Title: 3",
                                                "Item Subtitle: 3",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group5));
            group5.Items.Add(new SampleDataItem("Group-5-Item-4",
                                                "Item Title: 4",
                                                "Item Subtitle: 4",
                                                "Assets/MediumGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group5));
            this.AllGroups.Add(group5);

            var group6 = new SampleDataGroup("Group-6",
                                             "Group Title: 6",
                                             "Group Subtitle: 6",
                                             "Assets/DarkGray.png",
                                             "Group Description: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vivamus tempor scelerisque lorem in vehicula. Aliquam tincidunt, lacus ut sagittis tristique, turpis massa volutpat augue, eu rutrum ligula ante a ante");

            group6.Items.Add(new SampleDataItem("Group-6-Item-1",
                                                "Item Title: 1",
                                                "Item Subtitle: 1",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group6));
            group6.Items.Add(new SampleDataItem("Group-6-Item-2",
                                                "Item Title: 2",
                                                "Item Subtitle: 2",
                                                "Assets/DarkGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group6));
            group6.Items.Add(new SampleDataItem("Group-6-Item-3",
                                                "Item Title: 3",
                                                "Item Subtitle: 3",
                                                "Assets/MediumGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group6));
            group6.Items.Add(new SampleDataItem("Group-6-Item-4",
                                                "Item Title: 4",
                                                "Item Subtitle: 4",
                                                "Assets/DarkGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group6));
            group6.Items.Add(new SampleDataItem("Group-6-Item-5",
                                                "Item Title: 5",
                                                "Item Subtitle: 5",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group6));
            group6.Items.Add(new SampleDataItem("Group-6-Item-6",
                                                "Item Title: 6",
                                                "Item Subtitle: 6",
                                                "Assets/MediumGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group6));
            group6.Items.Add(new SampleDataItem("Group-6-Item-7",
                                                "Item Title: 7",
                                                "Item Subtitle: 7",
                                                "Assets/DarkGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group6));
            group6.Items.Add(new SampleDataItem("Group-6-Item-8",
                                                "Item Title: 8",
                                                "Item Subtitle: 8",
                                                "Assets/LightGray.png",
                                                "Item Description: Pellentesque porta, mauris quis interdum vehicula, urna sapien ultrices velit, nec venenatis dui odio in augue. Cras posuere, enim a cursus convallis, neque turpis malesuada erat, ut adipiscing neque tortor ac erat.",
                                                ITEM_CONTENT,
                                                group6));
            this.AllGroups.Add(group6);
        }
Ejemplo n.º 9
0
 public SampleDataItem(String uniqueId, String title, String subtitle, String imagePath, String description, String content, SampleDataGroup group)
     : base(uniqueId, title, subtitle, imagePath, description)
 {
     this._content = content;
     this._group   = group;
 }
Ejemplo n.º 10
0
        //this also makes the group


        //make general parsers for justin.tv, youtube, etc...
        //all parsers should made a new group for each entity
        // also needed is a way to serialize and save to settings the list of current subscriptions

        public static async Task addOfficeCamarchives()
        {
        
            string url = "http://api.justin.tv/api/channel/archives/riotgames.json?limit=20";


            JsonArray json = await GetArrayAsync(url);
            

            SampleDataGroup archives = new SampleDataGroup("Officecam", "Office cam", "I hope this isn't creepy", "Assets/MediumGray.png", "");
            //SampleDataGroup archives = makeJustinGroupByName(name);

            foreach (var x in json){
                var y = x.GetObject();
                string unique_id = y.GetNamedString("id");
                string title = y.GetNamedString("title");
                //string subtitle = y.GetNamedString("stream_name");
                
                string imagepath = y.GetNamedString("image_url_medium");
                string content = "http://www.twitch.tv/" + "officecam" + "/b/" + y.GetNamedString("id");
                string videourl = y.GetNamedString("video_file_url");
                SampleDataItem newvideo = new SampleDataItem(unique_id, title, "", imagepath, videourl, content, archives);
                archives.Items.Add(newvideo);
            }                                                                    
            
            //SampleDataSource._sampleDataSource._allGroups.Clear();
            SampleDataSource._sampleDataSource._allGroups.Insert(0,archives);



        }