From 3c86efbaa2959ddddaf12be27533147e1bb047ea Mon Sep 17 00:00:00 2001 From: "alecf%netscape.com" Date: Thu, 25 Jul 2002 20:02:33 +0000 Subject: [PATCH] fix for bug 159220 - make nsWindowDataSource be 64-bit friendly so we don't crash on Tru64 r=timeless, sr=brendan, a=asa git-svn-id: svn://10.0.0.236/trunk@125797 18797224-902f-48f8-a5cc-f745e15eee43 --- .../xpfe/components/windowds/nsWindowDataSource.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/mozilla/xpfe/components/windowds/nsWindowDataSource.cpp b/mozilla/xpfe/components/windowds/nsWindowDataSource.cpp index 737b87bab59..d6ee9bc5be9 100644 --- a/mozilla/xpfe/components/windowds/nsWindowDataSource.cpp +++ b/mozilla/xpfe/components/windowds/nsWindowDataSource.cpp @@ -174,7 +174,7 @@ nsWindowDataSource::OnWindowTitleChange(nsIXULWindow *window, { nsresult rv; - nsPRUint32Key key(NS_PTR_TO_INT32(window)); + nsVoidKey key(window); nsCOMPtr sup = dont_AddRef(mWindowResources.Get(&key)); @@ -225,7 +225,7 @@ nsWindowDataSource::OnOpenWindow(nsIXULWindow *window) nsCOMPtr windowResource; gRDFService->GetResource(windowId.get(), getter_AddRefs(windowResource)); - nsPRUint32Key key(NS_PTR_TO_INT32(window)); + nsVoidKey key(window); mWindowResources.Put(&key, windowResource); // assert the new window @@ -239,7 +239,7 @@ nsWindowDataSource::OnOpenWindow(nsIXULWindow *window) NS_IMETHODIMP nsWindowDataSource::OnCloseWindow(nsIXULWindow *window) { - nsPRUint32Key key(NS_PTR_TO_INT32(window)); + nsVoidKey key(window); nsCOMPtr resource; nsresult rv; @@ -329,7 +329,7 @@ struct findWindowClosure { PR_STATIC_CALLBACK(PRBool) findWindow(nsHashKey* aKey, void *aData, void* aClosure) { - nsPRUint32Key *thisKey = NS_STATIC_CAST(nsPRUint32Key*, aKey); + nsVoidKey *thisKey = NS_STATIC_CAST(nsVoidKey*, aKey); nsIRDFResource *resource = NS_STATIC_CAST(nsIRDFResource*, aData); @@ -340,7 +340,7 @@ findWindow(nsHashKey* aKey, void *aData, void* aClosure) if (resource == closure->targetResource) { closure->resultWindow = NS_STATIC_CAST(nsIXULWindow*, - NS_INT32_TO_PTR(thisKey->GetValue())); + thisKey->GetValue()); return PR_FALSE; // stop enumerating } return PR_TRUE;