Esempio n. 1
0
        public BaseReadBook(ReadBookInfo bookInfo, int pageCount, String title, String author, BaseBook sourceBook)
            : base(bookInfo.ItemID)
        {
            m_Background = bookInfo.BackgroundID;
            m_CustomArt  = bookInfo.CustomArt;
            m_BigBook    = bookInfo.BigBook;
            BookContent content = this.DefaultContent;

            if (sourceBook != null)
            {
                m_Author = sourceBook.Author;
                m_Title  = sourceBook.Title;
                m_Pages  = (BookPageInfo[])sourceBook.Pages.Clone();
                m_Full   = true;
            }
            else
            {
                if (content == null)
                {
                    m_Pages = new BookPageInfo[pageCount];
                    for (int i = 0; i < m_Pages.Length; ++i)
                    {
                        m_Pages[i] = new BookPageInfo();
                    }
                }
                else
                {
                    m_Title  = content.Title;
                    m_Author = content.Author;
                    m_Pages  = content.Copy();
                }
            }
            if (author != null)
            {
                m_Author = author;
            }
            if (title != null)
            {
                m_Title = title;
            }
            if ((author != null) && (title != null))
            {
                m_Full = true;
            }
            Weight = BookWeight;
        }
Esempio n. 2
0
 public BaseReadBook(ReadBookInfo bookInfo, int pageCount) : this(bookInfo, pageCount, null, null, null)
 {
 }
Esempio n. 3
0
 public BaseReadBook(ReadBookInfo bookInfo, String title, String author, int pageCount) : this(bookInfo, pageCount, title, author, null)
 {
 }
Esempio n. 4
0
 public BaseReadBook(ReadBookInfo bookInfo) : this(bookInfo, 20)
 {
 }
Esempio n. 5
0
        public BaseReadBook(ReadBookInfo bookInfo, int pageCount, String title, String author, BaseBook sourceBook)
            : base(bookInfo.ItemID)
        {
            m_Background = bookInfo.BackgroundID;
            m_CustomArt = bookInfo.CustomArt;
            m_BigBook = bookInfo.BigBook;
            BookContent content = this.DefaultContent;

            if (sourceBook != null)
            {
                m_Author = sourceBook.Author;
                m_Title = sourceBook.Title;
                m_Pages = (BookPageInfo[])sourceBook.Pages.Clone();
                m_Full = true;
            }
            else
            {
                if (content == null)
                {
                    m_Pages = new BookPageInfo[pageCount];
                    for (int i = 0; i < m_Pages.Length; ++i)
                        m_Pages[i] = new BookPageInfo();
                }
                else
                {
                    m_Title = content.Title;
                    m_Author = content.Author;
                    m_Pages = content.Copy();
                }                
                
            }
            if (author != null)
            {
                m_Author = author;
            }
            if (title != null)
            {
                m_Title = title;
            }
            if ((author != null) && (title != null))
            {
                m_Full = true;
            }
            Weight = BookWeight;
        }
Esempio n. 6
0
 public BaseReadBook(ReadBookInfo bookInfo, String title, String author, int pageCount) : this(bookInfo, pageCount, title, author, null) { }
Esempio n. 7
0
 public BaseReadBook(ReadBookInfo bookInfo, int pageCount) : this(bookInfo, pageCount, null, null, null) { }
Esempio n. 8
0
 public BaseReadBook(ReadBookInfo bookInfo) : this(bookInfo, 20) { }