-
Notifications
You must be signed in to change notification settings - Fork 171
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Modifiers for reparenting and convert to absolute strategies (#6054)
**Description:** To make our canvas interactions more predictable I put reparenting and conversion to absolute behind modifier keys: - cmd is needed for reparenting - ctrl is needed for conversion to absolute **Notes:** - Nearly 70 tests were broken (nearly all reparenting and convert-to-absolute tests). In most of the cases I just had to add the necessary modifiers to make the tests work - Insertion relies on reparenting, I needed to modify the draw-to-insert strategy too - cmd disables snapping, so now it is not possible to have snapping during reparenting (I needed to disable the tests for this) - space forces convert to absolute, this is in partial conflict with ctrl, but they are not really the same: without ctrl convert-to-absolute strategies are disabled, but even with ctrl other strategies are still possible, while space really forces convert-to-absolute strategies - when you have a selection, cmd mouse down on a descendant element will change the selection to the descendant. If you don't want that, you need to press cmd after the mouse down. - with ctrl, you always need to press it after mouse down, otherwise the context menu will open - earlier cmd had a special meaning in case of reparenting: it allowed the element to be reparented into a parent which is smaller than the element itself. This distinction doesn't exist anymore, because without pressing cmd there is no reparent at all **Manual Tests:** I hereby swear that: - [x] I opened a hydrogen project and it loaded - [x] I could navigate to various routes in Preview mode Fixes #6047
- Loading branch information
Showing
14 changed files
with
468 additions
and
148 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.