Examples of startDragging()


Examples of org.tinyuml.draw.Selection.startDragging()

    assertFalse(selection.contains(x, y));
    assertEquals(Cursor.getDefaultCursor(),
      selection.getCursorForPosition(x, y));
    // These methods have no effect, just check they don't throw
    // exceptions
    selection.startDragging(x, y);
    selection.stopDragging(x, y);
    selection.cancelDragging();
    selection.updatePosition(x, y);
    selection.draw(drawingContext);
    selection.updateDimensions();
View Full Code Here

Examples of org.tinyuml.draw.Selection.startDragging()

    assertFalse(selection.contains(x, y));
    assertEquals(Cursor.getDefaultCursor(),
      selection.getCursorForPosition(x, y));
    // These methods have no effect, just check they don't throw
    // exceptions
    selection.startDragging(x, y);
    selection.stopDragging(x, y);
    selection.cancelDragging();
    selection.updatePosition(x, y);
    selection.draw(drawingContext);
    selection.updateDimensions();
View Full Code Here

Examples of org.tinyuml.draw.Selection.startDragging()

    assertFalse(selection.contains(x, y));
    assertEquals(Cursor.getDefaultCursor(),
      selection.getCursorForPosition(x, y));
    // These methods have no effect, just check they don't throw
    // exceptions
    selection.startDragging(x, y);
    selection.stopDragging(x, y);
    selection.cancelDragging();
    selection.updatePosition(x, y);
    selection.draw(drawingContext);
    selection.updateDimensions();
View Full Code Here

Examples of org.tinyuml.draw.Selection.startDragging()

    assertEquals(connection, selection.getElement());
    assertFalse(selection.isDragging());
    assertEquals(Cursor.getDefaultCursor(),
      selection.getCursorForPosition(3.0, 1.0));
    // these have no effect
    selection.startDragging(1.0, 2.0);
    selection.stopDragging(3.0, 4.0);
    selection.cancelDragging();
    selection.updateDimensions();
    selection.updatePosition(1.0, 2.0);
  }
View Full Code Here

Examples of org.tinyuml.draw.Selection.startDragging()

    assertFalse(selection.contains(x, y));
    assertEquals(Cursor.getDefaultCursor(),
      selection.getCursorForPosition(x, y));
    // These methods have no effect, just check they don't throw
    // exceptions
    selection.startDragging(x, y);
    selection.stopDragging(x, y);
    selection.cancelDragging();
    selection.updatePosition(x, y);
    selection.draw(drawingContext);
    selection.updateDimensions();
View Full Code Here

Examples of org.tinyuml.draw.SimpleConnectionSelection.startDragging()

   */
  public void testDragSegmentAndCancel() {
    node1.setOrigin(10, 10); // (10, 10, 80, 40) -> max (90, 50)
    node2.setOrigin(120, 10); // (120, 10, 80, 40) -> max (200, 50)
    SimpleConnectionSelection selection = setupConnection();
    selection.startDragging(105, 30);
    Point2D oldp1 = conn.getEndPoint1();
    Point2D oldp2 = conn.getEndPoint2();
    assertEquals(3, selection.getEditPoints().size());
    assertTrue(selection.isDragging());
    selection.updatePosition(120, 50);
View Full Code Here

Examples of org.tinyuml.draw.SimpleConnectionSelection.startDragging()

   */
  public void testDragSegmentAndStop() {
    node1.setOrigin(10, 10); // (10, 10, 80, 40) -> max (90, 50)
    node2.setOrigin(120, 10); // (120, 10, 80, 40) -> max (200, 50)
    SimpleConnectionSelection selection = setupConnection();
    selection.startDragging(105, 30);
    assertEquals(3, selection.getEditPoints().size());
    assertTrue(selection.isDragging());
    selection.updatePosition(120, 50);
    selection.updatePosition(130, 70);
    selection.stopDragging(140, 90);
View Full Code Here

Examples of org.tinyuml.draw.SimpleConnectionSelection.startDragging()

    node1.setOrigin(10, 10); // (10, 10, 80, 40) -> max (90, 50)
    node2.setOrigin(120, 10); // (120, 10, 80, 40) -> max (200, 50)
    SimpleConnectionSelection selection = setupConnection();
    Point2D oldp1 = conn.getEndPoint1();
    Point2D oldp2 = conn.getEndPoint2();
    selection.startDragging(105, 30);
    assertEquals(3, selection.getEditPoints().size());
    assertTrue(selection.isDragging());
    selection.updatePosition(120, 50);
    selection.updatePosition(110, 40);
    selection.updatePosition(106, 31); // melting position
View Full Code Here

Examples of org.tinyuml.draw.SimpleConnectionSelection.startDragging()

    node1.setOrigin(10, 10); // (10, 10, 80, 40) -> max (90, 50)
    node2.setOrigin(120, 10); // (120, 10, 80, 40) -> max (200, 50)
    SimpleConnectionSelection selection = setupConnection();
    // insert a new control point to make a total of three
    conn.getPoints().add(1, new Point2D.Double(105, 90));
    selection.startDragging(105, 90);
    assertTrue(selection.isDragging());
    selection.updatePosition(120, 50);
    selection.updatePosition(130, 70);
    selection.updatePosition(140, 90);
    selection.stopDragging(140, 90);
View Full Code Here

Examples of org.tinyuml.draw.SimpleConnectionSelection.startDragging()

    node1.setOrigin(10, 10); // (10, 10, 80, 40) -> max (90, 50)
    node2.setOrigin(120, 10); // (120, 10, 80, 40) -> max (200, 50)
    SimpleConnectionSelection selection = setupConnection();
    // insert a new control point to make a total of three
    conn.getPoints().add(1, new Point2D.Double(105, 90));
    selection.startDragging(105, 90);
    assertTrue(selection.isDragging());
    selection.updatePosition(120, 50);
    selection.updatePosition(110, 40);
    selection.updatePosition(105, 31);
    selection.stopDragging(105, 31);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.