File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -22,14 +22,18 @@ import type {
2222
2323import * as Constants from '../constants' ;
2424import type { Navigation } from '../navigation' ;
25+ import { Mover } from './mover' ;
2526
2627const KeyCodes = BlocklyUtils . KeyCodes ;
2728
2829/**
2930 * Class for registering a shortcut for the enter action.
3031 */
3132export class EnterAction {
32- constructor ( private navigation : Navigation ) { }
33+ constructor (
34+ private mover : Mover ,
35+ private navigation : Navigation ,
36+ ) { }
3337
3438 /**
3539 * Adds the enter action shortcut to the registry.
@@ -149,6 +153,8 @@ export class EnterAction {
149153 this . navigation . focusWorkspace ( workspace ) ;
150154 // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
151155 workspace . getCursor ( ) ?. setCurNode ( ASTNode . createBlockNode ( newBlock ) ! ) ;
156+
157+ this . mover . startMove ( workspace ) ;
152158 }
153159
154160 /**
Original file line number Diff line number Diff line change @@ -70,7 +70,7 @@ export class NavigationController {
7070
7171 exitAction : ExitAction = new ExitAction ( this . navigation ) ;
7272
73- enterAction : EnterAction = new EnterAction ( this . navigation ) ;
73+ enterAction : EnterAction = new EnterAction ( this . mover , this . navigation ) ;
7474
7575 actionMenu : ActionMenu = new ActionMenu ( this . navigation ) ;
7676
You can’t perform that action at this time.
0 commit comments