Check if the systray is initialized before hiding the main frame

sip-call-params
Ingo Bauersachs 10 years ago
parent d258eaf5fd
commit 6989eab74e

@ -1920,7 +1920,8 @@ protected void windowClosing(WindowEvent event)
// On Mac systems the application is not quited on window close, so we
// don't need to warn the user.
if (!GuiActivator.getUIService().getExitOnMainWindowClose()
&& !OSUtils.IS_MAC)
&& !OSUtils.IS_MAC
&& GuiActivator.getSystrayService().checkInitialized())
{
SwingUtilities.invokeLater(new Runnable()
{

@ -469,7 +469,8 @@ else if (originalDockImage != null)
}
}
private boolean checkInitialized()
@Override
public boolean checkInitialized()
{
if (!initialized)
logger.error("Systray not init");

@ -129,4 +129,10 @@ public PopupMessageHandler setActivePopupMessageHandler(
* Selects the best available popup message handler
*/
public void selectBestPopupMessageHandler();
/**
* Checks if the systray icon has been initialized.
* @return True if the systray is initialized, false otherwise.
*/
public boolean checkInitialized();
}

Loading…
Cancel
Save