зеркало из https://github.com/mozilla/pjs.git
Bug 216187 Windows icon association shouldn't use Mozilla application icon r=danm sr=rbs a=asa
This commit is contained in:
Родитель
66789435b3
Коммит
6f31c6ac6f
|
@ -101,7 +101,7 @@ static FileTypeRegistryEntry
|
|||
mng( mngExts, "MozillaMNG", "MNG Image", "", "image-file.ico"),
|
||||
xbm( xbmExts, "MozillaXBM", "XBM Image", "xbmfile", "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"),
|
||||
xhtml( xhtmExts, "MozillaXHTML", "XHTML 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 ( NS_SUCCEEDED( rv ) ) {
|
||||
nsCAutoString iconFileToUse;
|
||||
nsCAutoString iconFileToUse( "%1" );
|
||||
nsCAutoString descKey( "Software\\Classes\\" );
|
||||
descKey += protocol;
|
||||
RegistryEntry descEntry( HKEY_LOCAL_MACHINE, descKey.get(), NULL, "" );
|
||||
|
@ -735,6 +735,7 @@ nsresult FileTypeRegistryEntry::set() {
|
|||
iconKey += protocol;
|
||||
iconKey += "\\DefaultIcon";
|
||||
|
||||
if ( !iconFile.Equals(iconFileToUse) ) {
|
||||
iconFileToUse = thisApplication() + NS_LITERAL_CSTRING( ",0" );
|
||||
|
||||
// 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.Append( NS_LITERAL_CSTRING( ",0" ) );
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче