aboutsummaryrefslogtreecommitdiffstats
path: root/embed/mozilla/EphyBrowser.cpp
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2005-05-05 20:55:11 +0800
committerChristian Persch <chpe@src.gnome.org>2005-05-05 20:55:11 +0800
commit39d6c68acf69f08e5d141b6a2fc91c003a5f594c (patch)
tree8bcbfd7655e180adb459d02c651605a19810f626 /embed/mozilla/EphyBrowser.cpp
parent7e6e562f008531e7197bf71c4526d4d49f040766 (diff)
downloadgsoc2013-epiphany-39d6c68acf69f08e5d141b6a2fc91c003a5f594c.tar
gsoc2013-epiphany-39d6c68acf69f08e5d141b6a2fc91c003a5f594c.tar.gz
gsoc2013-epiphany-39d6c68acf69f08e5d141b6a2fc91c003a5f594c.tar.bz2
gsoc2013-epiphany-39d6c68acf69f08e5d141b6a2fc91c003a5f594c.tar.lz
gsoc2013-epiphany-39d6c68acf69f08e5d141b6a2fc91c003a5f594c.tar.xz
gsoc2013-epiphany-39d6c68acf69f08e5d141b6a2fc91c003a5f594c.tar.zst
gsoc2013-epiphany-39d6c68acf69f08e5d141b6a2fc91c003a5f594c.zip
Thanks to the fastback patch, we can now get the secure browser UI object
2005-05-05 Christian Persch <chpe@cvs.gnome.org> * embed/mozilla/EphyBrowser.cpp: * embed/mozilla/MozRegisterComponents.cpp: Thanks to the fastback patch, we can now get the secure browser UI object from the docshell.
Diffstat (limited to 'embed/mozilla/EphyBrowser.cpp')
-rw-r--r--embed/mozilla/EphyBrowser.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/embed/mozilla/EphyBrowser.cpp b/embed/mozilla/EphyBrowser.cpp
index 91bfca09d..0372fc13c 100644
--- a/embed/mozilla/EphyBrowser.cpp
+++ b/embed/mozilla/EphyBrowser.cpp
@@ -525,6 +525,13 @@ nsresult EphyBrowser::Init (GtkMozEmbed *mozembed)
NS_ENSURE_SUCCESS (rv, NS_ERROR_FAILURE);
#ifdef HAVE_MOZILLA_PSM
+#ifdef HAVE_GECKO_1_8
+ nsCOMPtr<nsIDocShell> docShell (do_GetInterface (mWebBrowser, &rv));
+ NS_ENSURE_SUCCESS (rv, rv);
+
+ rv = docShell->GetSecurityUI (getter_AddRefs (mSecurityInfo));
+ NS_ENSURE_SUCCESS (rv, rv);
+#else
/* FIXME: mozilla sucks! nsWebBrowser already has an instance of this,
* but we cannot get to it!
* See https://bugzilla.mozilla.org/show_bug.cgi?id=94974
@@ -561,11 +568,12 @@ nsresult EphyBrowser::Init (GtkMozEmbed *mozembed)
NS_ENSURE_SUCCESS (rv, rv);
}
}
+#endif /* HAVE_GECKO_1_8 */
if (!mSecurityInfo)
{
- g_warning ("Failed to instantiate nsISecureBrowserUI!\n");
+ g_warning ("Failed to get nsISecureBrowserUI!\n");
}
-#endif
+#endif /* HAVE_MOZILLA_PSM */
mInitialized = PR_TRUE;