Bug 143901. Prevent null exceptions under certain conditions.

This commit is contained in:
Jim Norman 2006-01-18 23:03:35 +00:00
parent 310dc000db
commit bf2ce71f10

View File

@ -188,10 +188,17 @@ namespace Novell.CASA.GUI
} }
else else
{
//if (Common.IS_LINUX)
{ {
Glade.XML gxmlTemp = new Glade.XML(Common.GladeFile, "dialogSingleInstance", null); Glade.XML gxmlTemp = new Glade.XML(Common.GladeFile, "dialogSingleInstance", null);
gxmlTemp.Autoconnect(this); gxmlTemp.Autoconnect(this);
} }
//else
//{
// Common.FocusExistingApp();
//}
}
Logger.DbgLog("GUI:CasaMain.CasaMain() - END"); Logger.DbgLog("GUI:CasaMain.CasaMain() - END");
} }
@ -1390,22 +1397,30 @@ namespace Novell.CASA.GUI
/// ///
internal void Focus() internal void Focus()
{ {
if (windowMain != null)
windowMain.Present(); windowMain.Present();
} }
internal void Hide() internal void Hide()
{ {
if (windowMain != null)
windowMain.Visible = false; windowMain.Visible = false;
} }
internal void Show() internal void Show()
{
if (windowMain == null)
MasterPasswordAuthentication();
else
{ {
RefreshStores(); RefreshStores();
windowMain.Visible = true; windowMain.Visible = true;
} }
}
internal void Dispose() internal void Dispose()
{ {
if (windowMain != null)
windowMain.Destroy(); windowMain.Destroy();
} }