private void SetUpUiThread() { _uiThread = new Thread(() => { _nyanCat = new NyanCatWindow(100); _nyanCat.Show(); _nyanCat.Closed += (s, e) => _nyanCat.Dispatcher.InvokeShutdown(); Dispatcher.Run(); }); _uiThread.SetApartmentState(ApartmentState.STA); _uiThread.Start(); }
public void SetUp() { var speedInNyanoMetersPerSecond = 100; _window = new NyanCatWindow(speedInNyanoMetersPerSecond); }