diff options
author | Jean-François Rameau <jframeau@cvs.gnome.org> | 2006-03-03 21:57:27 +0800 |
---|---|---|
committer | Jean-François Rameau <jframeau@src.gnome.org> | 2006-03-03 21:57:27 +0800 |
commit | 7bb807425a00d571949c378e8bdf2edcf6ecb40a (patch) | |
tree | 9e2b7686dc572e6d96fe2648c76057da609217af | |
parent | 846c58ecb9f38d453a898749a0eb8e82b27c51bd (diff) | |
download | gsoc2013-epiphany-7bb807425a00d571949c378e8bdf2edcf6ecb40a.tar gsoc2013-epiphany-7bb807425a00d571949c378e8bdf2edcf6ecb40a.tar.gz gsoc2013-epiphany-7bb807425a00d571949c378e8bdf2edcf6ecb40a.tar.bz2 gsoc2013-epiphany-7bb807425a00d571949c378e8bdf2edcf6ecb40a.tar.lz gsoc2013-epiphany-7bb807425a00d571949c378e8bdf2edcf6ecb40a.tar.xz gsoc2013-epiphany-7bb807425a00d571949c378e8bdf2edcf6ecb40a.tar.zst gsoc2013-epiphany-7bb807425a00d571949c378e8bdf2edcf6ecb40a.zip |
Sync Epiphany with new nsIGlobalHistory3 stuff.
2006-03-03 Jean-François Rameau <jframeau@cvs.gnome.org>
* configure.ac:
* embed/mozilla/GlobalHistory.h:
* embed/mozilla/GlobalHistory.cpp:
Sync Epiphany with new nsIGlobalHistory3 stuff.
* embed/mozilla/EphyContentPolicy.cpp: (GetEmbedFromContext):
Fix a missing return.
-rw-r--r-- | ChangeLog | 12 | ||||
-rw-r--r-- | configure.ac | 4 | ||||
-rw-r--r-- | embed/mozilla/EphyContentPolicy.cpp | 2 | ||||
-rw-r--r-- | embed/mozilla/GlobalHistory.cpp | 25 | ||||
-rw-r--r-- | embed/mozilla/GlobalHistory.h | 11 |
5 files changed, 50 insertions, 4 deletions
@@ -1,3 +1,15 @@ +2006-03-03 Jean-François Rameau <jframeau@cvs.gnome.org> + + * configure.ac: + * embed/mozilla/GlobalHistory.h: + * embed/mozilla/GlobalHistory.cpp: + + Sync Epiphany with new nsIGlobalHistory3 stuff. + + * embed/mozilla/EphyContentPolicy.cpp: (GetEmbedFromContext): + + Fix a missing return. + 2006-03-02 Christian Persch <chpe@cvs.gnome.org> * embed/mozilla/EphyContentPolicy.cpp: diff --git a/configure.ac b/configure.ac index a89d3ccc9..1061cefe7 100644 --- a/configure.ac +++ b/configure.ac @@ -361,6 +361,10 @@ fi GECKO_CHECK_CONTRACTIDS([$REQUIRED_CONTRACTS], [],[AC_MSG_ERROR([$gecko_cv_gecko needs to be compiled with at least --enable-extensions=default,$REQUIRED_EXTENSIONS])]) +# Check for nsIGlobalHistory3 + +GECKO_CHECK_HEADERS([docshell],[nsIGlobalHistory3.h]) + # Needed since 1.8b2 # Define this down here so it doesn't affect the API checks above diff --git a/embed/mozilla/EphyContentPolicy.cpp b/embed/mozilla/EphyContentPolicy.cpp index 137b8ae89..436ec0786 100644 --- a/embed/mozilla/EphyContentPolicy.cpp +++ b/embed/mozilla/EphyContentPolicy.cpp @@ -101,7 +101,7 @@ EphyContentPolicy::GetEmbedFromContext (nsISupports *aContext) NS_ENSURE_TRUE (window, NULL); GtkWidget *embed = EphyUtils::FindEmbed (window); - if (!EPHY_IS_EMBED (embed)) NULL; + if (!EPHY_IS_EMBED (embed)) return NULL; return embed; } diff --git a/embed/mozilla/GlobalHistory.cpp b/embed/mozilla/GlobalHistory.cpp index 841fdf031..257f55506 100644 --- a/embed/mozilla/GlobalHistory.cpp +++ b/embed/mozilla/GlobalHistory.cpp @@ -35,7 +35,11 @@ #define MAX_TITLE_LENGTH 2048 #define MAX_URL_LENGTH 16384 -NS_IMPL_ISUPPORTS1 (MozGlobalHistory, nsIGlobalHistory2) +#ifdef HAVE_NSIGLOBALHISTORY3_H +NS_IMPL_ISUPPORTS2 (MozGlobalHistory, nsIGlobalHistory2, nsIGlobalHistory3) +#else +NS_IMPL_ISUPPORTS2 (MozGlobalHistory, nsIGlobalHistory2) +#endif /* HAVE_NSIGLOBALHISTORY3_H */ MozGlobalHistory::MozGlobalHistory () { @@ -156,7 +160,7 @@ NS_IMETHODIMP MozGlobalHistory::SetPageTitle(nsIURI *aURI, return NS_OK; } -#ifdef HAVE_GECKO_1_9 +#ifdef HAVE_NSIGLOBALHISTORY3_H /* unsigned long getURIGeckoFlags(in nsIURI aURI); */ NS_IMETHODIMP MozGlobalHistory::GetURIGeckoFlags(nsIURI *aURI, @@ -209,4 +213,19 @@ MozGlobalHistory::SetURIGeckoFlags(nsIURI *aURI, return NS_ERROR_FAILURE; } -#endif /* HAVE_GECKO_1_9 */ + +/* void addDocumentRedirect (in nsIChannel + aOldChannel, + in nsIChannel aNewChannel, + in PRInt32 aFlags, + in boolean aTopLevel); */ +NS_IMETHODIMP +MozGlobalHistory::AddDocumentRedirect(nsIChannel *aOldChannel, + nsIChannel *aNewChannel, + PRInt32 aFlags, + PRBool aTopLevel) +{ + return NS_ERROR_NOT_IMPLEMENTED; +} + +#endif /* HAVE_NSIGLOBALHISTORY3_H */ diff --git a/embed/mozilla/GlobalHistory.h b/embed/mozilla/GlobalHistory.h index 992819a1e..edb01db5e 100644 --- a/embed/mozilla/GlobalHistory.h +++ b/embed/mozilla/GlobalHistory.h @@ -24,7 +24,11 @@ #include "ephy-history.h" +#ifdef HAVE_NSIGLOBALHISTORY3_H +#include <nsIGlobalHistory3.h> +#else #include <nsIGlobalHistory2.h> +#endif /* HAVE_NSIGLOBALHISTORY3_H */ #include <nsCOMPtr.h> #include <nsAutoPtr.h> @@ -40,7 +44,11 @@ { 0xb7, 0x9e, 0xf7, 0xaa, 0x49, 0xeb, 0x6a, 0x15} \ } +#ifdef HAVE_NSIGLOBALHISTORY3_H +class MozGlobalHistory: public nsIGlobalHistory3 +#else class MozGlobalHistory: public nsIGlobalHistory2 +#endif /* HAVE_NSIGLOBALHISTORY3_H */ { public: MozGlobalHistory (); @@ -48,6 +56,9 @@ class MozGlobalHistory: public nsIGlobalHistory2 NS_DECL_ISUPPORTS NS_DECL_NSIGLOBALHISTORY2 +#ifdef HAVE_NSIGLOBALHISTORY3_H + NS_DECL_NSIGLOBALHISTORY3 +#endif /* HAVE_NSIGLOBALHISTORY3_H */ private: EphyHistory *mGlobalHistory; |