OSX the new search engine is not using Services.dirsvc/FileUtils.getFile to get special paths

RESOLVED INVALID

Status

()

RESOLVED INVALID
4 years ago
4 years ago

People

(Reporter: noitidart, Unassigned)

Tracking

36 Branch
x86_64
Windows 8.1
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

(Reporter)

Description

4 years ago
Created attachment 8560895 [details]
code for bugzilla where new search enigne doesnt use special paths right.js

User Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:36.0) Gecko/20100101 Firefox/36.0
Build ID: 20150202183609

Steps to reproduce:

On mac os x 10.10.1 I created a shortcut to my firefox profile by running the attached code from scratchpad with environment set to browser.



Actual results:

Click on drop down of new search engine nothing shows. On new tabs we see the error log of `this._defaultEngine` is null. etc. See screnshot attached


Expected results:

Should rely on Services.dirsvc and other methods that properly fetch special paths. So like Services.dirsvc('XREExeF', Ci.nsIFile) or FileUtils.getFile('XREExeF', []) etc.
(Reporter)

Comment 1

4 years ago
Created attachment 8560896 [details]
image of errors related to search engine.png

screenshot showing errors attached
(Reporter)

Comment 2

4 years ago
and that code makes a copy of all files in the original Firefox.app to as an alias, and folders as folders. Reason this is needed is thats how you make shortcut files in Mac to launch a profile. You can then "keep in dock" that icon, restart browser, restart computer with "open at login" or "reopen windows from last time" and it will open the right profile while remaining in right spot in dock ("kept" and non-kept). Also it takes the right icon if you set a custom icon on it.
(Reporter)

Comment 3

4 years ago
Oh never mind i fixed it up. I had to override the dir service provider, but i had to restart the browser afterwards:

https://github.com/Noitidart/PortableTester/blob/mac-alias-launcher-override-paths/bootstrap.js
(Reporter)

Comment 4

4 years ago
marking as resolved because the alias app shortcut only is created by my addons. and my addon comes with a fix for it.

and the fix for it override the Services.dirsvc paths, so the title of this is worng, the OSX new search engine DOES use Services.dirsvc, which is super good news!
Status: UNCONFIRMED → RESOLVED
Last Resolved: 4 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.