Module: wine Branch: refs/heads/master Commit: 7080c8d98ebc46fef3bedcb457e0be4643616a3d URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=7080c8d98ebc46fef3bedcb4...
Author: Jacek Caban jacek@codeweavers.com Date: Thu Feb 9 12:17:38 2006 +0100
mshtml: Better ns*String handling.
---
dlls/mshtml/mshtml_private.h | 1 + dlls/mshtml/nsembed.c | 11 +++++++++-- dlls/mshtml/nsiface.idl | 4 ++-- 3 files changed, 12 insertions(+), 4 deletions(-)
diff --git a/dlls/mshtml/mshtml_private.h b/dlls/mshtml/mshtml_private.h index 6640f90..019111e 100644 --- a/dlls/mshtml/mshtml_private.h +++ b/dlls/mshtml/mshtml_private.h @@ -151,6 +151,7 @@ void init_nsio(nsIComponentManager*,nsIC nsIURI *get_nsIURI(LPCWSTR);
nsACString *nsACString_Create(void); +PRUint32 nsACString_GetData(const nsACString*,const char**,PRBool*); void nsACString_SetData(nsACString*,const char*); void nsACString_Destroy(nsACString*);
diff --git a/dlls/mshtml/nsembed.c b/dlls/mshtml/nsembed.c index 004901e..93533af 100644 --- a/dlls/mshtml/nsembed.c +++ b/dlls/mshtml/nsembed.c @@ -50,6 +50,13 @@ struct nsStringContainer { void *d3; };
+struct nsCStringContainer { + void *v; + void *d1; + PRUint32 d2; + void *d3; +}; + static nsresult (*NS_InitXPCOM2)(nsIServiceManager**,void*,void*); static nsresult (*NS_ShutdownXPCOM)(nsIServiceManager*); static nsresult (*NS_GetComponentRegistrar)(nsIComponentRegistrar**); @@ -60,7 +67,7 @@ static nsresult (*NS_CStringContainerFin static nsresult (*NS_StringSetData)(nsAString*,const PRUnichar*,PRUint32); static nsresult (*NS_CStringSetData)(nsACString*,const char*,PRUint32); static nsresult (*NS_NewLocalFile)(const nsAString*,PRBool,nsIFile**); -static PRUint32 (*NS_CStringGetData)(nsACString*,const char**,PRBool*); +static PRUint32 (*NS_CStringGetData)(const nsACString*,const char**,PRBool*);
static HINSTANCE hXPCOM = NULL;
@@ -370,7 +377,7 @@ void nsACString_SetData(nsACString *str, NS_CStringSetData(str, data, PR_UINT32_MAX); }
-static PRUint32 nsACString_GetData(nsACString *str, const char **data, PRBool *termited) +PRUint32 nsACString_GetData(const nsACString *str, const char **data, PRBool *termited) { return NS_CStringGetData(str, data, termited); } diff --git a/dlls/mshtml/nsiface.idl b/dlls/mshtml/nsiface.idl index d97c3bd..cc2c7d0 100644 --- a/dlls/mshtml/nsiface.idl +++ b/dlls/mshtml/nsiface.idl @@ -46,9 +46,9 @@ typedef LARGE_INTEGER PRInt64; typedef ULARGE_INTEGER PRUint64; typedef PRUint64 DOMTimeStamp;
+typedef struct nsCStringContainer nsCStringContainer; typedef struct nsStringContainer nsStringContainer; -typedef nsStringContainer nsCStringContainer; -typedef nsStringContainer nsACString; +typedef nsCStringContainer nsACString; typedef nsStringContainer nsAString;
interface nsIWebBrowserChrome;