epiphany r8323 - in branches/gnome-2-22: . embed/mozilla



Author: chpe
Date: Mon Jun 30 18:22:04 2008
New Revision: 8323
URL: http://svn.gnome.org/viewvc/epiphany?rev=8323&view=rev

Log:
Check for nsIBadCertListener.h.

Modified:
   branches/gnome-2-22/configure.ac
   branches/gnome-2-22/embed/mozilla/EphyHeaderSniffer.cpp
   branches/gnome-2-22/embed/mozilla/GtkNSSDialogs.cpp
   branches/gnome-2-22/embed/mozilla/GtkNSSDialogs.h
   branches/gnome-2-22/embed/mozilla/Makefile.am
   branches/gnome-2-22/embed/mozilla/MozDownload.cpp

Modified: branches/gnome-2-22/configure.ac
==============================================================================
--- branches/gnome-2-22/configure.ac	(original)
+++ branches/gnome-2-22/configure.ac	Mon Jun 30 18:22:04 2008
@@ -378,6 +378,10 @@
 GECKO_CHECK_HEADERS([spellchecker],[mozISpellCheckingEngine.h],
 	[have_gecko_spell_checker=yes],[have_gecko_spell_checker=no])
 
+# Check for nsIBadCertListener (gecko 1.8 or forwardported to 1.9 e.g. on debian)
+
+GECKO_CHECK_HEADERS([],[nsIBadCertListener.h],[have_nsibadcertlistener=yes],[have_nsibadcertlistener=no])
+
 # Check for some contractIDs that we need but are provided by extensions
 # which may or may not have been built.
 
@@ -394,6 +398,7 @@
 AM_CONDITIONAL([HAVE_XULRUNNER],[test "$gecko_cv_gecko" = "xulrunner" -o "$gecko_cv_gecko" = "libxul" -o "$gecko_cv_gecko" = "libxul-embedding"])
 AM_CONDITIONAL([HAVE_MOZILLA_PSM],[test "$enable_psm" = "yes" -a "$have_psm" = "yes"])
 AM_CONDITIONAL([ENABLE_FILEPICKER],[test "$enable_filepicker" = "yes"])
+AM_CONDITIONAL([HAVE_NSIBADCERTLISTENER_H],[test "$have_nsibadcertlistener" = "yes"])
 
 # *********
 # Xulrunner

Modified: branches/gnome-2-22/embed/mozilla/EphyHeaderSniffer.cpp
==============================================================================
--- branches/gnome-2-22/embed/mozilla/EphyHeaderSniffer.cpp	(original)
+++ branches/gnome-2-22/embed/mozilla/EphyHeaderSniffer.cpp	Mon Jun 30 18:22:04 2008
@@ -72,7 +72,7 @@
 #include "ephy-gui.h"
 #include "ephy-prefs.h"
 
-#ifndef HAVE_GECKO_1_9
+#ifdef HAVE_NSIBADCERTLISTENER_H
 #include "EphyBadCertRejector.h"
 #endif
 #include "MozDownload.h"
@@ -224,7 +224,7 @@
 NS_IMETHODIMP
 EphyHeaderSniffer::GetInterface(const nsIID & uuid, void * *result)
 {
-#ifndef HAVE_GECKO_1_9
+#ifdef HAVE_NSIBADCERTLISTENER_H
 	if (uuid.Equals (NS_GET_IID (nsIBadCertListener)) &&
 	    mEmbedPersist)
 	{

Modified: branches/gnome-2-22/embed/mozilla/GtkNSSDialogs.cpp
==============================================================================
--- branches/gnome-2-22/embed/mozilla/GtkNSSDialogs.cpp	(original)
+++ branches/gnome-2-22/embed/mozilla/GtkNSSDialogs.cpp	Mon Jun 30 18:22:04 2008
@@ -110,7 +110,7 @@
 {
 }
 
-#ifdef HAVE_GECKO_1_9
+#ifndef HAVE_NSIBADCERTLISTENER_H
 NS_IMPL_THREADSAFE_ISUPPORTS4 (GtkNSSDialogs,
 			       nsITokenPasswordDialogs,
 			       nsICertificateDialogs,
@@ -217,7 +217,7 @@
 	}
 }
 
-#ifndef HAVE_GECKO_1_9
+#ifdef HAVE_NSIBADCERTLISTENER_H
 /**
  *  Display a dialog box, showing 'View Certificate', 'Cancel',
  *  and 'Accept' buttons. Optionally a checkbox can be shown,
@@ -321,7 +321,7 @@
 	gtk_widget_destroy (dialog);
         return res;
 }
-#endif /* HAVE_GECKO_1_9 */
+#endif /* HAVE_NSIBADCERTLISTENER_H */
 
 /* Helper functions */
 
@@ -389,7 +389,7 @@
 	return NS_OK;
 }
   
-#ifndef HAVE_GECKO_1_9
+#ifdef HAVE_NSIBADCERTLISTENER_H
 
 NS_IMETHODIMP
 GtkNSSDialogs::ConfirmMismatchDomain (nsIInterfaceRequestor *ctx,
@@ -606,7 +606,7 @@
 	return NS_OK;
 }
 
-#endif /* HAVE_GECKO_1_9 */
+#endif /* HAVE_NSIBADCERTLISTENER_H */
 
 NS_IMETHODIMP 
 GtkNSSDialogs::ConfirmDownloadCACert(nsIInterfaceRequestor *ctx, 

Modified: branches/gnome-2-22/embed/mozilla/GtkNSSDialogs.h
==============================================================================
--- branches/gnome-2-22/embed/mozilla/GtkNSSDialogs.h	(original)
+++ branches/gnome-2-22/embed/mozilla/GtkNSSDialogs.h	Mon Jun 30 18:22:04 2008
@@ -22,7 +22,7 @@
 #ifndef GTKNSSDIALOGS_H
 #define GTKNSSDIALOGS_H 1
 
-#ifndef HAVE_GECKO_1_9
+#ifdef HAVE_NSIBADCERTLISTENER_H
 #include <nsIBadCertListener.h>
 #endif
 #include <nsICertificateDialogs.h>
@@ -40,7 +40,7 @@
 #define GTK_NSSDIALOGS_CLASSNAME  "Gtk NSS Dialogs"
 
 class GtkNSSDialogs : public nsICertificateDialogs,
-#ifndef HAVE_GECKO_1_9
+#ifdef HAVE_NSIBADCERTLISTENER_H
                       public nsIBadCertListener,
 #endif
 		      public nsITokenPasswordDialogs,
@@ -50,7 +50,7 @@
   public:
     NS_DECL_ISUPPORTS
     NS_DECL_NSICERTIFICATEDIALOGS
-#ifndef HAVE_GECKO_1_9
+#ifdef HAVE_NSIBADCERTLISTENER_H
     NS_DECL_NSIBADCERTLISTENER
 #endif
     NS_DECL_NSITOKENPASSWORDDIALOGS

Modified: branches/gnome-2-22/embed/mozilla/Makefile.am
==============================================================================
--- branches/gnome-2-22/embed/mozilla/Makefile.am	(original)
+++ branches/gnome-2-22/embed/mozilla/Makefile.am	Mon Jun 30 18:22:04 2008
@@ -64,6 +64,13 @@
 	mozilla-notifiers.cpp		\
 	mozilla-notifiers.h
 
+if HAVE_NSIBADCERTLISTENER_H
+libephymozillaembed_la_SOURCES += 	\
+	EphyBadCertRejector.cpp		\
+	EphyBadCertRejector.h		\
+	$(NULL)
+endif
+
 if HAVE_GECKO_1_9
 libephymozillaembed_la_SOURCES += \
 	EphyXULAppInfo.cpp		\
@@ -73,8 +80,6 @@
 
 if !HAVE_GECKO_1_9
 libephymozillaembed_la_SOURCES += 	\
-	EphyBadCertRejector.cpp		\
-	EphyBadCertRejector.h		\
 	EphyDirectoryProvider.cpp       \
 	EphyDirectoryProvider.h		\
 	$(NULL)

Modified: branches/gnome-2-22/embed/mozilla/MozDownload.cpp
==============================================================================
--- branches/gnome-2-22/embed/mozilla/MozDownload.cpp	(original)
+++ branches/gnome-2-22/embed/mozilla/MozDownload.cpp	Mon Jun 30 18:22:04 2008
@@ -71,7 +71,7 @@
 #include <nsNetError.h>
 #include <nsServiceManagerUtils.h>
 
-#ifndef HAVE_GECKO_1_9
+#ifdef HAVE_NSIBADCERTLISTENER_H
 #include "EphyBadCertRejector.h"
 #endif
 
@@ -533,7 +533,7 @@
 NS_IMETHODIMP
 MozDownload::GetInterface(const nsIID & uuid, void * *result)
 {
-#ifndef HAVE_GECKO_1_9
+#ifdef HAVE_NSIBADCERTLISTENER_H
 	if (uuid.Equals (NS_GET_IID (nsIBadCertListener)) &&
 	    mEmbedPersist)
 	{



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]