126 lines
3.8 KiB
C#
126 lines
3.8 KiB
C#
using System;
|
|
using System.Linq;
|
|
using Cpp2IlInjected;
|
|
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
|
|
namespace RRUI.Theme
|
|
{
|
|
// Token: 0x02000837 RID: 2103
|
|
[Token(Token = "0x2000837")]
|
|
public class SurfaceTheme : PaletteThemeReference
|
|
{
|
|
// Token: 0x17000A52 RID: 2642
|
|
// (get) Token: 0x06003A42 RID: 14914 RVA: 0x000F1428 File Offset: 0x000EF628
|
|
// (set) Token: 0x06003A43 RID: 14915 RVA: 0x000F143C File Offset: 0x000EF63C
|
|
[Token(Token = "0x17000A52")]
|
|
public HKNKJCKPDIH LJEGDBMBIEE
|
|
{
|
|
[Token(Token = "0x6003A42")]
|
|
[Address(RVA = "0x4730E0", Offset = "0x471EE0", VA = "0x1804730E0")]
|
|
get
|
|
{
|
|
return this.color;
|
|
}
|
|
[Token(Token = "0x6003A43")]
|
|
[Address(RVA = "0x9FAF40", Offset = "0x9F9D40", VA = "0x1809FAF40")]
|
|
set
|
|
{
|
|
if (this.color != value)
|
|
{
|
|
this.color = value;
|
|
bool isCompleted = ((IAsyncResult)this).IsCompleted;
|
|
return;
|
|
}
|
|
}
|
|
}
|
|
|
|
// Token: 0x06003A44 RID: 14916 RVA: 0x000F1464 File Offset: 0x000EF664
|
|
[Token(Token = "0x6003A44")]
|
|
[Address(RVA = "0x9FACD0", Offset = "0x9F9AD0", VA = "0x1809FACD0", Slot = "5")]
|
|
public override void Apply()
|
|
{
|
|
Palette palette = this.paletteTheme.palette;
|
|
HKNKJCKPDIH hknkjckpdih = this.color;
|
|
Palette.HPNELBJEPJH hpnelbjepjh = new Palette.HPNELBJEPJH();
|
|
hpnelbjepjh.backgroundColorPaletteType = hknkjckpdih;
|
|
Palette.BackgroundColorPaletteItem[] backgroundColorPalettes = palette.backgroundColorPalettes;
|
|
Func<Palette.BackgroundColorPaletteItem, bool> func = delegate(Palette.BackgroundColorPaletteItem backgroundColorPaletteItem)
|
|
{
|
|
HKNKJCKPDIH backgroundColorPaletteType = hpnelbjepjh.backgroundColorPaletteType;
|
|
return backgroundColorPaletteItem.backgroundColorPaletteType == backgroundColorPaletteType;
|
|
};
|
|
Palette.BackgroundColorPaletteItem backgroundColorPaletteItem2 = Enumerable.FirstOrDefault<Palette.BackgroundColorPaletteItem>(backgroundColorPalettes, func);
|
|
if (backgroundColorPaletteItem2 == 0 || backgroundColorPaletteItem2.gradient != 0)
|
|
{
|
|
Color white = Color.white;
|
|
}
|
|
Gradient gradient = new Gradient();
|
|
Color color = this.image.color;
|
|
UIGradient uigradient = this.gradient;
|
|
int num = 0;
|
|
if (uigradient != num && !this.ignoreGradient)
|
|
{
|
|
UIGradient uigradient2 = this.gradient;
|
|
Gradient gradient2 = uigradient2.gradient;
|
|
if (gradient2 != gradient)
|
|
{
|
|
Gradient gradient3;
|
|
if (gradient == 0)
|
|
{
|
|
gradient3 = new Gradient();
|
|
uigradient2.gradient = gradient3;
|
|
}
|
|
Gradient gradient4;
|
|
if (gradient2 == 0)
|
|
{
|
|
gradient4 = new Gradient();
|
|
uigradient2.gradient = gradient4;
|
|
}
|
|
GradientColorKey[] colorKeys = gradient3.colorKeys;
|
|
GradientAlphaKey[] alphaKeys = gradient3.alphaKeys;
|
|
gradient4.SetKeys(colorKeys, alphaKeys);
|
|
Gradient gradient5 = uigradient2.gradient;
|
|
GradientMode mode = gradient3.mode;
|
|
uigradient2.LEEFJJKFHJH = true;
|
|
uigradient2.DBNJDLHEEPJ();
|
|
}
|
|
}
|
|
}
|
|
|
|
// Token: 0x06003A45 RID: 14917 RVA: 0x000F1588 File Offset: 0x000EF788
|
|
[Token(Token = "0x6003A45")]
|
|
[Address(RVA = "0x74EA40", Offset = "0x74D840", VA = "0x18074EA40")]
|
|
public SurfaceTheme()
|
|
{
|
|
}
|
|
|
|
// Token: 0x04003221 RID: 12833
|
|
[FieldOffset(Offset = "0x20")]
|
|
[Token(Token = "0x4003221")]
|
|
[SerializeField]
|
|
[DDPIINEJFMD(JIBDPHMGEGO.Self, false, false, false)]
|
|
private Image image;
|
|
|
|
// Token: 0x04003222 RID: 12834
|
|
[FieldOffset(Offset = "0x28")]
|
|
[Token(Token = "0x4003222")]
|
|
[SerializeField]
|
|
[OCIDFHDICIP(JIBDPHMGEGO.Self, false, false, false)]
|
|
private UIGradient gradient;
|
|
|
|
// Token: 0x04003223 RID: 12835
|
|
[FieldOffset(Offset = "0x30")]
|
|
[Token(Token = "0x4003223")]
|
|
[SerializeField]
|
|
private HKNKJCKPDIH color;
|
|
|
|
// Token: 0x04003224 RID: 12836
|
|
[FieldOffset(Offset = "0x34")]
|
|
[Token(Token = "0x4003224")]
|
|
[SerializeField]
|
|
[OMAIFIIBMNL("gradient")]
|
|
private bool ignoreGradient;
|
|
}
|
|
}
|