public static void DeviceConnected(PSVR Device) { lock (locker) { if (dev != null) { dev.Dispose(); dev = null; } dev = Device; } }
private void MainForm_FormClosing(object sender, FormClosingEventArgs e) { if (!exit) { this.Hide(); e.Cancel = true; return; } if (vrSet != null) { vrSet.Dispose(); } hookedEvents.KeyDown -= HookedEvents_KeyDown; trayIcon.Visible = false; }