aboutsummaryrefslogtreecommitdiffstats
path: root/embed/mozilla/mozilla-embed-single.cpp
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2003-12-31 02:10:21 +0800
committerChristian Persch <chpe@src.gnome.org>2003-12-31 02:10:21 +0800
commite75afc16ed5bb461f2e1a49e052f23e70e47db82 (patch)
treeb105c9bc748b75bbad6de430f37858547049ae67 /embed/mozilla/mozilla-embed-single.cpp
parent69f1a14473f11b9890713a52843b5b8bd465f1f9 (diff)
downloadgsoc2013-epiphany-e75afc16ed5bb461f2e1a49e052f23e70e47db82.tar
gsoc2013-epiphany-e75afc16ed5bb461f2e1a49e052f23e70e47db82.tar.gz
gsoc2013-epiphany-e75afc16ed5bb461f2e1a49e052f23e70e47db82.tar.bz2
gsoc2013-epiphany-e75afc16ed5bb461f2e1a49e052f23e70e47db82.tar.lz
gsoc2013-epiphany-e75afc16ed5bb461f2e1a49e052f23e70e47db82.tar.xz
gsoc2013-epiphany-e75afc16ed5bb461f2e1a49e052f23e70e47db82.tar.zst
gsoc2013-epiphany-e75afc16ed5bb461f2e1a49e052f23e70e47db82.zip
Add API to EphyEmbedSingle to clear the HTTP authentication cache.
2003-12-30 Christian Persch <chpe@cvs.gnome.org> * embed/ephy-embed-single.c: (ephy_embed_single_clear_auth_cache): * embed/ephy-embed-single.h: * embed/mozilla/mozilla-embed-single.cpp: Add API to EphyEmbedSingle to clear the HTTP authentication cache.
Diffstat (limited to 'embed/mozilla/mozilla-embed-single.cpp')
-rw-r--r--embed/mozilla/mozilla-embed-single.cpp15
1 files changed, 14 insertions, 1 deletions
diff --git a/embed/mozilla/mozilla-embed-single.cpp b/embed/mozilla/mozilla-embed-single.cpp
index f60c60bee..84ace349d 100644
--- a/embed/mozilla/mozilla-embed-single.cpp
+++ b/embed/mozilla/mozilla-embed-single.cpp
@@ -75,6 +75,7 @@
#include <nsILocalFile.h>
#include <nsIURI.h>
#include <nsNetUtil.h>
+#include <nsIHttpAuthManager.h>
// FIXME: For setting the locale. hopefully gtkmozembed will do itself soon
#include <nsIChromeRegistry.h>
@@ -538,7 +539,6 @@ static void
impl_clear_cache (EphyEmbedSingle *shell)
{
nsresult rv;
-
nsCOMPtr<nsICacheService> CacheService =
do_GetService (NS_CACHESERVICE_CONTRACTID, &rv);
if (NS_SUCCEEDED (rv))
@@ -548,6 +548,18 @@ impl_clear_cache (EphyEmbedSingle *shell)
}
static void
+impl_clear_auth_cache (EphyEmbedSingle *shell)
+{
+ nsresult rv;
+ nsCOMPtr<nsIHttpAuthManager> AuthManager =
+ do_GetService (NS_HTTPAUTHMANAGER_CONTRACTID, &rv);
+ if (NS_SUCCEEDED (rv))
+ {
+ AuthManager->ClearAll();
+ }
+}
+
+static void
impl_set_offline_mode (EphyEmbedSingle *shell,
gboolean offline)
{
@@ -892,6 +904,7 @@ static void
ephy_embed_single_iface_init (EphyEmbedSingleClass *iface)
{
iface->clear_cache = impl_clear_cache;
+ iface->clear_auth_cache = impl_clear_auth_cache;
iface->set_offline_mode = impl_set_offline_mode;
iface->load_proxy_autoconf = impl_load_proxy_autoconf;
iface->get_font_list = impl_get_font_list;