private delegate void OnGUI(); public void FunInvoke() { // отрисовка } public void fun() { Invoke(new OnGUI(FunInvoke)); }