[Date Prev][Date Next][Thread Prev][Thread Next][Thread Index]
[XaraXtreme-commits] Commit Complete
Commit by : alex
Repository : xara
Revision : 843
Date : Wed Apr 19 23:24:18 BST 2006
Changed paths:
M /Trunk/XaraLX/Kernel/sgallery.cpp
M /Trunk/XaraLX/Kernel/sgallery.h
M /Trunk/XaraLX/Kernel/sgmenu.cpp
Fixed ENSURE & SEGV on gallery pop-up
Diff:
Index: Trunk/XaraLX/Kernel/sgmenu.cpp
===================================================================
--- Trunk/XaraLX/Kernel/sgmenu.cpp (revision 842)
+++ Trunk/XaraLX/Kernel/sgmenu.cpp (revision 843)
@@ -269,10 +269,10 @@
String_32 Bob;
Temp.Left(&Bob, 31);
- DialogBarOp* pDialogBarOp = DialogBarOp::FindDialogBarOp(Bob , GalleryBarNameLimitSize);
+ SuperGallery* pSuperGallery = SuperGallery::FindSuperGallery(Bob , GalleryBarNameLimitSize);
- if (pDialogBarOp != NULL && pDialogBarOp->IsKindOf(CC_RUNTIME_CLASS(SuperGallery)))
- return((SuperGallery *) pDialogBarOp);
+ if (pSuperGallery != NULL && pSuperGallery->IsKindOf(CC_RUNTIME_CLASS(SuperGallery)))
+ return((SuperGallery *) pSuperGallery);
// Not found, or isn't a gallery?! (eep!)
return(NULL);
Index: Trunk/XaraLX/Kernel/sgallery.cpp
===================================================================
--- Trunk/XaraLX/Kernel/sgallery.cpp (revision 842)
+++ Trunk/XaraLX/Kernel/sgallery.cpp (revision 843)
@@ -217,7 +217,7 @@
/********************************************************************************************
-> SuperGallery::SuperGallery(CCRuntimeClass *Class = CC_RUNTIME_CLASS(DialogOp)): DialogOp(_R(IDD_BLANKBAR), MODELESS,0,SAFECLASS(Class))
+> SuperGallery::SuperGallery(CCRuntimeClass *Class = CC_RUNTIME_CLASS(DialogOp)): DialogOp(_R(IDD_BLANKBAR), MODELESS,0,GSAFECLASS(Class))
Author: Jason_Williams (Xara Group Ltd) <camelotdev@xxxxxxxx>
Created: 21/10/94
@@ -225,7 +225,7 @@
********************************************************************************************/
-SuperGallery::SuperGallery(CCRuntimeClass *Class): DialogOp(_R(IDD_BLANKBAR), MODELESS,0,SAFECLASS(Class))
+SuperGallery::SuperGallery(CCRuntimeClass *Class): DialogOp(_R(IDD_BLANKBAR), MODELESS,0,GSAFECLASS(Class))
{
String_32 str = String_32(_R(IDS_K_BARS_NONAME));
Name=str;
@@ -246,7 +246,7 @@
********************************************************************************************/
SuperGallery::SuperGallery(String_32 &NewName,CCRuntimeClass *Class)
- : DialogOp(_R(IDD_BLANKBAR), MODELESS,0,SAFECLASS(Class))
+ : DialogOp(_R(IDD_BLANKBAR), MODELESS,0,GSAFECLASS(Class))
{
String_32 str = String_32(_R(IDS_K_BARS_NONAME));
Name=str;
Index: Trunk/XaraLX/Kernel/sgallery.h
===================================================================
--- Trunk/XaraLX/Kernel/sgallery.h (revision 842)
+++ Trunk/XaraLX/Kernel/sgallery.h (revision 843)
@@ -105,6 +105,7 @@
#include "sgscan.h"
#include "dlgtypes.h"
+#define GSAFECLASS(TheClass) (TheClass?TheClass:CC_RUNTIME_CLASS(DialogOp))
// Pre-declarations
class DragMessage;
Xara