Closed Bug 1702240 Opened 3 years ago Closed 3 years ago

Change nsDocShell's notification of keyword-search pass a string rather than an engine

Categories

(Firefox :: Search, task, P3)

task

Tracking

()

RESOLVED FIXED
96 Branch
Tracking Status
firefox96 --- fixed

People

(Reporter: standard8, Assigned: janey, Mentored)

References

(Blocks 1 open bug)

Details

(Whiteboard: [lang=js|cpp][good-next-bug])

Attachments

(1 file)

If we pass a string for the engine name in the keyword-search notification, then nsDocShell will no longer need to import the search service. This will help with potentially changing the search service to not be an XPCOM service (bug 1643008). It is still slightly TBD if we do make the change or not, but I think this is a useful simplification.

The keyword-search notification and handler can be found here: https://searchfox.org/mozilla-central/search?q=keyword-search&path=*&case=false&regexp=false

nsDocShell::MaybeNotifyKeywordSearchLoading should be changed to pass aProvider as the first argument, however, that needs to be wrapped into a nsISupports interface, e.g. example here.

On the JavaScript side, I think we can use Services.search.getEngineByName(subject.data) to get the engine object.

I would like to try to fix this issue.

(In reply to mgroot from comment #1)

I would like to try to fix this issue.

Sure. Thank you for the offer.

Assignee: nobody → m.a.w.degroot
Mentor: standard8
Severity: -- → N/A
Priority: -- → P3

:mgroot, are you still working on this?

Flags: needinfo?(m.a.w.degroot)

I am, but I have little time at the moment so if it is high priority feel free to reassign.

Flags: needinfo?(m.a.w.degroot)

(In reply to mgroot from comment #4)

I am, but I have little time at the moment so if it is high priority feel free to reassign.

That is fine, this isn't high priority at the moment, so just wanted to check. Just let us know if anything changes. If you need help let us know.

Opening this up for others, as mgroot hasn't had time to get to it.

Assignee: m.a.w.degroot → nobody
Whiteboard: [lang=js|cpp][good-next-bug]

Hey guys! Would love to work on this one!

Assignee: nobody → jenyabrentnall
Pushed by mbanner@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/7987621675da
Change nsDocShell's notification of keyword-search pass a string rather than an engine. r=Standard8
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 96 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: