本文整理匯總了Java中javafx.scene.Node.localToParent方法的典型用法代碼示例。如果您正苦於以下問題:Java Node.localToParent方法的具體用法?Java Node.localToParent怎麽用?Java Node.localToParent使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類javafx.scene.Node
的用法示例。
在下文中一共展示了Node.localToParent方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: click
import javafx.scene.Node; //導入方法依賴的package包/類
@Override public void click(int button, Node target, PickResult pickResult, int clickCount, double xoffset, double yoffset) {
Node cell = getPseudoComponent();
target = getTextObj((TableCell<?, ?>) cell);
Point2D targetXY = target.localToParent(xoffset, yoffset);
targetXY = node.localToScene(targetXY);
super.click(button, target, new PickResult(target, targetXY.getX(), targetXY.getY()), clickCount, xoffset, yoffset);
}
示例2: _getMidpoint
import javafx.scene.Node; //導入方法依賴的package包/類
@Override public Point2D _getMidpoint() {
TreeView<?> treeView = (TreeView<?>) getComponent();
Node cell = getCellAt(treeView, getPath(treeView, path));
Bounds boundsInParent = cell.getBoundsInParent();
double x = boundsInParent.getWidth() / 2;
double y = boundsInParent.getHeight() / 2;
return cell.localToParent(x, y);
}
示例3: _getMidpoint
import javafx.scene.Node; //導入方法依賴的package包/類
@Override public Point2D _getMidpoint() {
Node cell = getPseudoComponent();
Bounds boundsInParent = cell.getBoundsInParent();
double x = boundsInParent.getWidth() / 2;
double y = boundsInParent.getHeight() / 2;
return cell.localToParent(x, y);
}
示例4: click
import javafx.scene.Node; //導入方法依賴的package包/類
@Override public void click(int button, Node target, PickResult pickResult, int clickCount, double xoffset, double yoffset) {
Node cell = getPseudoComponent();
target = getTextObj((TreeTableCell<?, ?>) cell);
Point2D targetXY = target.localToParent(xoffset, yoffset);
targetXY = node.localToScene(targetXY);
super.click(button, target, new PickResult(target, targetXY.getX(), targetXY.getY()), clickCount, xoffset, yoffset);
}
示例5: _moveto
import javafx.scene.Node; //導入方法依賴的package包/類
@Override public void _moveto(double xoffset, double yoffset) {
Node cell = getPseudoComponent();
Point2D pCoords = cell.localToParent(xoffset, yoffset);
parent._moveto(pCoords.getX(), pCoords.getY());
}
示例6: _moveto
import javafx.scene.Node; //導入方法依賴的package包/類
@Override public void _moveto(double xoffset, double yoffset) {
Node cell = getCellAt((ListView<?>) getComponent(), itemIndex);
Point2D pCoords = cell.localToParent(xoffset, yoffset);
parent._moveto(pCoords.getX(), pCoords.getY());
}