Ejemplo n.º 1
0
        void HandleBanClick(object sender, EventArgs e)
        {
            string u = TextInput.GetInput(this, "Who");

            if (u == null)
            {
                return;
            }
            string w = TextInput.GetInput(this, "Why");

            if (w == null)
            {
                return;
            }
            ProxyControl.Ban(u, DateTime.MaxValue, w);
        }
Ejemplo n.º 2
0
        void KickPlayer(object sender, EventArgs e)
        {
            string players = "";

            foreach (PlayerListItem i in SelectedItems)
            {
                players += " " + i.Item.Username;
            }

            string reason = TextInput.GetInput(this, "Why Kick" + players);

            if (reason == null)
            {
                return;
            }

            foreach (PlayerListItem i in SelectedItems)
            {
                ProxyControl.Kick(i.Item, reason);
            }
        }
Ejemplo n.º 3
0
        void BanPlayer30(object sender, EventArgs e)
        {
            string players = "";

            foreach (PlayerListItem i in SelectedItems)
            {
                players += " " + i.Item.Username;
            }

            string reason = TextInput.GetInput(this, "Why Ban" + players);

            if (reason == null)
            {
                return;
            }

            foreach (PlayerListItem i in SelectedItems)
            {
                ProxyControl.Ban(i.Item, DateTime.Now.AddMinutes(30), reason);
            }
        }
Ejemplo n.º 4
0
		public static string GetInput (IWin32Window owner, string question)
		{
			TextInput ti = new TextInput (question);
			ti.ShowDialog (owner);
			return ti.Result;
		}