private void HandCard_MouseLeftButtonUp(object sender, System.Windows.Input.MouseButtonEventArgs e) { HandCardInfo info = (HandCardInfo)(sender as System.Windows.Controls.Image).Tag; mahjongLogic.PlayCard(info.player, info.card); }