本文整理了Java中com.badlogic.gdx.scenes.scene2d.Stage.scrolled()
方法的一些代码示例,展示了Stage.scrolled()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Stage.scrolled()
方法的具体详情如下:
包路径:com.badlogic.gdx.scenes.scene2d.Stage
类名称:Stage
方法名:scrolled
[英]Applies a mouse scroll event to the stage and returns true if an actor in the scene Event#handle() the event. This event only occurs on the desktop.
[中]将鼠标滚动事件应用于舞台,如果场景中的演员事件#handle()处理该事件,则返回true。此事件仅在桌面上发生。
代码示例来源:origin: com.lwgame.gdx/core
@Override
public boolean scrolled(int amount) {
return stage.scrolled(amount) || !isTransparent();
}
代码示例来源:origin: com.lwgame.gdx/lwgame-core
@Override
public boolean scrolled(int amount) {
return stage.scrolled(amount) || !isTransparent();
}
代码示例来源:origin: dingjibang/GDX-RPG
/** Called when the mouse wheel was scrolled. Will not be called on iOS.
* @param amount the scroll amount, -1 or 1 depending on the direction the wheel was scrolled.
* @return whether the input was processed. */
public boolean scrolled (int amount){
if($.allMatch(processors(), p -> p.scrolled(amount)) && onInput()){
stage.scrolled(amount);
return bubble;
}
return false;
};
内容来源于网络,如有侵权,请联系作者删除!