mojira.dev
MC-147727

Unable to close anvil using inventory key without taking the input item out, if textfield has focus

The bug

When trying to exit the Anvil GUI, if there is an item in the input slot and the textfield has focus, the inventory key cannot close the GUI. However after taking the item out and then trying to exit using the inventory key it exits correctly.

How to reproduce:

  1. Right-click an anvil

  2. Place an item on the left, like e.g. Stone

  3. Click on the textfield or press TAB to give it focus (this step was introduced in 20w10a, because the textfield doesn't start focused anymore but was fixed later)

  4. Use the inventory key to close the GUI
    > ❌  Nothing happens

  5. Now take out the item and try the inventory key again
    > ✔ GUI now closes

Related issues

Attachments

Comments

migrated
[media]
Jack McKalling

Follow-up of MC-147184

Jack McKalling

Because the anvil doesn't focus the textfield anymore, I just discovered in 20w10a that the focus is required for this bug to happen. If the textfield has no focus, pressing the inventory key correctly closes the GUI.

Jack McKalling

(Unassigned)

Confirmed

(Unassigned)

anvil

Minecraft 19w14b, Minecraft 1.14 Pre-Release 1, Minecraft 1.14 Pre-Release 2, Minecraft 1.14 Pre-Release 3, Minecraft 1.14 Pre-Release 4, ..., 21w20a, 1.17 Release Candidate 2, 1.17, 1.17.1, 1.21

Retrieved