Comment 36 for bug 23369

Revision history for this message
In , Yinbolian (yinbolian) wrote :

>you don't need the destructor if you aren't implementing one...use use
>NS_IMPL_NSGETMODULE
Ok, I will change that in the next patch.

>I don't see why you need ReadSystemPref to go through this
>extra level of indirection of passing around an integer.
My aim is to check whether the "aTopic" is the pref in interested (in the
table). In case we receive some garbage.

> and I think you do need to keep these lists in sync, look:
I am not understood, I think. Ok, think of this situation,

static const char* sSysPrefList[] = {
    "network.proxy.http",
};

and

Index: ./system-pref/src/gconf/gconf_pref_list.inc
===================================================================
    {"network.proxy.http", "/system/http_proxy/host"},
    {"network.proxy.http_port", "/system/http_proxy/port"},
    {"network.http.connect.timeout", "/system/network/http/connect/timeout"},
    {"network.http.request.timeout", "network/http/request/timeout"},
    {"font.default", "/system/font/default"},
    {"font.size.variable.ar", "/font/size/variable/ar"},
    {"font.size.fixed.ar", "font/size/fixed/ar"},

The first list stands for mozilla, it says "I only want these prefs read from
system".

The second list stands for the system prefs, it says "Currently I support all
these prefs in mozilla".

So I think, they are not needed to be in sync.
I wait for your comments on this and on other parts of the patch before I made
another patch. Thanks.