aboutsummaryrefslogtreecommitdiffstats
path: root/embed/mozilla/mozilla-embed-persist.cpp
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2005-05-07 02:15:29 +0800
committerChristian Persch <chpe@src.gnome.org>2005-05-07 02:15:29 +0800
commita6dfa12b0587d65d8015fbaef94fce453db10148 (patch)
tree9068d03ed49d42ad57664235857ca74cd04c2de9 /embed/mozilla/mozilla-embed-persist.cpp
parente03b3fa839387e8316632e15c39290095417f7c2 (diff)
downloadgsoc2013-epiphany-a6dfa12b0587d65d8015fbaef94fce453db10148.tar
gsoc2013-epiphany-a6dfa12b0587d65d8015fbaef94fce453db10148.tar.gz
gsoc2013-epiphany-a6dfa12b0587d65d8015fbaef94fce453db10148.tar.bz2
gsoc2013-epiphany-a6dfa12b0587d65d8015fbaef94fce453db10148.tar.lz
gsoc2013-epiphany-a6dfa12b0587d65d8015fbaef94fce453db10148.tar.xz
gsoc2013-epiphany-a6dfa12b0587d65d8015fbaef94fce453db10148.tar.zst
gsoc2013-epiphany-a6dfa12b0587d65d8015fbaef94fce453db10148.zip
Use nsICancelable.
2005-05-06 Christian Persch <chpe@cvs.gnome.org> * embed/mozilla/mozilla-embed-persist.cpp: Use nsICancelable.
Diffstat (limited to 'embed/mozilla/mozilla-embed-persist.cpp')
-rw-r--r--embed/mozilla/mozilla-embed-persist.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/embed/mozilla/mozilla-embed-persist.cpp b/embed/mozilla/mozilla-embed-persist.cpp
index b9f3e690c..06733ddbe 100644
--- a/embed/mozilla/mozilla-embed-persist.cpp
+++ b/embed/mozilla/mozilla-embed-persist.cpp
@@ -40,6 +40,7 @@
#include <nsIDOMSerializer.h>
#include <nsIIOService.h>
#include <nsNetCID.h>
+#include <nsNetError.h>
static void
mozilla_embed_persist_class_init (MozillaEmbedPersistClass *klass);
@@ -122,10 +123,18 @@ impl_cancel (EphyEmbedPersist *persist)
{
nsCOMPtr<nsIWebBrowserPersist> bpersist =
MOZILLA_EMBED_PERSIST (persist)->priv->mPersist;
+#ifdef HAVE_GECKO_1_8
+ nsCOMPtr<nsICancelable> cancelable (do_QueryInterface (bpersist));
+ if (cancelable)
+ {
+ cancelable->Cancel (NS_BINDING_ABORTED);
+ }
+#else
if (bpersist)
{
bpersist->CancelSave ();
}
+#endif
g_object_unref (persist);
}