本文整理了Java中com.ait.lienzo.client.core.shape.Group.getComputedLocation()
方法的一些代码示例,展示了Group.getComputedLocation()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Group.getComputedLocation()
方法的具体详情如下:
包路径:com.ait.lienzo.client.core.shape.Group
类名称:Group
方法名:getComputedLocation
暂无
代码示例来源:origin: com.ahome-it/lienzo-core
public Point2D getComputedLocation()
{
return getGroup().getComputedLocation();
}
代码示例来源:origin: ahome-it/lienzo-core
public Point2D getComputedLocation()
{
return getGroup().getComputedLocation();
}
代码示例来源:origin: ahome-it/lienzo-core
public Point2D getComputedLocation()
{
return getGroup().getComputedLocation();
}
代码示例来源:origin: org.kie.workbench.stunner/kie-wb-common-stunner-lienzo
@SuppressWarnings("unchecked")
public T connect(final ShapeView headShapeView,
final Connection headConnection,
final ShapeView tailShapeView,
final Connection tailConnection) {
final Optional<WiresShape> headWiresShape = Optional.ofNullable((WiresShape) headShapeView);
final Optional<WiresShape> tailWiresShape = Optional.ofNullable((WiresShape) tailShapeView);
return connect(headWiresShape.map(WiresShape::getMagnets).orElse(null),
headWiresShape.map(s -> s.getGroup().getComputedLocation()).orElse(null),
headConnection,
tailWiresShape.map(WiresShape::getMagnets).orElse(null),
tailWiresShape.map(s -> s.getGroup().getComputedLocation()).orElse(null),
tailConnection);
}
代码示例来源:origin: org.kie.workbench.stunner/kie-wb-common-stunner-lienzo-extensions
private void shapeOffset(final WiresContainer shape) {
offset(shape.getGroup().getComputedLocation());
}
代码示例来源:origin: org.kie.workbench.stunner/kie-wb-common-stunner-lienzo-extensions
private BoundingBox computeAbsoluteBoundingBox(final double pad) {
final BoundingBox bb = getBoundingBox().get();
final Point2D computedLocation = asPrimitive().getComputedLocation();
return new BoundingBox(computedLocation.getX() - pad,
computedLocation.getY() - pad,
computedLocation.getX() + bb.getWidth() + pad,
computedLocation.getY() + bb.getHeight() + pad);
}
代码示例来源:origin: org.kie.workbench.stunner/kie-wb-common-stunner-case-mgmt-client
@Override
public boolean onMove(double dx,
double dy) {
containmentControl.onMove(dx, dy);
//Handle moving ghost from one container to another
final Optional<CaseManagementShapeView> ghost = state.getGhost();
if (ghost.isPresent() && null != getParent() && null != getParent().getGroup()) {
if (getWiresManager().getContainmentAcceptor().containmentAllowed(getParent(),
new WiresShape[]{getShape()})) {
final double mouseX = containmentControl.getParentPickerControl().getShapeLocationControl().getMouseStartX() + dx;
final double mouseY = containmentControl.getParentPickerControl().getShapeLocationControl().getMouseStartY() + dy;
final Point2D parentAbsLoc = getParent().getGroup().getComputedLocation();
final Point2D mouseRelativeLoc = new Point2D(mouseX - parentAbsLoc.getX(),
mouseY - parentAbsLoc.getY());
//Children contains m_ghost and others excluding m_shape. This therefore moves m_ghost within children.
getParent().getLayoutHandler().add(ghost.get(),
getParent(),
mouseRelativeLoc);
containmentControl.getParentPickerControl().rebuildPicker();
}
}
return false;
}
代码示例来源:origin: com.ahome-it/lienzo-core
protected void updateParentLocation()
{
if ((null == m_parent) && (null != getGroup().getLayer()))
{
m_parent = new Group();
getGroup().getLayer().add(m_parent);
}
if (null == m_parent)
{
return;
}
final Point2D p = getGroup().getComputedLocation();
m_parent.setX(p.getX());
m_parent.setY(p.getY());
m_parent.moveToTop();
for (final WiresShape child : m_wires_shape.getChildShapes())
{
final WiresShapeControlHandleList list = child.getControls();
if (null != list)
{
list.updateParentLocation();
}
}
}
代码示例来源:origin: ahome-it/lienzo-core
protected void updateParentLocation()
{
if ((null == m_parent) && (null != getGroup().getLayer()))
{
m_parent = new Group();
getGroup().getLayer().add(m_parent);
}
if (null == m_parent)
{
return;
}
final Point2D p = getGroup().getComputedLocation();
m_parent.setX(p.getX());
m_parent.setY(p.getY());
m_parent.moveToTop();
for (final WiresShape child : m_wires_shape.getChildShapes())
{
final WiresShapeControlHandleList list = child.getControls();
if (null != list)
{
list.updateParentLocation();
}
}
}
代码示例来源:origin: ahome-it/lienzo-core
protected void updateParentLocation()
{
if ((null == m_parent) && (null != getGroup().getLayer()))
{
m_parent = new Group();
getGroup().getLayer().add(m_parent);
}
if (null == m_parent)
{
return;
}
final Point2D p = getGroup().getComputedLocation();
m_parent.setX(p.getX());
m_parent.setY(p.getY());
m_parent.moveToTop();
for (final WiresShape child : m_wires_shape.getChildShapes())
{
final WiresShapeControlHandleList list = child.getControls();
if (null != list)
{
list.updateParentLocation();
}
}
}
内容来源于网络,如有侵权,请联系作者删除!