Add shortcuts for Viewflags and Debug View modes #3472
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pr adds shortcuts to the options found in the "View Flags" and "Debug View" sections in the "View" menu of the editor and prefab editor.
Bloats the input options a bit, but imo that is a good tradeoff because the shortcuts make switching viewmodes much easier and also allow former Unreal engine users to keep their muscle memory.
There is no need to refresh the view and flags context menu after a shortcut is pressed, because when those menu are open the editor is not registering any shortcuts anyways.
Edit: I just did some collision setup for a few prefabs with this pr merged into my branch and it's been so much faster than usual because I could switch between collision view/ overlay mode and normal mode with the press of two buttons
Debug View
These shortcuts are the same as Unreal engine, the only difference being Alt + 1 for the collision mode, as I couldn't find an equivalent to Unreals "Detailed Lighting" and the collision view mode is also important.
View Flags
These shortcuts aren't inspired by anything lol. Pressing a shortcut will toggle the view flag it is assigned to on and off. I tried adding some default shortcuts to the most used view flags: