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

Function init

pages/vomnibar_page.js:447–466  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

445let vomnibarInstance;
446
447function init() {
448 UIComponentMessenger.init();
449 UIComponentMessenger.registerHandler(function (event) {
450 switch (event.data.name) {
451 case "hide":
452 ui?.hide();
453 break;
454 case "hidden":
455 ui?.onHidden();
456 break;
457 case "activate":
458 const options = Object.assign({}, event.data);
459 delete options.name;
460 activate(options);
461 break;
462 default:
463 Utils.assert(false, "Unrecognized message type.", event.data);
464 }
465 });
466}
467
468const testEnv = globalThis.window == null ||
469 globalThis.window.location.search.includes("dom_tests=true");

Callers 1

vomnibar_page.jsFile · 0.70

Calls 4

onHiddenMethod · 0.80
activateFunction · 0.70
initMethod · 0.45
hideMethod · 0.45

Tested by

no test coverage detected