Stopped using macros to access fields of struct that were longer than the actual struct field names.

This commit is contained in:
sdagley%netscape.com 1998-10-14 06:01:36 +00:00
Родитель 9ff0a65088
Коммит 606e8a2f62
2 изменённых файлов: 8 добавлений и 8 удалений

Просмотреть файл

@ -290,7 +290,7 @@ void CURLDispatcher::DispatchToDiskAsText(CURLDispatchInfo* inDispatchInfo)
if ((theErr != noErr) && (theErr != dupFNErr)) if ((theErr != noErr) && (theErr != dupFNErr))
ThrowIfOSErr_(theErr); ThrowIfOSErr_(theErr);
CFileMgr::FileSetComment(destSpec, NET_URLStruct_Address(inURL)); CFileMgr::FileSetComment(destSpec, inURL->address);
char* thePath = CFileMgr::EncodedPathNameFromFSSpec(destSpec, TRUE); char* thePath = CFileMgr::EncodedPathNameFromFSSpec(destSpec, TRUE);
ThrowIfNULL_(thePath); ThrowIfNULL_(thePath);
@ -840,7 +840,7 @@ CURLDispatchInfo::CURLDispatchInfo(
#endif #endif
if (inURLStruct) if (inURLStruct)
mURLType = NET_URL_Type(NET_URLStruct_Address(inURLStruct)); mURLType = NET_URL_Type(inURLStruct->address);
else else
mURLType = 0; mURLType = 0;
} }
@ -863,7 +863,7 @@ URL_Struct* CURLDispatchInfo::ReleaseURLStruct()
char* CURLDispatchInfo::GetURL() char* CURLDispatchInfo::GetURL()
{ {
if (mURLStruct) if (mURLStruct)
return NET_URLStruct_Address(mURLStruct); return mURLStruct->address;
else else
return NULL; return NULL;
} }

Просмотреть файл

@ -823,7 +823,7 @@ CMimeMapper* CreateUnknownMimeTypeMapper( URL_Struct* request )
// Notify the user with nice names // Notify the user with nice names
newName = CFileMgr::FileNameFromURL( request->address ); newName = CFileMgr::FileNameFromURL( request->address );
fileName = newName; fileName = newName;
content_type = NET_URLStruct_ContentType( request ); content_type = request->content_type;
::ParamText( newName, content_type, CStr255::sEmptyString, CStr255::sEmptyString ); ::ParamText( newName, content_type, CStr255::sEmptyString, CStr255::sEmptyString );
@ -837,14 +837,14 @@ CMimeMapper* CreateUnknownMimeTypeMapper( URL_Struct* request )
case ALRT_UnknownMimeType_Cancel: case ALRT_UnknownMimeType_Cancel:
return NULL; return NULL;
case ALRT_UnknownMimeType_Save: case ALRT_UnknownMimeType_Save:
mapper = CPrefs::CreateDefaultUnknownMapper( NET_URLStruct_ContentType(request), TRUE ); mapper = CPrefs::CreateDefaultUnknownMapper( request->content_type, TRUE );
mapper->SetLoadAction( CMimeMapper::Save ); mapper->SetLoadAction( CMimeMapper::Save );
return mapper; return mapper;
case ALRT_UnknownMimeType_PickApp: case ALRT_UnknownMimeType_PickApp:
StandardFileReply reply; StandardFileReply reply;
CFilePicker::DoCustomGetFile( reply, CFilePicker::Applications, FALSE ); CFilePicker::DoCustomGetFile( reply, CFilePicker::Applications, FALSE );
if ( reply.sfGood ) if ( reply.sfGood )
mapper = CPrefs::CreateDefaultAppMapper( reply.sfFile,NET_URLStruct_ContentType(request), TRUE ); mapper = CPrefs::CreateDefaultAppMapper( reply.sfFile, request->content_type, TRUE );
return mapper; return mapper;
case ALRT_UnknownMimeType_MoreInfo: case ALRT_UnknownMimeType_MoreInfo:
{ {
@ -855,7 +855,7 @@ CMimeMapper* CreateUnknownMimeTypeMapper( URL_Struct* request )
cstring url; cstring url;
url = (const char*) string; // cstringÕs operator= expects unsigned char* to be a P string, so we have to cast url = (const char*) string; // cstringÕs operator= expects unsigned char* to be a P string, so we have to cast
url += "?"; url += "?";
url += NET_URLStruct_ContentType( request ); url += request->content_type;
AppleEvent getURLEvent; AppleEvent getURLEvent;
UAppleEventsMgr::MakeAppleEvent( AE_url_suite, AE_url_getURL, getURLEvent ); UAppleEventsMgr::MakeAppleEvent( AE_url_suite, AE_url_getURL, getURLEvent );
@ -889,7 +889,7 @@ NET_StreamClass * NewFilePipe (
// 97-06-15 pkc -- We really should make a function to determine if a URL is a // 97-06-15 pkc -- We really should make a function to determine if a URL is a
// mail attachment instead of duplicating this code. // mail attachment instead of duplicating this code.
const char* urlAddress = request ? NET_URLStruct_Address(request) : nil; const char* urlAddress = request ? request->address : nil;
Boolean isMailMessage = false; Boolean isMailMessage = false;
if (urlAddress) if (urlAddress)
{ {