MCPcopy
hub / github.com/philc/vimium / commandHandler

Method commandHandler

content_scripts/mode_visual.js:366–379  ·  view source on GitHub ↗
({ command: { command }, count })

Source from the content-addressed store, hash-verified

364 }
365
366 commandHandler({ command: { command }, count }) {
367 if (count == null) count = 1;
368 switch (typeof command) {
369 case "string":
370 for (let i = 0, end = count; i < end; i++) {
371 this.movement.runMovement(command);
372 }
373 break;
374 case "function":
375 command(count);
376 break;
377 }
378 return this.movement.scrollIntoView();
379 }
380
381 // find: (count, backwards) =>
382 find(count, backwards) {

Callers

nothing calls this directly

Calls 2

runMovementMethod · 0.80
scrollIntoViewMethod · 0.80

Tested by

no test coverage detected