зеркало из https://github.com/mozilla/pjs.git
Fix bugs 51368 and 51372 -- use InternetConfig.h from Universal Headers, renaming the IC SDK folder so that CodeWarrior does not search within it. r=pchen
This commit is contained in:
Родитель
5340ae2947
Коммит
e12ee16abf
|
@ -270,6 +270,16 @@ sub ConfigureBuildSystem()
|
|||
$UNIVERSAL_INTERFACES_VERSION = 0x0330;
|
||||
}
|
||||
|
||||
#// Rename IC SDK folder in the Mac OS Support folder
|
||||
my($ic_sdk_folder) = getCodeWarriorPath("MacOS Support:ICProgKit2.0.2");
|
||||
if( -e $ic_sdk_folder)
|
||||
{
|
||||
my($new_ic_folder_name) = getCodeWarriorPath("MacOS Support:(ICProgKit2.0.2)");
|
||||
rename ($ic_sdk_folder, $new_ic_folder_name);
|
||||
# note that CodeWarrior doesn't descnet into folders with () the name
|
||||
print "Mozilla no longer needs the Internet Config SDK to build:\n Renaming the 'ICProgKit2.0.2' folder to '(ICProgKit2.0.2)'\n";
|
||||
}
|
||||
|
||||
printf("UNIVERSAL_INTERFACES_VERSION = 0x%04X\n", $UNIVERSAL_INTERFACES_VERSION);
|
||||
|
||||
my($line, $config, $oldconfig, $define, $definevalue, $defines);
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include "nsInternetConfig.h"
|
||||
#include "nsString.h"
|
||||
#include "nsDebug.h"
|
||||
|
||||
#include <CodeFragments.h>
|
||||
#include <Processes.h>
|
||||
ICInstance nsInternetConfig::sInstance = NULL;
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
*
|
||||
* Contributor(s):
|
||||
*/
|
||||
#include "InternetConfig.h"
|
||||
#include <InternetConfig.h>
|
||||
#include "PRTypes.h"
|
||||
#include "nsError.h"
|
||||
|
||||
|
|
|
@ -22,8 +22,8 @@
|
|||
|
||||
#include "nsMacMIMEDataSource.h"
|
||||
#include "nsString.h"
|
||||
#include "MacTypes.h"
|
||||
#include "InternetConfig.h"
|
||||
|
||||
#include <MacTypes.h>
|
||||
|
||||
// Yumm
|
||||
static void ConvertCharStringToStr255( char* inString, Str255& outString )
|
||||
|
@ -48,16 +48,16 @@ static nsresult MakeMIMEInfo( ICMapEntry &entry, nsIMIMEInfo*& info )
|
|||
if ( NS_FAILED( rv ) )
|
||||
return rv;
|
||||
// Stuff in the data;
|
||||
info->SetMacCreator( entry.file_type );
|
||||
info->SetMacType( entry.file_creator);
|
||||
info->SetMacCreator( entry.fileType );
|
||||
info->SetMacType( entry.fileCreator);
|
||||
|
||||
nsCString description( (char*)&entry.entry_name[1], entry.entry_name[0]);
|
||||
nsCString description( (char*)&entry.entryName[1], entry.entryName[0]);
|
||||
nsString unicodeDescription;
|
||||
unicodeDescription.AssignWithConversion ( description );
|
||||
info->SetDescription( unicodeDescription.GetUnicode() );
|
||||
|
||||
|
||||
nsCString mimetype((char*) &entry.MIME_type[1], entry.MIME_type[0] );
|
||||
nsCString mimetype((char*) &entry.MIMEType[1], entry.MIMEType[0] );
|
||||
info->SetMIMEType( mimetype.GetBuffer() );
|
||||
|
||||
// remove the .
|
||||
|
@ -95,7 +95,7 @@ NS_IMETHODIMP nsMacMIMEDataSource::GetFromExtension(const char *aFileExt, nsIMIM
|
|||
Str255 pFileName;
|
||||
ConvertCharStringToStr255( filename, pFileName );
|
||||
ICMapEntry entry;
|
||||
ICError err = ::ICMapFilename( instance, pFileName, &entry );
|
||||
OSStatus err = ::ICMapFilename( instance, pFileName, &entry );
|
||||
if( err == noErr )
|
||||
{
|
||||
rv = MakeMIMEInfo( entry, *_retval );
|
||||
|
@ -116,7 +116,7 @@ NS_IMETHODIMP nsMacMIMEDataSource::GetFromTypeCreator(PRUint32 aType, PRUint32 a
|
|||
Str255 pFileName;
|
||||
ConvertCharStringToStr255( filename, pFileName );
|
||||
ICMapEntry entry;
|
||||
ICError err = ::ICMapTypeCreator( instance, aType, aCreator, pFileName, &entry );
|
||||
OSStatus err = ::ICMapTypeCreator( instance, aType, aCreator, pFileName, &entry );
|
||||
if( err == noErr )
|
||||
{
|
||||
rv = MakeMIMEInfo( entry, *_retval );
|
||||
|
|
|
@ -31,7 +31,7 @@
|
|||
#include "nsVoidArray.h"
|
||||
#include "nsStringUtil.h"
|
||||
|
||||
#include <ICAPI.h>
|
||||
#include <InternetConfig.h>
|
||||
|
||||
#include "nsMacControl.h"
|
||||
#include "nsCarbonHelpers.h"
|
||||
|
@ -445,7 +445,7 @@ nsFilePicker :: MapFilterToFileTypes ( )
|
|||
{
|
||||
OSType tempOSType;
|
||||
ICInstance icInstance;
|
||||
ICError icErr;
|
||||
OSStatus icErr;
|
||||
Handle mappings = NewHandleClear(4);
|
||||
ICAttr attr;
|
||||
ICMapEntry icEntry;
|
||||
|
@ -520,7 +520,7 @@ nsFilePicker :: MapFilterToFileTypes ( )
|
|||
if (icErr != icPrefNotFoundErr)
|
||||
{
|
||||
bool addToList = true;
|
||||
tempOSType = icEntry.file_type;
|
||||
tempOSType = icEntry.fileType;
|
||||
for (PRUint32 typeIndex = 0; typeIndex < typesInThisFilter; typeIndex++)
|
||||
{
|
||||
if (mTypeLists[loop1]->osType[typeIndex] == tempOSType)
|
||||
|
|
|
@ -23,6 +23,7 @@
|
|||
#include "nsInternetConfig.h"
|
||||
#include "nsString.h"
|
||||
#include "nsDebug.h"
|
||||
|
||||
#include <CodeFragments.h>
|
||||
#include <Processes.h>
|
||||
ICInstance nsInternetConfig::sInstance = NULL;
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
*
|
||||
* Contributor(s):
|
||||
*/
|
||||
#include "InternetConfig.h"
|
||||
#include <InternetConfig.h>
|
||||
#include "PRTypes.h"
|
||||
#include "nsError.h"
|
||||
|
||||
|
|
|
@ -22,8 +22,8 @@
|
|||
|
||||
#include "nsMacMIMEDataSource.h"
|
||||
#include "nsString.h"
|
||||
#include "MacTypes.h"
|
||||
#include "InternetConfig.h"
|
||||
|
||||
#include <MacTypes.h>
|
||||
|
||||
// Yumm
|
||||
static void ConvertCharStringToStr255( char* inString, Str255& outString )
|
||||
|
@ -48,16 +48,16 @@ static nsresult MakeMIMEInfo( ICMapEntry &entry, nsIMIMEInfo*& info )
|
|||
if ( NS_FAILED( rv ) )
|
||||
return rv;
|
||||
// Stuff in the data;
|
||||
info->SetMacCreator( entry.file_type );
|
||||
info->SetMacType( entry.file_creator);
|
||||
info->SetMacCreator( entry.fileType );
|
||||
info->SetMacType( entry.fileCreator);
|
||||
|
||||
nsCString description( (char*)&entry.entry_name[1], entry.entry_name[0]);
|
||||
nsCString description( (char*)&entry.entryName[1], entry.entryName[0]);
|
||||
nsString unicodeDescription;
|
||||
unicodeDescription.AssignWithConversion ( description );
|
||||
info->SetDescription( unicodeDescription.GetUnicode() );
|
||||
|
||||
|
||||
nsCString mimetype((char*) &entry.MIME_type[1], entry.MIME_type[0] );
|
||||
nsCString mimetype((char*) &entry.MIMEType[1], entry.MIMEType[0] );
|
||||
info->SetMIMEType( mimetype.GetBuffer() );
|
||||
|
||||
// remove the .
|
||||
|
@ -95,7 +95,7 @@ NS_IMETHODIMP nsMacMIMEDataSource::GetFromExtension(const char *aFileExt, nsIMIM
|
|||
Str255 pFileName;
|
||||
ConvertCharStringToStr255( filename, pFileName );
|
||||
ICMapEntry entry;
|
||||
ICError err = ::ICMapFilename( instance, pFileName, &entry );
|
||||
OSStatus err = ::ICMapFilename( instance, pFileName, &entry );
|
||||
if( err == noErr )
|
||||
{
|
||||
rv = MakeMIMEInfo( entry, *_retval );
|
||||
|
@ -116,7 +116,7 @@ NS_IMETHODIMP nsMacMIMEDataSource::GetFromTypeCreator(PRUint32 aType, PRUint32 a
|
|||
Str255 pFileName;
|
||||
ConvertCharStringToStr255( filename, pFileName );
|
||||
ICMapEntry entry;
|
||||
ICError err = ::ICMapTypeCreator( instance, aType, aCreator, pFileName, &entry );
|
||||
OSStatus err = ::ICMapTypeCreator( instance, aType, aCreator, pFileName, &entry );
|
||||
if( err == noErr )
|
||||
{
|
||||
rv = MakeMIMEInfo( entry, *_retval );
|
||||
|
|
Загрузка…
Ссылка в новой задаче