aboutsummaryrefslogtreecommitdiffstats
path: root/embed/mozilla/mozilla-embed-single.cpp
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2005-05-06 22:47:28 +0800
committerChristian Persch <chpe@src.gnome.org>2005-05-06 22:47:28 +0800
commite0273e6cf13d88db4af3c31a71e23780a706ba7b (patch)
tree8784bcaef7adb7b8d5b8c2978baf916956ccc909 /embed/mozilla/mozilla-embed-single.cpp
parentac9c396df1323960ea05ed345a4c92a3229b962e (diff)
downloadgsoc2013-epiphany-e0273e6cf13d88db4af3c31a71e23780a706ba7b.tar
gsoc2013-epiphany-e0273e6cf13d88db4af3c31a71e23780a706ba7b.tar.gz
gsoc2013-epiphany-e0273e6cf13d88db4af3c31a71e23780a706ba7b.tar.bz2
gsoc2013-epiphany-e0273e6cf13d88db4af3c31a71e23780a706ba7b.tar.lz
gsoc2013-epiphany-e0273e6cf13d88db4af3c31a71e23780a706ba7b.tar.xz
gsoc2013-epiphany-e0273e6cf13d88db4af3c31a71e23780a706ba7b.tar.zst
gsoc2013-epiphany-e0273e6cf13d88db4af3c31a71e23780a706ba7b.zip
Use new way to add user agent info. Fixes bug #173000.
2005-05-06 Christian Persch <chpe@cvs.gnome.org> * embed/mozilla/mozilla-embed-single.cpp: Use new way to add user agent info. Fixes bug #173000.
Diffstat (limited to 'embed/mozilla/mozilla-embed-single.cpp')
-rw-r--r--embed/mozilla/mozilla-embed-single.cpp11
1 files changed, 9 insertions, 2 deletions
diff --git a/embed/mozilla/mozilla-embed-single.cpp b/embed/mozilla/mozilla-embed-single.cpp
index c5b16c728..2053914e9 100644
--- a/embed/mozilla/mozilla-embed-single.cpp
+++ b/embed/mozilla/mozilla-embed-single.cpp
@@ -236,10 +236,17 @@ mozilla_set_default_prefs (MozillaEmbedSingle *mes)
g_warning ("failed to read user preferences, error: %x", rv);
}
- /* FIXME We need to do this because mozilla doesnt set product
- sub for embedding apps */
+#ifdef HAVE_GECKO_1_8
+ /* FIXME: maybe only set the major version ("1.6", "1.8") here? */
+ pref->SetCharPref ("general.useragent.extra.epiphany", "Epiphany/" VERSION);
+
+ /* Unset old prefs, otherwise they end up in the user agent string too */
+ pref->ClearUserPref ("general.useragent.vendor");
+ pref->ClearUserPref ("general.useragent.vendorSub");
+#else
pref->SetCharPref ("general.useragent.vendor", "Epiphany");
pref->SetCharPref ("general.useragent.vendorSub", VERSION);
+#endif
/* Open ftp uris with an external handler if one is setup */
pref->SetBoolPref("network.protocol-handler.external.ftp",