[galeon] Restore myportal: functionality.
- From: Fabio Bonelli <fabiob src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [galeon] Restore myportal: functionality.
- Date: Thu, 13 May 2010 15:51:07 +0000 (UTC)
commit 0015ce89a1880d9686408205ed2f3437c661918d
Author: Fabio Bonelli <fabiob src gnome org>
Date: Thu May 13 17:48:57 2010 +0200
Restore myportal: functionality.
myportal: works again with xulrunner 1.9.
mozilla/Makefile.am | 6 +++---
mozilla/MozRegisterComponents.cpp | 4 ++--
mozilla/MyportalProtocolHandler.cpp | 8 ++++----
3 files changed, 9 insertions(+), 9 deletions(-)
---
diff --git a/mozilla/Makefile.am b/mozilla/Makefile.am
index a8f6983..8c8f3e5 100644
--- a/mozilla/Makefile.am
+++ b/mozilla/Makefile.am
@@ -127,6 +127,8 @@ libmozillaembed_la_SOURCES = \
MozillaPrivate.h \
MozRegisterComponents.cpp \
MozRegisterComponents.h \
+ MyportalProtocolHandler.cpp \
+ MyportalProtocolHandler.h \
GeckoPrintService.cpp \
GeckoPrintService.h \
GeckoPrintSession.cpp \
@@ -149,9 +151,7 @@ endif
if HAVE_NSSTRING_INTERNAL
libmozillaembed_la_SOURCES += \
GaleonAboutModule.cpp \
- GaleonAboutModule.h \
- MyportalProtocolHandler.cpp \
- MyportalProtocolHandler.h
+ GaleonAboutModule.h
endif
if HAVE_NSITOOLKITCHROMEREGISTRY_H
diff --git a/mozilla/MozRegisterComponents.cpp b/mozilla/MozRegisterComponents.cpp
index edbab09..ff9b4ec 100644
--- a/mozilla/MozRegisterComponents.cpp
+++ b/mozilla/MozRegisterComponents.cpp
@@ -85,8 +85,8 @@ NS_GENERIC_FACTORY_CONSTRUCTOR(GtkNSSSecurityWarningDialogs)
#endif
#ifdef HAVE_NSSTRING_INTERNAL
NS_GENERIC_FACTORY_CONSTRUCTOR(GaleonAboutModule)
-NS_GENERIC_FACTORY_CONSTRUCTOR(GMyportalProtocolHandler)
#endif
+NS_GENERIC_FACTORY_CONSTRUCTOR(GMyportalProtocolHandler)
#ifndef XPCOM_GLUE
NS_GENERIC_FACTORY_CONSTRUCTOR(GExternalProtocolService)
#endif
@@ -228,7 +228,6 @@ static const nsModuleComponentInfo sAppComps[] = {
GtkNSSSecurityWarningDialogsConstructor
},
#endif
-#ifdef HAVE_NSSTRING_INTERNAL
{
G_ABOUT_MYPORTAL_CLASSNAME,
G_MYPORTAL_PROTOCOL_CID,
@@ -241,6 +240,7 @@ static const nsModuleComponentInfo sAppComps[] = {
G_MYPORTAL_HANDLER_CONTRACTID,
GMyportalProtocolHandlerConstructor
},
+#ifdef HAVE_NSSTRING_INTERNAL
{
GALEON_ABOUT_TOPHER_CLASSNAME,
GALEON_ABOUT_MODULE_CID,
diff --git a/mozilla/MyportalProtocolHandler.cpp b/mozilla/MyportalProtocolHandler.cpp
index 666f13e..cec6695 100644
--- a/mozilla/MyportalProtocolHandler.cpp
+++ b/mozilla/MyportalProtocolHandler.cpp
@@ -404,10 +404,10 @@ GMyportalProtocolHandler::CreateMyportalPage (const char *path,
}
/* open the rendering stream */
- nsCOMPtr<nsIStorageStream> sStream;
-
- rv = NS_NewStorageStream(16384, (PRUint32)-1, getter_AddRefs(sStream));
- NS_ENSURE_SUCCESS (rv, rv);
+ nsCOMPtr<nsIStorageStream> sStream (do_CreateInstance("@mozilla.org/storagestream;1", &rv));
+ NS_ENSURE_SUCCESS(rv, rv);
+ rv = sStream->Init(16384, PR_UINT32_MAX, nsnull);
+ NS_ENSURE_SUCCESS(rv, rv);
rv = sStream->GetOutputStream(0, getter_AddRefs(mStream));
NS_ENSURE_SUCCESS (rv, rv);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]