Inheritance: System.EventArgs
        private void OnConnected(object sender, InstanceEventArgs e)
        {
            idleSpinner.Visible = false;
            idleSpinner.Spinning = false;

            heartTile.Style = MetroColorStyle.Lime;
            heartTile.TileImage = Resources.fontawesome_50_bright_heart;
            heartTile.Visible = true;
            heartTile.Refresh();
        }
        private void OnDisconnected(object sender, InstanceEventArgs e)
        {
            heartTile.Style = MetroColorStyle.Red;
            heartTile.Visible = true;

            idleSpinner.Style = MetroColorStyle.Red;
            idleSpinner.Visible = true;
            idleSpinner.Spinning = true;

            heartTile.Refresh();
            idleSpinner.Refresh();

            Tooltip.SetToolTip(this, "Service is currently not reachable");
        }
Example #3
0
 private void OnDisconnected(object sender, InstanceEventArgs e)
 {
     discoLabel.Text = String.Empty;
     discoTile.Style = MetroColorStyle.Orange;
     discoTile.Refresh();
     Tooltip.RemoveAll();
 }
        private void OnUnmonitored(object sender, InstanceEventArgs e)
        {
            // We need to remove the instance from the monitored pool
            var senderInstance = (ManagedInstance) sender;
            _instances.Remove(senderInstance.Id);

            senderInstance.Statistics.PropertyChanged -= OnStatisticsChanged;
            senderInstance.Unmonitored -= OnUnmonitored;
        }
 private void OnConnecting(InstanceEventArgs e)
 {
     var handler = Connecting;
     if (handler != null) handler(this, e);
 }
 protected virtual void OnUnmonitored(InstanceEventArgs e)
 {
     var handler = Unmonitored;
     if (handler != null) handler(this, e);
 }
 private void OnDisconnected(InstanceEventArgs e)
 {
     var handler = Disconnected;
     if (handler != null) handler(this, e);
 }
        private void OnUnmonitored(object sender, InstanceEventArgs e)
        {
            // We need to remove the instance from the monitored pool
            var senderInstance = (ManagedInstance) sender;

            senderInstance.Folders.CollectionChanged -= OnFolderChanged;
            senderInstance.Unmonitored -= OnUnmonitored;
        }
 private void OnDisconnected(object sender, InstanceEventArgs e)
 {
     Clear();
 }
 private void OnDisconnected(object sender, InstanceEventArgs e)
 {
     devicesTile.Text = String.Empty;
     Tooltip.RemoveAll();
 }