public override bool HandlesKeyDown(Key key)
        {
            if (key == game.Mapping(KeyBinding.PlayerList))
            {
                if (playerList == null)
                {
                    CreatePlayerListWidget();
                }
                return(true);
            }

            if (chat.HandlesKeyDown(key))
            {
                return(true);
            }
            return(hotbar.HandlesKeyDown(key));
        }
Exemple #2
0
        public override bool HandlesKeyDown(Key key)
        {
            Key  playerListKey = game.Mapping(KeyBinding.PlayerList);
            bool handles       = playerListKey != Key.Tab || !game.TabAutocomplete || !chat.HandlesAllInput;

            if (key == playerListKey && handles)
            {
                if (playerList == null)
                {
                    CreatePlayerListWidget();
                }
                return(true);
            }

            if (chat.HandlesKeyDown(key))
            {
                return(true);
            }
            return(hotbar.HandlesKeyDown(key));
        }