public void update_clients_online_numer(string amount) { if (this.InvokeRequired) { string_delegate d = new string_delegate(update_clients_online_numer); this.Invoke(d, new object[] { amount }); } else { this.users_online.Text = "(" + amount + ")"; } }
public void paint_my_profile_picture(string url) { if (InvokeRequired) { string_delegate d = new string_delegate(paint_my_profile_picture); this.Invoke(d, new object[] { url }); } else { Task.Run(new Action(() => { prof_pic_main.Image = prof_pic_painter.paint_profile_image(url, false, false); })); } }
public void update_ready_time(string secs) { if (InvokeRequired) { string_delegate d = new string_delegate(update_ready_time); this.Invoke(d, new object[] { secs }); } else { timeleft.Text = "Aega jäänud: " + secs + "s"; if (!main_hub.my_info.am_i_ready) { // play sound SoundPlayer beep = new SoundPlayer(Properties.Resources.beep); beep.Play(); } } }
protected virtual void InitRicherTextBox() { GetText = new string_delegate(GetTextSafe); }