-
Notifications
You must be signed in to change notification settings - Fork 881
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feat: Implemented keyboard shortcut Alt to perform a centered resize #6586
base: master
Are you sure you want to change the base?
Conversation
While holding the Alt key and resizing an instance, both sides are resized. This was achieved by doubling the scaling factor and updating the new X and Y coordinates without using a fixedPoint. Closes issue 4ian#6160 Co-authored-by: David Palma <david.palma@tecnico.ulisboa.pt>
@@ -210,14 +211,17 @@ export default class InstancesResizer { | |||
: roundedTotalDeltaX; | |||
const flippedTotalDeltaY = isTop ? -roundedTotalDeltaY : roundedTotalDeltaY; | |||
|
|||
// While rezising both sides, TotalDelta must be doubled |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// While rezising both sides, TotalDelta must be doubled | |
// While resizing both sides, TotalDelta must be doubled. |
@@ -210,14 +211,17 @@ export default class InstancesResizer { | |||
: roundedTotalDeltaX; | |||
const flippedTotalDeltaY = isTop ? -roundedTotalDeltaY : roundedTotalDeltaY; | |||
|
|||
// While rezising both sides, TotalDelta must be doubled | |||
const altOffset = centeredResize ? 2 : 1; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
altOffset is not very meaningful as a variable name. Can you think of something that represents this factor?
Thanks for the suggestion! |
Hi! Thanks for the review. |
Could you clarify the what you mean by "depends on the default X rotation?". |
Here is a video to reproduce the particular issue I saw: demo_bug_alt_resize_3D_model.movDepending on the Default X Rotation, the point that does not move is never the same 😅 |
Hi @AlexandreSi, |
While holding the Alt key and resizing an instance, both sides are
resized. This was achieved by doubling the scaling factor and
updating the new X and Y coordinates without using a fixedPoint.
Closes issue #6160