public SelectabilityStateEngine(IUIImage uiImage, IUIManager uim)
        {
            selectableState   = new SelectableState(uiImage, uim);
            unselectableState = new UnselectableState(uiImage, uim);
            selectedState     = new SelectedState(uiImage, uim);

            MakeSureStatesAreSet();

            this.SetToInitialState();
        }
예제 #2
0
        public SelectabilityStateEngine(
            ISelectabilityStateImplementor implementor
            )
        {
            State.IConstArg stateArg = new State.ConstArg(
                implementor
                );
            selectableState = new SelectableState(
                stateArg
                );
            unselectableState = new UnselectableState(
                stateArg
                );
            selectedState = new SelectedState(
                stateArg
                );
            MakeSureStatesAreSet();

            thisCurState = selectableState;
        }