remove the modal about dialog (actually, make it controllable via pref). default is about webpage as before. r=bryner

This commit is contained in:
ben%netscape.com 2000-02-06 22:36:29 +00:00
parent 516acb28c0
commit 9da29fda65

View File

@ -111,7 +111,22 @@ function goHelpMenu( url )
function goAboutDialog()
{
window.openDialog("chrome:global/content/about.xul", "About", "modal,chrome,resizable=yes,height=450,width=550");
var defaultAboutState = false;
try {
var pref = Components.classes["component://netscape/preferences"].getService();
if( pref )
pref = pref.QueryInterface( Components.interfaces.nsIPref );
defaultAboutState = pref.GetBoolPref("browser.show_about_as_stupid_modal_window");
}
catch(e) {
defaultAboutState = false;
}
if( defaultAboutState )
window.openDialog("chrome:global/content/about.xul", "About", "modal,chrome,resizable=yes,height=450,width=550");
else if( appCore )
appCore.loadUrl( "chrome://global/content/about.html" );
else
window.open( "chrome://global/content/about.html", "_blank" );
}