Bug 216187 Windows icon association shouldn't use Mozilla application icon r=danm sr=rbs a=asa

This commit is contained in:
neil%parkwaycc.co.uk 2003-12-02 22:36:06 +00:00
Родитель 66789435b3
Коммит 6f31c6ac6f
2 изменённых файлов: 4 добавлений и 3 удалений

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

@ -101,7 +101,7 @@ static FileTypeRegistryEntry
mng( mngExts, "MozillaMNG", "MNG Image", "", "image-file.ico"), mng( mngExts, "MozillaMNG", "MNG Image", "", "image-file.ico"),
xbm( xbmExts, "MozillaXBM", "XBM Image", "xbmfile", "image-file.ico"), xbm( xbmExts, "MozillaXBM", "XBM Image", "xbmfile", "image-file.ico"),
bmp( bmpExts, "MozillaBMP", "BMP Image", "", "image-file.ico"), bmp( bmpExts, "MozillaBMP", "BMP Image", "", "image-file.ico"),
ico( icoExts, "MozillaICO", "Icon", "icofile", "image-file.ico"), ico( icoExts, "MozillaICO", "Icon", "icofile", "%1"),
xml( xmlExts, "MozillaXML", "XML Document", "xmlfile", "doc-file.ico"), xml( xmlExts, "MozillaXML", "XML Document", "xmlfile", "doc-file.ico"),
xhtml( xhtmExts, "MozillaXHTML", "XHTML Document", "", "doc-file.ico"), xhtml( xhtmExts, "MozillaXHTML", "XHTML Document", "", "doc-file.ico"),
xul( xulExts, "MozillaXUL", "Mozilla XUL Document", "", "doc-file.ico"); xul( xulExts, "MozillaXUL", "Mozilla XUL Document", "", "doc-file.ico");

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

@ -717,7 +717,7 @@ nsresult FileTypeRegistryEntry::set() {
// If we just created this file type entry, set description and default icon. // If we just created this file type entry, set description and default icon.
if ( NS_SUCCEEDED( rv ) ) { if ( NS_SUCCEEDED( rv ) ) {
nsCAutoString iconFileToUse; nsCAutoString iconFileToUse( "%1" );
nsCAutoString descKey( "Software\\Classes\\" ); nsCAutoString descKey( "Software\\Classes\\" );
descKey += protocol; descKey += protocol;
RegistryEntry descEntry( HKEY_LOCAL_MACHINE, descKey.get(), NULL, "" ); RegistryEntry descEntry( HKEY_LOCAL_MACHINE, descKey.get(), NULL, "" );
@ -735,6 +735,7 @@ nsresult FileTypeRegistryEntry::set() {
iconKey += protocol; iconKey += protocol;
iconKey += "\\DefaultIcon"; iconKey += "\\DefaultIcon";
if ( !iconFile.Equals(iconFileToUse) ) {
iconFileToUse = thisApplication() + NS_LITERAL_CSTRING( ",0" ); iconFileToUse = thisApplication() + NS_LITERAL_CSTRING( ",0" );
// Check to see if there's an icon file name associated with this extension. // Check to see if there's an icon file name associated with this extension.
@ -769,7 +770,7 @@ nsresult FileTypeRegistryEntry::set() {
iconFileToUse.Assign( buffer ); iconFileToUse.Assign( buffer );
iconFileToUse.Append( NS_LITERAL_CSTRING( ",0" ) ); iconFileToUse.Append( NS_LITERAL_CSTRING( ",0" ) );
} }
}
} }
} }
} }