|
|
|
@ -143,7 +143,7 @@ namespace TheGameExtreme.view
|
|
|
|
|
if (stack.HitTest(point) || stack.HitTest(pointVisuCard))
|
|
|
|
|
{
|
|
|
|
|
int indexPile = stackCollection.IndexOf(stack);
|
|
|
|
|
if (played(indexPile, decimal.Parse(bitmap.Value)))
|
|
|
|
|
if (played(indexPile, bitmap.Value.Value))
|
|
|
|
|
{
|
|
|
|
|
bitmap.ProcessTouchEvent(args.Id, TouchActionType.Moved, stack.InitialPoint);
|
|
|
|
|
bitmap.InitialPoint = stackCollection[stackCollection.IndexOf(stack)].InitialPoint;
|
|
|
|
@ -183,14 +183,14 @@ namespace TheGameExtreme.view
|
|
|
|
|
SKPaint textPaint = new SKPaint();
|
|
|
|
|
float textWidth = textPaint.MeasureText("001");
|
|
|
|
|
float textSize = 0.05f * (float)DeviceDisplay.MainDisplayInfo.Width * textPaint.TextSize / textWidth;
|
|
|
|
|
SKPoint position = new SKPoint((float)((DeviceDisplay.MainDisplayInfo.Width * 0.9) / (viewmodel.getListOrderedStacks().Count * 2)) - textPaint.MeasureText("01"), (float)((DeviceDisplay.MainDisplayInfo.Height * 0.1) + (DeviceDisplay.MainDisplayInfo.Height * 0.9) * 0.01 + 2 * textSize));
|
|
|
|
|
SKPoint position = new SKPoint((float)((DeviceDisplay.MainDisplayInfo.Width * 0.9) / (viewmodel.getListOrderedStacks().Count * 2)) - textPaint.MeasureText("01") * 0.5f, (float)((DeviceDisplay.MainDisplayInfo.Height * 0.1) + (DeviceDisplay.MainDisplayInfo.Height * 0.9) * 0.01 + 2 * textSize));
|
|
|
|
|
|
|
|
|
|
for (int i = 0; i < viewmodel.getListOrderedStacks().Count; i++)
|
|
|
|
|
{
|
|
|
|
|
textPaint = new SKPaint();
|
|
|
|
|
textPaint.TextSize = textSize;
|
|
|
|
|
|
|
|
|
|
stackCollection.Add(new TouchManipulationBitmap(textPaint, viewmodel.getListOrderedStacks()[i].Peek().Value)
|
|
|
|
|
stackCollection.Add(new TouchManipulationBitmap(textPaint, viewmodel.getListOrderedStacks()[i].Peek())
|
|
|
|
|
{
|
|
|
|
|
Matrix = SKMatrix.MakeTranslation(position.X, position.Y),
|
|
|
|
|
InitialMatrix = SKMatrix.MakeTranslation(position.X, position.Y),
|
|
|
|
@ -206,7 +206,7 @@ namespace TheGameExtreme.view
|
|
|
|
|
SKPaint textPaint = new SKPaint();
|
|
|
|
|
float textWidth = textPaint.MeasureText("001");
|
|
|
|
|
float textSize = 0.05f * (float)DeviceDisplay.MainDisplayInfo.Width * textPaint.TextSize / textWidth;
|
|
|
|
|
SKPoint position = new SKPoint((float)((DeviceDisplay.MainDisplayInfo.Width * 0.9) / (viewmodel.CurrentHand.Count * 2)) - textPaint.MeasureText("01"), (float)((DeviceDisplay.MainDisplayInfo.Height * 0.9) - (DeviceDisplay.MainDisplayInfo.Height * 0.9) * 0.2 - textSize));
|
|
|
|
|
SKPoint position = new SKPoint((float)((DeviceDisplay.MainDisplayInfo.Width * 0.9) / (viewmodel.CurrentHand.Count * 2)) - textPaint.MeasureText("01") * 0.5f + (float)(DeviceDisplay.MainDisplayInfo.Width * 0.01), (float)((DeviceDisplay.MainDisplayInfo.Height * 0.9) - (DeviceDisplay.MainDisplayInfo.Height * 0.9) * 0.1 - 2 * textSize));
|
|
|
|
|
|
|
|
|
|
for (int i = 0; i < viewmodel.CurrentHand.Count; i++)
|
|
|
|
|
{
|
|
|
|
@ -214,7 +214,7 @@ namespace TheGameExtreme.view
|
|
|
|
|
textPaint.TextSize = textSize;
|
|
|
|
|
position.X -= (float)(textWidth * 0.5);
|
|
|
|
|
|
|
|
|
|
textCollection.Add(new TouchManipulationBitmap(textPaint, viewmodel.CurrentHand[i].Value)
|
|
|
|
|
textCollection.Add(new TouchManipulationBitmap(textPaint, viewmodel.CurrentHand[i])
|
|
|
|
|
{
|
|
|
|
|
Matrix = SKMatrix.MakeTranslation(position.X, position.Y),
|
|
|
|
|
InitialMatrix = SKMatrix.MakeTranslation(position.X, position.Y),
|
|
|
|
|