本文整理了Java中java.awt.Canvas.isShowing()
方法的一些代码示例,展示了Canvas.isShowing()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Canvas.isShowing()
方法的具体详情如下:
包路径:java.awt.Canvas
类名称:Canvas
方法名:isShowing
暂无
代码示例来源:origin: libgdx/libgdx
private void checkCatched (MouseEvent e) {
if (catched && robot != null && canvas.isShowing()) {
int x = Math.max(0, Math.min(e.getX(), canvas.getWidth()) - 1) + canvas.getLocationOnScreen().x;
int y = Math.max(0, Math.min(e.getY(), canvas.getHeight()) - 1) + canvas.getLocationOnScreen().y;
if (e.getX() < 0 || e.getX() >= canvas.getWidth() || e.getY() < 0 || e.getY() >= canvas.getHeight()) {
robot.mouseMove(x, y);
}
}
}
代码示例来源:origin: libgdx/libgdx
private void checkCatched (MouseEvent e) {
if (catched && robot != null && canvas.isShowing()) {
int x = Math.max(0, Math.min(e.getX(), canvas.getWidth()) - 1) + canvas.getLocationOnScreen().x;
int y = Math.max(0, Math.min(e.getY(), canvas.getHeight()) - 1) + canvas.getLocationOnScreen().y;
if (e.getX() < 0 || e.getX() >= canvas.getWidth() || e.getY() < 0 || e.getY() >= canvas.getHeight()) {
robot.mouseMove(x, y);
}
}
}
代码示例来源:origin: org.activecomponents.jadex/jadex-kernel-extension-envsupport
/**
* Checks if this IViewport is showing on screen.
*
* @return true if the IViewport is showing, false otherwise
*/
public boolean isShowing()
{
return canvas_.isShowing();
}
代码示例来源:origin: org.activecomponents.jadex/jadex-kernel-extension-envsupport
/**
* Checks if this IViewport is showing on screen.
*
* @return true if the IViewport is showing, false otherwise
*/
public boolean isShowing()
{
return canvas_.isShowing();
}
代码示例来源:origin: com.badlogicgames.gdx/gdx-backend-lwjgl
private void checkCatched (MouseEvent e) {
if (catched && robot != null && canvas.isShowing()) {
int x = Math.max(0, Math.min(e.getX(), canvas.getWidth()) - 1) + canvas.getLocationOnScreen().x;
int y = Math.max(0, Math.min(e.getY(), canvas.getHeight()) - 1) + canvas.getLocationOnScreen().y;
if (e.getX() < 0 || e.getX() >= canvas.getWidth() || e.getY() < 0 || e.getY() >= canvas.getHeight()) {
robot.mouseMove(x, y);
}
}
}
内容来源于网络,如有侵权,请联系作者删除!