fix typo in function name, cleanup unused args (#317)
Signed-off-by: Jess Frazelle <github@jessfraz.com>
This commit is contained in:
		@ -530,14 +530,12 @@ export class EngineCommandManager {
 | 
			
		||||
    console.log('sending command', command)
 | 
			
		||||
    this.engineConnection?.send(command)
 | 
			
		||||
  }
 | 
			
		||||
  sendModellingCommand({
 | 
			
		||||
  sendModelingCommand({
 | 
			
		||||
    id,
 | 
			
		||||
    params,
 | 
			
		||||
    range,
 | 
			
		||||
    command,
 | 
			
		||||
  }: {
 | 
			
		||||
    id: string
 | 
			
		||||
    params: any
 | 
			
		||||
    range: SourceRange
 | 
			
		||||
    command: EngineCommand
 | 
			
		||||
  }): Promise<any> {
 | 
			
		||||
 | 
			
		||||
@ -30,14 +30,8 @@ export const extrude: InternalFn = (
 | 
			
		||||
 | 
			
		||||
  const extrudeSurfaces: ExtrudeSurface[] = []
 | 
			
		||||
  const extrusionDirection = clockwiseSign(sketch.value.map((line) => line.to))
 | 
			
		||||
  engineCommandManager.sendModellingCommand({
 | 
			
		||||
  engineCommandManager.sendModelingCommand({
 | 
			
		||||
    id,
 | 
			
		||||
    params: [
 | 
			
		||||
      {
 | 
			
		||||
        length,
 | 
			
		||||
        extrusionDirection: extrusionDirection,
 | 
			
		||||
      },
 | 
			
		||||
    ],
 | 
			
		||||
    range: sourceRange,
 | 
			
		||||
    command: {
 | 
			
		||||
      type: 'modeling_cmd_req',
 | 
			
		||||
 | 
			
		||||
@ -253,9 +253,8 @@ export const line: SketchLineHelper = {
 | 
			
		||||
      sourceRange,
 | 
			
		||||
      data,
 | 
			
		||||
    })
 | 
			
		||||
    engineCommandManager.sendModellingCommand({
 | 
			
		||||
    engineCommandManager.sendModelingCommand({
 | 
			
		||||
      id,
 | 
			
		||||
      params: [lineData, previousSketch],
 | 
			
		||||
      range: sourceRange,
 | 
			
		||||
      command: {
 | 
			
		||||
        type: 'modeling_cmd_req',
 | 
			
		||||
@ -1535,18 +1534,13 @@ export const close: InternalFn = (
 | 
			
		||||
    ? sketchGroup.start.from
 | 
			
		||||
    : getCoordsFromPaths(sketchGroup, 0)
 | 
			
		||||
 | 
			
		||||
  const lineData: LineData = {
 | 
			
		||||
    from: [...from, 0],
 | 
			
		||||
    to: [...to, 0],
 | 
			
		||||
  }
 | 
			
		||||
  const id = makeId({
 | 
			
		||||
    code,
 | 
			
		||||
    sourceRange,
 | 
			
		||||
    data: sketchGroup,
 | 
			
		||||
  })
 | 
			
		||||
  engineCommandManager.sendModellingCommand({
 | 
			
		||||
  engineCommandManager.sendModelingCommand({
 | 
			
		||||
    id,
 | 
			
		||||
    params: [lineData],
 | 
			
		||||
    range: sourceRange,
 | 
			
		||||
    command: {
 | 
			
		||||
      type: 'modeling_cmd_req',
 | 
			
		||||
@ -1608,9 +1602,8 @@ export const startSketchAt: InternalFn = (
 | 
			
		||||
    data,
 | 
			
		||||
    isPath: true,
 | 
			
		||||
  })
 | 
			
		||||
  engineCommandManager.sendModellingCommand({
 | 
			
		||||
  engineCommandManager.sendModelingCommand({
 | 
			
		||||
    id: pathId,
 | 
			
		||||
    params: [lineData],
 | 
			
		||||
    range: sourceRange,
 | 
			
		||||
    command: {
 | 
			
		||||
      type: 'modeling_cmd_req',
 | 
			
		||||
 | 
			
		||||
@ -10,7 +10,7 @@ class MockEngineCommandManager {
 | 
			
		||||
  startNewSession() {}
 | 
			
		||||
  waitForAllCommands() {}
 | 
			
		||||
  waitForReady = new Promise<void>((resolve) => resolve())
 | 
			
		||||
  sendModellingCommand() {}
 | 
			
		||||
  sendModelingCommand() {}
 | 
			
		||||
  sendSceneCommand() {}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Reference in New Issue
	
	Block a user