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

[XaraXtreme-commits] Commit Complete



Commit by  : alex
Repository : xara
Revision   : 1611
Date       : Sun Jul 30 12:22:17 BST 2006

Changed paths:
   M /Trunk/XaraLX/Kernel/swffiltr.cpp
   M /Trunk/XaraLX/Kernel/swfrndr.cpp

Fix bz r1342 flash export crash


Diff:
Index: Trunk/XaraLX/Kernel/swfrndr.cpp
===================================================================
--- Trunk/XaraLX/Kernel/swfrndr.cpp	(revision 1610)
+++ Trunk/XaraLX/Kernel/swfrndr.cpp	(revision 1611)
@@ -284,7 +284,7 @@
 	StrokeColourAttribute	*pStrokeColour	= NULL;
 	TranspFillAttribute		*pTransp		= NULL;
 	DocColour				*pColour		= NULL;
-//	FlashExportDC			*FlashDC		= ( FlashExportDC * ) RenderDC;
+//	FlashExportDC			*FlashDC		= ( FlashExportDC * ) CCDC::ConvertFromNativeDC(RenderDC);
 
 	// Step 2:	If this is the first path to be processed, mpShape will be NULL. Therefore
 	//			create a new element. Otherwise add one to the end of the existing list.
@@ -968,7 +968,7 @@
 	BOOL invalidSizeFound = FALSE;
 
 	// Step 1:	Get a device context to the Flash file.
-	FlashExportDC *pFlashDC = ( FlashExportDC * ) RenderRegion::GetRenderDC();
+	FlashExportDC *pFlashDC = ( FlashExportDC * ) CCDC::ConvertFromNativeDC(RenderRegion::GetRenderDC());
 
 	TRACEUSER( "Graeme", _T("Entering ExportAll!
") );
 	FlashBitmapRecord *pLastBitmap = NULL;
@@ -1681,7 +1681,7 @@
 {
 	BOOL				IsContone	= ( pStartColour != NULL && pEndColour != NULL );
 	WORD				BitmapID	= FlashPlaceObject::GetBitmapCount ();
-	FlashExportDC		*pFlashDC	= ( FlashExportDC * ) RenderDC;
+	FlashExportDC		*pFlashDC	= ( FlashExportDC * ) CCDC::ConvertFromNativeDC(RenderDC);
 	FlashBitmapRecord	*pRecord	= mpBitmap;
 
 	// If the bitmap has been contoned, but the underlying bitmap is a 32 bit image,
@@ -1888,7 +1888,7 @@
 	WORD				BitmapID		= FlashPlaceObject::GetBitmapCount ();
 	OILBitmap			*pBitmap		= ( pBMFill->GetBitmap () )->GetActualBitmap ();
 	DocColour			*pStartColour	= pFill->GetStartColour ();
-	FlashExportDC		*pFlashDC		= ( FlashExportDC * ) RenderDC;
+	FlashExportDC		*pFlashDC		= ( FlashExportDC * ) CCDC::ConvertFromNativeDC(RenderDC);
 //	BOOL				IsContone		= TRUE;
 //	FlashBitmapRecord	*pRecord		= mpBitmap;
 
Index: Trunk/XaraLX/Kernel/swffiltr.cpp
===================================================================
--- Trunk/XaraLX/Kernel/swffiltr.cpp	(revision 1610)
+++ Trunk/XaraLX/Kernel/swffiltr.cpp	(revision 1611)
@@ -437,7 +437,7 @@
 		// writing multiple instances to the file.
 
 		// Create a FlashRenderRegion and FlashExportDC pointers by casting the stock ones.
-		FlashExportDC		*pFDC	= ( FlashExportDC* ) pRegion->GetRenderDC ();
+		FlashExportDC		*pFDC	= ( FlashExportDC* ) CCDC::ConvertFromNativeDC(pRegion->GetRenderDC ());
 		FlashRenderRegion	*pFRR	= ( FlashRenderRegion* ) pRegion;
 
 		// Find the first node that we should export from this spread


Xara