Exemplo n.º 1
0
 public override void OnMouseDown(DrawManager parent, MouseButtonEventArgs button)
 {
     if (scrollbar_rect.matrix.TestCollision(new Vertex2(UserMouse.GetX(), UserMouse.GetY())))
     {
         anchor    = new Vertex2(UserMouse.GetX(), UserMouse.GetY() - (scrollbar_rect.y - outline_rect.y));
         isGrabbed = true;
     }
 }
Exemplo n.º 2
0
 public override void Draw(DrawManager parent)
 {
     base.Draw(parent);
     highlight_box.Draw(parent);
     if (highlight_box.matrix.TestCollision(new Vertex2(UserMouse.GetX(), UserMouse.GetY())))
     {
         highlight_box.color.a += 4;
         if (highlight_box.color.a > 80)
         {
             highlight_box.color.a = 80;
         }
     }
     else
     {
         highlight_box.color.a -= 4;
         if (highlight_box.color.a < 20)
         {
             highlight_box.color.a = 20;
         }
     }
     title_text.Draw(parent);
 }
Exemplo n.º 3
0
 public override void Draw(DrawManager parent)
 {
     cursorSprite.x = UserMouse.GetX();
     cursorSprite.y = UserMouse.GetY();
     cursorSprite.Draw(parent);
 }