public static Spotify_Killer_Rule_Exists ( ) : bool | ||
return | bool |
private void button_add_remove_spotify_killer_Click(object sender, EventArgs e) { if (FWSpotifyKiller.Spotify_Killer_Rule_Exists()) { FWSpotifyKiller.Remove_Spotify_Killer(); } else { FWSpotifyKiller.Add_Spotify_Killer(); } update_spotify_killer_states(); }
private void update_spotify_killer_states() { bool spotify_killer_added = FWSpotifyKiller.Spotify_Killer_Rule_Exists(); bool fw_enabled = FWSpotifyKiller.Is_Firewall_Enabled(); bool spotify_killed = FWSpotifyKiller.Get_Spotify_Killer_State(); Color color_true = Color.Green; Color color_false = Color.Red; panel_spotify_killer_added.BackColor = (spotify_killer_added ? color_true : color_false); panel_firewall_enabled.BackColor = (fw_enabled ? color_true : color_false); panel_spotify_killed.BackColor = (spotify_killed ? color_true : color_false); button_add_remove_spotify_killer.Text = (spotify_killer_added ? "Remove Spotify Killer" : "Add Spotify Killer"); button_enable_disable_fw.Text = (fw_enabled ? "Disable Firewall" : "Enable Firewall"); button_kill_revive_spotify.Text = (spotify_killed ? "Revive Spotify" : "Kill Spotify"); }