Tasque.Backends.IceCore.IceBackend.OnDBusNameOwnerChanged C# (CSharp) Method

OnDBusNameOwnerChanged() static private method

static private OnDBusNameOwnerChanged ( string serviceName, string oldOwner, string newOwner ) : void
serviceName string
oldOwner string
newOwner string
return void
        void OnDBusNameOwnerChanged(string serviceName,
											string oldOwner,
											string newOwner)
        {
            if (serviceName == null)
                return;

            if (serviceName.CompareTo (DaemonNamespace) != 0)
                return;

            if (oldOwner != null && oldOwner.Length > 0) {
                // The daemon just went away
                Console.WriteLine ("The ICEcore Daemon just quit.");

                // TODO: Determine whether we should force the daemon to start up again
            } else {
                // This is a new daemon
                ConnectToICEcoreDaemon ();

                // Populate the models
                Refresh ();
            }
        }