public static byte?GetNonCompiledEnumProp(byte styleAttributeRplId, StyleAttributeNames styleAttributeName, Style style, StyleInstance styleIntance) { if (style == null) { return(null); } ReportProperty reportProperty = ((StyleBase)style)[styleAttributeName]; if (reportProperty == null) { return(null); } if (reportProperty.IsExpression) { if (styleIntance != null) { object obj = ((StyleBaseInstance)styleIntance)[styleAttributeName]; if (obj != null) { bool flag = false; return(PageItem.GetStylePropByte(styleAttributeRplId, obj, ref flag)); } } return(null); } return(PageItem.GetStylePropByte(styleAttributeRplId, reportProperty)); }
public static void SetStyle(byte rplId, object styleProp, StyleWriter writer) { switch (rplId) { case 33: break; case 37: { int num = (int)styleProp; if (num > 0) { writer.Write(rplId, num); } break; } default: { bool flag = true; byte?stylePropByte = PageItem.GetStylePropByte(rplId, styleProp, ref flag); int? nullable = stylePropByte; if (nullable.HasValue) { writer.Write(rplId, stylePropByte.Value); } else if (flag) { writer.Write(rplId, styleProp.ToString()); } break; } } }
internal static byte?GetNonCompiledEnumProp(byte styleAttributeRplId, StyleAttributeNames styleAttributeName, Style style, StyleInstance styleIntance) { if (style == null) { return(null); } ReportProperty reportProperty = style[styleAttributeName]; if (reportProperty == null) { return(null); } if (reportProperty.IsExpression) { if (styleIntance != null) { object obj = styleIntance[styleAttributeName]; if (obj != null) { bool convertToString = false; return(PageItem.GetStylePropByte(styleAttributeRplId, obj, ref convertToString)); } } return(null); } return(PageItem.GetStylePropByte(styleAttributeRplId, reportProperty)); }
internal static void SetStyle(byte rplId, object styleProp, StyleWriter writer) { switch (rplId) { case 33: return; case 37: { int num = (int)styleProp; if (num > 0) { writer.Write(rplId, num); } return; } } bool convertToString = true; byte?stylePropByte = PageItem.GetStylePropByte(rplId, styleProp, ref convertToString); if (stylePropByte.HasValue) { writer.Write(rplId, stylePropByte.Value); } else if (convertToString) { writer.Write(rplId, styleProp.ToString()); } }
internal static void AddStyle(byte rplId, ReportProperty prop, StyleWriter writer) { byte?stylePropByte = PageItem.GetStylePropByte(rplId, prop); if (stylePropByte.HasValue) { writer.Write(rplId, stylePropByte.Value); } }
public static void AddStyle(byte rplId, ReportProperty prop, StyleWriter writer) { byte?stylePropByte = PageItem.GetStylePropByte(rplId, prop); int? nullable = stylePropByte; if (nullable.HasValue) { writer.Write(rplId, stylePropByte.Value); } }
internal static byte?GetEnumProp(byte rplId, StyleAttributeNames styleAttributeName, Style styleDef, Dictionary <byte, object> styles) { object value = null; if (styles != null && styles.TryGetValue(rplId, out value)) { byte?b = value as byte?; if (b.HasValue) { return(b.Value); } } ReportProperty reportProperty = styleDef[styleAttributeName]; if (reportProperty != null && !reportProperty.IsExpression) { return(PageItem.GetStylePropByte(rplId, reportProperty)); } return(null); }
public static byte?GetEnumProp(byte rplId, StyleAttributeNames styleAttributeName, Style styleDef, Dictionary <byte, object> styles) { object obj = null; if (styles != null && styles.TryGetValue(rplId, out obj)) { byte?nullable = (byte?)(object)(obj as byte?); int? nullable2 = nullable; if (nullable2.HasValue) { return(nullable.Value); } } ReportProperty reportProperty = ((StyleBase)styleDef)[styleAttributeName]; if (reportProperty != null && !reportProperty.IsExpression) { return(PageItem.GetStylePropByte(rplId, reportProperty)); } return(null); }