AdvancedLauncher.UI.Windows.Logger.GetNewIndex C# (CSharp) Method

GetNewIndex() private method

private GetNewIndex ( Key key ) : int
key Key
return int
        private int GetNewIndex(Key key)
        {
            switch (key) {
                case Key.Up:
                    if (recentIndex <= 0) {
                        return recentIndex;
                    } else {
                        return recentIndex - 1;
                    }
                case Key.Down:
                    return recentIndex + 1;

                default:
                    return recentIndex;
            }
        }