Beispiel #1
0
        private void GetFavorised()
        {
            DoujinDataRow favRow = MainWindow.favs.FindBynHentaiID(this.nhentaiId);

            foreach (DoujinDataRow mainRow in MainWindow.dt)
            {
                if (mainRow.nHentaiID == favRow.nHentaiID)
                {
                    int id = mainRow.ID;
                    MainWindow.dt.RemoveDoujinDataRow(mainRow);
                    MainWindow.dt.AddDoujinDataRow(id, favRow.nHentaiID, favRow.mediaID, favRow.name, favRow.fullName, favRow.artist, favRow.character, favRow.parody, favRow.group, favRow.tags, favRow.language, favRow.favorite, favRow.pages, favRow.coverUrl, favRow.extension);
                }
            }
        }
Beispiel #2
0
        public static void AddDoujinDataRow(Doujin d, DoujinDataDataTable dt)
        {
            DoujinDataRow rowDoujinDataRow = ((DoujinDataRow)(dt.NewRow()));

            object[] columnValuesArray = new object[] {
                dt.Rows.Count,
                d.nhentaiId,
                d.mediaId,
                d.name,
                d.fullName,
                d.Artist(),
                d.Character(),
                d.Parody(),
                d.Group(),
                d.TagsConcat(),
                d.language,
                d.favorised,
                d.pageCount,
                d.coverUrl,
                d.coverExt
            };
            rowDoujinDataRow.ItemArray = columnValuesArray;
            dt.Rows.Add(rowDoujinDataRow);
        }
Beispiel #3
0
 public static Doujin DataRowToDoujin(DoujinDataRow row)
 {
     return(new Doujin(row.ID, row.nHentaiID, row.mediaID, row.pages, row.name, row.fullName, row.extension, row.extension, row.language, row.favorite, row.coverUrl));
 }