private void detectControllerButton_Click(object sender, RoutedEventArgs e) { JoystickInputSelectorDialog dlg = new JoystickInputSelectorDialog(); if (dlg.ShowDialog().Value == true) { textBox1.Text = dlg.ResultString; } }
public bool ShowInputDialog() { JoystickInputSelectorDialog dlg = new JoystickInputSelectorDialog(); if (dlg.ShowDialog() == true) { Joystick = JoystickReader.GetJoystick(); timer1.Start(); return(this.ShowDialog().Value); } else { return(false); } }