AppIndicator.Indicator:connected

"connected"             Boolean                : Read

Pretty simple, true if we have a reasonable expectation of being displayed through this object. You should hide your TrayIcon if so.