public static PrefSticky[] GetList(bool allowDefault) { int i = 0; int c = 3; if (allowDefault) { c++; } PrefSticky[] arr = new PrefSticky[c]; if (allowDefault) { arr[i++] = PrefSticky.Default; } arr[i++] = PrefSticky.Never; arr[i++] = PrefSticky.Always; arr[i++] = PrefSticky.WhenIdle; return(arr); }
public override bool Equals(object obj) { PrefSticky s = obj as PrefSticky; if (s != null) { return(this.sticky == s.sticky); } else { return(base.Equals(obj)); } }
public static PrefSticky[] GetList(bool allowDefault) { int i = 0; int c = 3; if (allowDefault) c++; PrefSticky[] arr = new PrefSticky[c]; if (allowDefault) { arr[i++] = PrefSticky.Default; } arr[i++] = PrefSticky.Never; arr[i++] = PrefSticky.Always; arr[i++] = PrefSticky.WhenIdle; return arr; }
public object GetRealObject(StreamingContext context) { return(PrefSticky.GetByValue(this.spo)); }