Exemple #1
0
        public ThemeState AddState(int stateId, string name = null)
        {
            ThemeState state = FindState(stateId);

            if (state == null)
            {
                state = new ThemeState(this, stateId, name ?? ThemeInfo.GetStateName(Parent.ClassName, Id, stateId));
                if (stateId == 0)
                {
                    partState = state;
                }
                else
                {
                    states.Add(state);
                }
            }

            return(state);
        }
Exemple #2
0
 private int CompareState(ThemeState x, ThemeState y)
 {
     return(x.Id.CompareTo(y.Id));
 }