From 4371b939b006672d0bf8c11f95ba414b01724638 Mon Sep 17 00:00:00 2001 From: nooperation Date: Sat, 18 Jul 2015 00:37:47 -0400 Subject: [PATCH] Refactoring RAD-498 for consistency --- Radegast/GUI/Consoles/GroupIMTabWindow.cs | 33 +++++++++++++++---------------- 1 file changed, 16 insertions(+), 17 deletions(-) diff --git a/Radegast/GUI/Consoles/GroupIMTabWindow.cs b/Radegast/GUI/Consoles/GroupIMTabWindow.cs index b757712..95f5f28 100644 --- a/Radegast/GUI/Consoles/GroupIMTabWindow.cs +++ b/Radegast/GUI/Consoles/GroupIMTabWindow.cs @@ -457,23 +457,6 @@ namespace Radegast pnlChatInput.Height = cbxInput.Height + 7; } - private void ctxMute_Click(object sender, EventArgs e) - { - if (Participants.SelectedItems.Count != 1) return; - - var agentID = (UUID)Participants.SelectedItems[0].Tag; - if (agentID == client.Self.AgentID) return; - - if (ctxMute.Text == "Mute") - { - client.Self.UpdateMuteListEntry(MuteType.Resident, agentID, instance.Names.GetLegacyName(agentID)); - } - else - { - client.Self.RemoveMuteListEntry(agentID, instance.Names.GetLegacyName(agentID)); - } - } - private void avatarContext_Opening(object sender, System.ComponentModel.CancelEventArgs e) { if (Participants.SelectedItems.Count != 1) @@ -550,5 +533,21 @@ namespace Radegast if (Participants.SelectedItems.Count != 1) return; UUID av = (UUID)Participants.SelectedItems[0].Tag; } + + private void ctxMute_Click(object sender, EventArgs e) + { + if (Participants.SelectedItems.Count != 1) return; + UUID av = (UUID)Participants.SelectedItems[0].Tag; + if (av == client.Self.AgentID) return; + + if (ctxMute.Text == "Mute") + { + client.Self.UpdateMuteListEntry(MuteType.Resident, av, instance.Names.GetLegacyName(av)); + } + else + { + client.Self.RemoveMuteListEntry(av, instance.Names.GetLegacyName(av)); + } + } } } -- 2.11.0