public void Update(MouseState mouse)
{
Rectangle mouseRec = new Rectangle((int)mouse.X, (int)mouse.Y, (int)sizeArrow.X, (int)sizeArrow.Y);
if (recArrowLeft.Intersects(mouseRec))
{
if (mouse.LeftButton == ButtonState.Pressed && mouseReleased == true)
{
if (arrayNumber != arResolutions.Count() - 1)
{
arrayNumber++;
ChangeResolution(new Vector2(Convert.ToInt32(arResolutions[arrayNumber][1]), Convert.ToInt32(arResolutions[arrayNumber][2])));
}
mouseReleased = false;
}
}
if (recArrowRight.Intersects(mouseRec))
{
if (mouse.LeftButton == ButtonState.Pressed && mouseReleased == true)
{
if (arrayNumber != 0)
{
arrayNumber--;
ChangeResolution(new Vector2(Convert.ToInt32(arResolutions[arrayNumber][1]), Convert.ToInt32(arResolutions[arrayNumber][2])));
}
mouseReleased = false;
}
}
if (mouse.LeftButton == ButtonState.Released)
{
mouseReleased = true;
}
}