I have created a Firefox extension and a C++ program:
The extension show some information on a sidebar on Firefox.
The C++ program edit some preferences of the extension in the prefs.js (preferences file of Firefox) when Firefox is in execution:
user_pref("Sidebarinfo.initialize", "true");
user_pref("Sidebarinfo.initdone", "false");
user_pref("Sidebarinfo.usageflag", "eng");
user_pref("Sidebarinfo.userid", "162");
user_pref("Sidebarinfo.originaltime", "1309061712");
So, how can I edit my extension’s preferences when Firefox is in execution?
If I edit prefs.js when Firefox is in execution (and only in this case), then Firefox resets prefs.js.
You can’t do the communication part that way. It’s a settings file, no “communication file”. You’ll have to read some other file (not sure how far this is possible) with the extension or retrieve some url from a mini http server embedded into the C++ program.