Example #1
0
 public void SetAllProp(WebObject.Base MasterObject, List <FieldInfo> PropList)
 {
     FieldInfo[] CSSProps = this.GetType().GetFields();
     foreach (FieldInfo LocalProp in PropList)
     {
         CSSProps[PropList.IndexOf(LocalProp)].SetValue(this, LocalProp.GetValue(MasterObject.CSS));
     }
 }
Example #2
0
        public string GetEmbemdedCSS(WebObject.Base ClassObject)
        {
            string CompiledCSS = "";

            FieldInfo[] CSSProps = this.GetType().GetFields();
            foreach (FieldInfo CSSProp in CSSProps)
            {
                if (CSSProp.GetValue(this).ToString() != "")
                {
                    if (ClassObject.CSS.GetPropValue(CSSProp.Name) != CSSProp.GetValue(this).ToString())
                    {
                        CompiledCSS += CSSProp.Name.Replace('_', '-') + ':' + CSSProp.GetValue(this) + ";";
                    }
                }
            }
            return(CompiledCSS);
        }
Example #3
0
 public void SetLangObjectValue(Type LangType, WebObject.Base CurrentObject, string PropName, string PropValue)
 {
     foreach (FieldInfo LocalProp in CurrentObject.GetType().GetRuntimeFields())
     {
         if (LocalProp.GetValue(CurrentObject).GetType() == LangType)
         {
             object LangObject = LocalProp.GetValue(CurrentObject);
             foreach (FieldInfo LocalLangProp in LangObject.GetType().GetRuntimeFields())
             {
                 if (LocalLangProp.Name == PropName)
                 {
                     LocalLangProp.SetValue(LangObject, PropValue);
                 }
             }
             LocalProp.SetValue(CurrentObject, LangObject);
         }
     }
 }
Example #4
0
 public string GetLangObjectValue(Type LangType, WebObject.Base CurrentObject, string PropName)
 {
     foreach (FieldInfo LocalProp in CurrentObject.GetType().GetRuntimeFields())
     {
         if (LocalProp.GetValue(CurrentObject).GetType() == LangType)
         {
             object LangObject = LocalProp.GetValue(CurrentObject);
             foreach (FieldInfo LocalLangProp in LangObject.GetType().GetRuntimeFields())
             {
                 if (LocalLangProp.Name == PropName)
                 {
                     LocalLangProp.GetValue(LangObject);
                     return(LocalLangProp.GetValue(LangObject).ToString());
                 }
             }
         }
     }
     return("error");
 }
Example #5
0
 public void SetAllProp(WebObject.Base MasterObject, List <FieldInfo> PropList)
 {
     FieldInfo[] HTMLProps = this.GetType().GetFields();
     foreach (FieldInfo LocalProp in PropList)
     {
         if (LocalProp.Name == "PropertiesValue")
         {
             string[] MasterPropValueList = (string[])LocalProp.GetValue(MasterObject.HTML);
             for (int i = 0; i < MasterPropValueList.Length; i++)
             {
                 this.PropertiesValue[i] = MasterPropValueList[i];
             }
         }
         else
         {
             HTMLProps[PropList.IndexOf(LocalProp)].SetValue(this, LocalProp.GetValue(MasterObject.HTML));
         }
     }
 }