Ejemplo n.º 1
0
 private static ColorDuo GetColorDuo(ref ColorDuo cd, string c1, string c2)
 {
     if (cd == null)
     {
         cd = new ColorDuo(RuntimeHelper.HexToColor(c1), RuntimeHelper.HexToColor(c2));
     }
     return(cd);
 }
Ejemplo n.º 2
0
 private static StyleDuo GetStyleDuo(ref StyleDuo style, ColorDuo cd)
 {
     // it seems that re-creating the textures if they've been destroyed will still cause some strange leaks
     // so I just re-create the whole style if the textures are destroyed
     if (style == null || style.TexturesHaveBeenDestroyed)
     {
         style = new StyleDuo(cd);
     }
     return(style);
 }
Ejemplo n.º 3
0
		private static StyleDuo GetStyleDuo(ref StyleDuo style, ColorDuo cd)
		{
			// it seems that re-creating the textures if they've been destroyed will still cause some strange leaks
			// so I just re-create the whole style if the textures are destroyed
			if (style == null || style.TexturesHaveBeenDestroyed) style = new StyleDuo(cd);
			return style;
		}
Ejemplo n.º 4
0
		private static ColorDuo GetColorDuo(ref ColorDuo cd, string c1, string c2)
		{
			if (cd == null) cd = new ColorDuo(RuntimeHelper.HexToColor(c1), RuntimeHelper.HexToColor(c2));
			return cd;
		}