public MainWindow() { InitializeComponent(); if (Application.Current == null) { return; } ButtplugTab.SetServerDetails("Kiiroo Emulator", 0); _bpServer = ButtplugTab.GetServer(); _bpServer.SendMessage(new RequestServerInfo("Kiiroo Emulator")).Wait(); InitializeComponent(); _kiirooEmulator = new KiirooPlatformEmulator(); _kiirooEmulator.OnKiirooPlatformEvent += HandleKiirooPlatformMessage; _kiirooEmulator.OnException += HandleKiirooPlatformMessage; _translator = new KiirooMessageTranslator(); _translator.VibrateEvent += OnVibrateEvent; _ops = new List <DispatcherOperation>(); var emu = new KiirooEmulatorPanel(); ButtplugTab.AddDevicePanel(_bpServer); ButtplugTab.SetApplicationTab("Kiiroo Emulator", emu); Closing += ClosingHandler; StartServer(); emu.ServerStatusChanged += OnServerStatusChanged; ButtplugTab.SelectedDevicesChanged += SelectionChangedHandler; var config = new ButtplugConfig("B******g"); ButtplugTab.GetAboutControl().CheckUpdate(config, "b******g-csharp"); }
public MainWindow() { InitializeComponent(); if (Application.Current == null) { return; } ButtplugTab.SetServerDetails("Kiiroo Emulator", 0); _emu = new KiirooEmulatorPanel(ButtplugTab.GetService()); ButtplugTab.SetApplicationTab("Kiiroo Emulator", _emu); Closing += ClosingHandler; _emu.StartServer(); }