Chrome extension using multiple omnibox keywords
Asked Answered
C

1

14

i am trying to create a Google Chrome extension and i want it to listen to multiple keywords from the Omnibox. To make it short, i want to know whether these two things are possible:

  • defining multiple omnibox keywords for one extension in the manifest file
  • letting chrome.omnibox.onInputEntered and other events know what keyword is enabled

thanks in advance.

Cilium answered 24/7, 2013 at 6:2 Comment(0)
K
29

No, the Chromium developers have made it clear that they will not support multiple omnibox keywords for extensions:

My take on this is that an omnibox keyword is a UI surface, like a page/browser action. We limit extensions to 1 UI surface to avoid adding clutter. Given that, I don't think we should implement this.

Granted, this bug asks for both the ability to define multiple keywords and dynamically change those keywords on the fly. However, the developer response seems opposed to multiple keywords in general.

The same response suggests an alternative:

The keyword is meant to act as a prefix for your extension, so rather than having N keywords, how about 1 keyword that accepts N commands?

Instead of supporting both keyword1 something and keyword2 something, you can use masterkeyword keyword1 something and masterkeyword keyword2 something.

Kistler answered 24/7, 2013 at 14:20 Comment(2)
It's too bad extensions can't dynamically change the keyword. The user might want to change the keyword to something more convenient. Also, if multiple extensions wanted to use the same keyword, allowing keywords to be changed dynamically would let the extension (or the user) choose a different one to resolve the conflict.Heads
@apsillers, What about conflicts?Wonderment

© 2022 - 2024 — McMap. All rights reserved.