示例#1
0
        public string GetReviewPageText(long idPage, int v)
        {
            if (Reviews == null)
            {
                return(null);
            }
            if (!Reviews.Pages.ContainsKey(idPage))
            {
                return(null);
            }
            ReviewPage rp = Reviews.Pages[idPage];

            return(v == 0 ? rp.PageTitle : rp.PageHelp);
        }
示例#2
0
        public string GetReviewText(long idPage, long idControl)
        {
            if (Reviews == null)
            {
                return(null);
            }
            if (!Reviews.Pages.ContainsKey(idPage))
            {
                return(null);
            }
            ReviewPage rp = Reviews.Pages[idPage];

            if (!rp.Items.ContainsKey(idControl))
            {
                return(null);
            }
            ReviewItem ri = rp.Items[idControl];

            return(ri.ItemText);
        }
示例#3
0
 public void LoadFromXml(XmlDocument doc)
 {
     foreach (XmlElement e in doc.ChildNodes)
     {
         if (e.Name.Equals("doc"))
         {
             foreach (XmlElement ef in e.ChildNodes)
             {
                 if (ef.Name.Equals("notes"))
                 {
                     BookNotes = ef.InnerText;
                 }
                 else if (ef.Name.Equals("page"))
                 {
                     ReviewPage rp = new ReviewPage();
                     rp.Load(ef);
                     Pages[int.Parse(ef.GetAttribute("id"))] = rp;
                 }
             }
         }
     }
 }