mirror of
https://github.com/invoke-ai/InvokeAI.git
synced 2026-02-13 18:05:20 -05:00
Update CanvasStateApiModule.ts
Add temporary grid snap with ctrl, optional small step with ctrl+shift, while grid snap is off
This commit is contained in:
committed by
psychedelicious
parent
7a23d8266f
commit
fa94a05c77
@@ -319,6 +319,14 @@ export class CanvasStateApiModule extends CanvasModuleBase {
|
||||
getPositionGridSize = (): number => {
|
||||
const snapToGrid = this.getSettings().snapToGrid;
|
||||
if (!snapToGrid) {
|
||||
const overrideSnap = this.$ctrlKey.get() || this.$metaKey.get();
|
||||
if (overrideSnap) {
|
||||
const useFine = this.$shiftKey.get();
|
||||
if (useFine) {
|
||||
return 8;
|
||||
}
|
||||
return 64;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
const useFine = this.$ctrlKey.get() || this.$metaKey.get();
|
||||
|
||||
Reference in New Issue
Block a user