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

[XaraXtreme-commits] Commit Complete



Commit by  : luke
Repository : xara
Revision   : 1498
Date       : Mon Jul 24 10:19:59 BST 2006

Changed paths:
   M /Trunk/XaraLX/Kernel/bmpexprw.cpp

Make sure the slow job is ended before leaving DoWithExportOptions


Diff:
Index: Trunk/XaraLX/Kernel/bmpexprw.cpp
===================================================================
--- Trunk/XaraLX/Kernel/bmpexprw.cpp	(revision 1497)
+++ Trunk/XaraLX/Kernel/bmpexprw.cpp	(revision 1498)
@@ -2674,15 +2674,14 @@
 pOptions->SetTempFileFlag(TRUE);
 
 	BOOL ok = TRUE;
-		
+
+	Progress	SlowJob;
+
 	try  // to export the document to the temp file
 	{
 		//no need for preview bitmap
 		m_pBmpFilter->IncludePreviewBmp(FALSE);
 
-		// start the progress bar
-		BeginSlowJob();
-		
 		// try to export the document
 		BOOL ExportedOK = TRUE;
 
@@ -2732,8 +2731,6 @@
 			 	Error::ClearError();
 			}
 
-			EndSlowJob();
-
 			return FALSE;
 		}
 	}
@@ -2750,8 +2747,6 @@
 		else
 			Error::ClearError();	// otherwise remove the error so it won't get reported
 
-		EndSlowJob();
-
 		// Make sure that the file is closed and deleted
 		try
 		{
@@ -2802,7 +2797,7 @@
 			}
 
 			// import the file
-			if (pImportFilter != NULL) 
+			if (pImportFilter != NULL)
 			{
 				// Set the preview bitmap flag to avoid adding the bitmap to the global bitmap list
 				((BaseBitmapFilter *)pImportFilter)->SetPreviewBitmap(TRUE);
@@ -2815,9 +2810,6 @@
 				// close the file
 				TempDiskFile.close();
 
-				// close the progress bar indicator
-				EndSlowJob();
-
 				if (ok)
 				{
 					// check if the bitmap is the same size, so the current view can be preserved


Xara