X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/5b781a6729859abc77e6ca5b1f81cbaad974a78f..61cca9d24ee3f935f2581e3cfb894e46181290e6:/src/mac/carbon/dirdlg.cpp diff --git a/src/mac/carbon/dirdlg.cpp b/src/mac/carbon/dirdlg.cpp index 51f4df142e..89b3892451 100644 --- a/src/mac/carbon/dirdlg.cpp +++ b/src/mac/carbon/dirdlg.cpp @@ -20,7 +20,11 @@ #include "wx/cmndata.h" -#include "Navigation.h" +#if defined(__UNIX__) + #include +#else + #include +#endif #if !USE_SHARED_LIBRARY IMPLEMENT_CLASS(wxDirDialog, wxDialog) @@ -178,7 +182,7 @@ static Boolean SameFSSpec(FSSpecPtr spec1, FSSpecPtr spec2) // flashing of the button when the key is hit static pascal Boolean SFGetFolderModalDialogFilter(DialogPtr theDlgPtr, EventRecord *eventRec, - short *item, Ptr dataPtr) + short *item, void *dataPtr) { #pragma unused (dataPtr) @@ -206,7 +210,7 @@ static pascal Boolean SFGetFolderModalDialogFilter(DialogPtr theDlgPtr, EventRec // MyDlgHook is a hook routine that maps the select button to Open // and sets the Select button name -static pascal short SFGetFolderDialogHook(short item, DialogPtr theDlgPtr, Ptr dataPtr) +static pascal short SFGetFolderDialogHook(short item, DialogPtr theDlgPtr, void *dataPtr) { UserDataRecPtr theUserDataRecPtr; long desktopDirID; @@ -418,7 +422,7 @@ void StandardGetFolder( ConstStr255Param message , ConstStr255Param path , FileF } } -static pascal Boolean OnlyVisibleFoldersCustomFileFilter(CInfoPBPtr myCInfoPBPtr, Ptr dataPtr) +static pascal Boolean OnlyVisibleFoldersCustomFileFilter(CInfoPBPtr myCInfoPBPtr, void *dataPtr) { #pragma unused (dataPtr) @@ -457,11 +461,18 @@ int wxDirDialog::ShowModal() Str255 prompt ; Str255 path ; +#if TARGET_CARBON + c2pstrcpy((StringPtr)prompt, m_message) ; +#else strcpy((char *)prompt, m_message) ; c2pstr((char *)prompt ) ; - +#endif +#if TARGET_CARBON + c2pstrcpy((StringPtr)path, m_path ) ; +#else strcpy((char *)path, m_path ) ; c2pstr((char *)path ) ; +#endif StandardFileReply reply ; FileFilterYDUPP invisiblesExcludedCustomFilterUPP = 0 ;