Пример #1
0
        protected Theme(Portal portal, IConfigSectionNode conf)
        {
            m_Portal = portal;
              m_Name = conf.AttrByName(Configuration.CONFIG_NAME_ATTR).Value;
              if (m_Name.IsNullOrWhiteSpace())
               throw new WaveException(StringConsts.CONFIG_PORTAL_THEME_NO_NAME_ERROR.Args(portal.Name));

              m_Description = conf.AttrByName(Portal.CONFIG_DESCR_ATTR).ValueAsString(m_Name);
              m_Default = conf.AttrByName(Portal.CONFIG_DEFAULT_ATTR).ValueAsBool(false);

              ConfigAttribute.Apply(this, conf);
        }
Пример #2
0
 /// <summary>
 /// DEVELOPERS do not use!
 /// A hack method needed in some VERY RARE cases, like serving an error page form the filter which is out of portal scope.
 /// </summary>
 public void ___InternalInjectPortal(Portal portal = null,
     Theme theme = null,
     WorkMatch match = null,
     JSONDataMap matchedVars = null)
 {
     m_Portal = portal;
                                              m_PortalTheme = theme;
                                              m_PortalMatch = match;
                                              m_PortalMatchedVars = matchedVars;
 }