Where did you install Firefox from? Help Mozilla uncover 3rd party websites that offer problematic Firefox installation by taking part in our campaign. There will be swag, and you'll be featured in our blog if you manage to report at least 10 valid reports!

Αναζήτηση στην υποστήριξη

Προσοχή στις απάτες! Δεν θα σας ζητήσουμε ποτέ να καλέσετε ή να στείλετε μήνυμα σε κάποιον αριθμό τηλεφώνου ή να μοιραστείτε προσωπικά δεδομένα. Αναφέρετε τυχόν ύποπτη δραστηριότητα μέσω της επιλογής «Αναφορά κατάχρησης».

Learn More

nsBrowserContentHandler.js is gibberish

  • 4 απαντήσεις
  • 1 έχει αυτό το πρόβλημα
  • 8 προβολές
  • Τελευταία απάντηση από Yaron

more options

I'd like to modify some lines in nsBrowserContentHandler.js.

I've extracted omni.ja. JS files in "omni\jsloader\resource\app\components" are gibberish (using Notepad++). I have no problem opening JS files in omni\chrome\browser\content\browser.

Any idea?

Thank you.

I'd like to modify some lines in nsBrowserContentHandler.js. I've extracted omni.ja. JS files in "omni\jsloader\resource\app\components" are gibberish (using Notepad++). I have no problem opening JS files in omni\chrome\browser\content\browser. Any idea? Thank you.

Όλες οι απαντήσεις (4)

more options

It is likely that the files in jsloader are compressed and can't be viewed directly.

Did you try to access the file via the components folder?

Maybe create an extension to overlay this function with a modified version.

  • resource:///components/nsBrowserContentHandler.js

Note that it isn't recommended to make changes to files in an omni.ja archive.

more options

Thank you cor-el. You're brilliant.

I've opened nsBrowserContentHandler.js in "omni\components".

I want to allow external links to open in a private window. I've changed the following lines:

 var allowPrivate = forcePrivate || PrivateBrowsingUtils.permanentPrivateBrowsing;
 var navWin = RecentWindow.getMostRecentBrowserWindow({private: allowPrivate});

to:

// var allowPrivate = forcePrivate || PrivateBrowsingUtils.permanentPrivateBrowsing;

 var navWin = RecentWindow.getMostRecentBrowserWindow({private: true});

After zipping the files and replacing omni.ja, I don't get what I want. I guess I have to modify the file in "omni\jsloader\resource\app\components" as well. How do I do that?

more options

Do you see the modified file with the resource:// link?

  • resource:///components/nsBrowserContentHandler.js
more options

Yes, I do see it.

Thanks again.