public override void Close() { if (displayState == DisplayState.Closed || displayState == DisplayState.Closing) { return; } displayState = DisplayState.Closing; rec_fore.Close(); closeCounter = 0; //fore, then bkg }
public override void Close() { if (displayState == DisplayState.Opened || displayState == DisplayState.Opening) { displayState = DisplayState.Closing; line.Close(); recA.Close(); recB.Close(); } }
public override void Update() { rec_bkg.Update(); rec_fore.Update(); if (displayState == DisplayState.Opening) { openCounter++; if (openCounter >= openWait) { rec_fore.Open(); } if (rec_bkg.displayState == DisplayState.Opened & rec_fore.displayState == DisplayState.Opened) { displayState = DisplayState.Opened; } } else if (displayState == DisplayState.Opened) { } else if (displayState == DisplayState.Closing) { closeCounter++; if (closeCounter >= closeWait) { rec_bkg.Close(); } if (rec_fore.displayState == DisplayState.Closed & rec_bkg.displayState == DisplayState.Closed) { displayState = DisplayState.Closed; } } else if (displayState == DisplayState.Closed) { } }