Using number keys to switch items doesn't work correctly in containers
To reproduce:
1. place chest and put in items
2. hold an item in your hot bar
3. hover over one of the items in the chest
4. press the number where the item is in your hot bar (eg. slot 1 press "1")
The items will not be switched as they should be but instead both moved into the hotbar
Related issues
Attachments
Comments


Confirmed.

still in 14w21b

Hmmm. It appears to move the displaced item to the first available slot in the player's hotbar or inventory, rather than swapping it with the item the player is pointing at. If the displaced item can stack will other items in the player's inventory, it will. The stack doesn't even have to fit in the same stack – it will be distributed over other stacks that have room in them.

14w21b:
Could this maybe be somehow a new feature?

Confirmed as early as 1.7.2. I haven't played earlier versions of MC so IDK if it did this since the beginning or not.

Cannot Reproduce in 1.8.1 Pre3, assuming it's Fixed

Reproduced in 1.8.1. Consider these two scenarios:
1: You have an item in hotbar slot 1, and a different item somewhere in your inventory. If you point at the item in your inventory and press 1, the items will swap places, so that the item in your inventory is now in hotbar slot 1, and the item that was in your hotbar is in the same place in your inventory as the other item.
2: You have an item in hotbar slot 1, as before, but the other item is in a container, such as a chest. If you point at the item in the container and press 1, the item in hotbar slot 1 will be moved to hotbar slot 2, and the item in the container will be moved to hotbar slot 1.
So the difference is in where the item already in your hotbar goes.

Is this still an issue in the current Minecraft Snapshot 15w49b or later? If so, please update the affected versions in order to best aid Mojang ensuring bugs are still valid in the latest releases/pre-releases.

Fixed sometime between 1.8.8 and 1.9.4.