void RowKeyUp(object sender, KeyEventArgs e) { if (e.Key == Key.Return) { GameLauncher.JoinServer((Server)((Control)sender).DataContext); } }
private void RowDoubleClick(object sender, MouseButtonEventArgs e) { var recentServer = (RecentServer)TheList.SelectedItem; if (recentServer == null) { return; } GameLauncher.JoinServer(recentServer.Server); }
private void RowDoubleClick(object sender, MouseButtonEventArgs e) { var control = e.OriginalSource as FrameworkElement; if (control != null) { if (control.Name == "Refresh") { e.Handled = true; return; } } var server = (Server)((Control)sender).DataContext; GameLauncher.JoinServer(server); }
private void RowDoubleClick(object sender, MouseButtonEventArgs e) { var server = (Server)((Control)sender).DataContext; GameLauncher.JoinServer(server); }