本文整理了Java中org.lwjgl.input.Keyboard.enableRepeatEvents()
方法的一些代码示例,展示了Keyboard.enableRepeatEvents()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Keyboard.enableRepeatEvents()
方法的具体详情如下:
包路径:org.lwjgl.input.Keyboard
类名称:Keyboard
方法名:enableRepeatEvents
暂无
代码示例来源:origin: libgdx/libgdx
public LwjglInput () {
Keyboard.enableRepeatEvents(false);
Mouse.setClipMouseCoordinatesToWindow(false);
}
代码示例来源:origin: libgdx/libgdx
public LwjglInput () {
Keyboard.enableRepeatEvents(false);
Mouse.setClipMouseCoordinatesToWindow(false);
}
代码示例来源:origin: jMonkeyEngine/jmonkeyengine
public void initialize() {
if (!context.isRenderable())
return;
try {
Keyboard.create();
Keyboard.enableRepeatEvents(true);
logger.fine("Keyboard created.");
} catch (LWJGLException ex) {
logger.log(Level.SEVERE, "Error while creating keyboard.", ex);
}
}
代码示例来源:origin: MovingBlocks/Terasology
private void initControls() {
try {
Keyboard.create();
Keyboard.enableRepeatEvents(true);
Mouse.create();
InputSystem inputSystem = new InputSystem();
context.put(InputSystem.class, inputSystem);
inputSystem.setMouseDevice(new LwjglMouseDevice(context));
inputSystem.setKeyboardDevice(new LwjglKeyboardDevice());
ControllerConfig controllerConfig = context.get(Config.class).getInput().getControllers();
JInputControllerDevice controllerDevice = new JInputControllerDevice(controllerConfig);
inputSystem.setControllerDevice(controllerDevice);
} catch (LWJGLException e) {
throw new RuntimeException("Could not initialize controls.", e);
}
}
代码示例来源:origin: AppliedEnergistics/Applied-Energistics-2
@Override
public void onGuiClosed()
{
super.onGuiClosed();
Keyboard.enableRepeatEvents( false );
memoryText = this.searchField.getText();
}
代码示例来源:origin: Vazkii/Botania
public void handleNoteKey(char par1, int par2) {
if(notesEnabled) {
Keyboard.enableRepeatEvents(true);
boolean changed = false;
if(par2 == 14 && note.length() > 0) {
if(isCtrlKeyDown())
note = "";
else {
if(note.endsWith("<br>"))
note = note.substring(0, note.length() - 4);
else note = note.substring(0, note.length() - 1);
}
changed = true;
}
if((ChatAllowedCharacters.isAllowedCharacter(par1) || par2 == 28) && note.length() < 250) {
note += par2 == 28 ? "<br>" : par1;
changed = true;
}
if(changed) {
notes.put(getNotesKey(), note);
PersistentVariableHelper.saveSafe();
}
} else Keyboard.enableRepeatEvents(false);
}
代码示例来源:origin: org.slick2d/slick2d-core
/**
* Enable key repeat for this input context. Uses the system settings for repeat
* interval configuration.
*/
public void enableKeyRepeat() {
Keyboard.enableRepeatEvents(true);
}
代码示例来源:origin: org.slick2d/slick2d-core
/**
* Disable key repeat for this input context
*/
public void disableKeyRepeat() {
Keyboard.enableRepeatEvents(false);
}
代码示例来源:origin: AppliedEnergistics/Applied-Energistics-2
@Override
public void initGui()
Keyboard.enableRepeatEvents( true );
代码示例来源:origin: ForestryMC/ForestryMC
@Override
public void onGuiClosed() {
Keyboard.enableRepeatEvents(false);
super.onGuiClosed();
}
代码示例来源:origin: raoulvdberge/refinedstorage
@Override
public void onGuiClosed() {
super.onGuiClosed();
Keyboard.enableRepeatEvents(false);
}
代码示例来源:origin: CoFH/CoFHCore
@Override
public void onGuiClosed() {
Keyboard.enableRepeatEvents(false);
super.onGuiClosed();
}
代码示例来源:origin: MrCrayfish/MrCrayfishFurnitureMod
@Override
public void onGuiClosed()
{
Keyboard.enableRepeatEvents(false);
PacketHandler.INSTANCE.sendToServer(new MessageUpdateValueContainer(values, valueContainer));
}
代码示例来源:origin: MrCrayfish/MrCrayfishFurnitureMod
@Override
public void initGui()
{
super.initGui();
Keyboard.enableRepeatEvents(false);
buttonList.clear();
int posX = width / 2;
int posY = height / 2;
button_empty = new GuiButton(0, posX + 40, posY - 50, 40, 20, I18n.format("cfm.button.empty"));
button_empty.enabled = true;
buttonList.add(button_empty);
}
代码示例来源:origin: SlimeKnights/TinkersConstruct
public void initGui() {
super.initGui();
Keyboard.enableRepeatEvents(true);
public void onGuiClosed() {
super.onGuiClosed();
Keyboard.enableRepeatEvents(false);
代码示例来源:origin: ForestryMC/ForestryMC
@Override
public void initGui() {
super.initGui();
buttonList.clear();
Keyboard.enableRepeatEvents(true);
buttonList.add(new GuiButton(2, width / 2 + 44, guiTop + 150, 12, 20, ">"));
buttonList.add(new GuiButton(3, width / 2 - 58, guiTop + 150, 12, 20, "<"));
buttonFilter = new GuiButton(4, width / 2 - 44, guiTop + 150, 42, 20, Translator.translateToLocal("for.gui.mail.filter.all"));
buttonList.add(buttonFilter);
buttonUse = new GuiButton(5, width / 2, guiTop + 150, 42, 20, Translator.translateToLocal("for.gui.mail.address.copy"));
buttonList.add(buttonUse);
}
代码示例来源:origin: nifty-gui/nifty-gui
public void startup() throws Exception {
Mouse.create();
Keyboard.create();
Keyboard.enableRepeatEvents(true);
logMouseCapabilities();
}
代码示例来源:origin: ldtteam/minecolonies
@Override
public void initGui()
{
x = (width - window.getWidth()) / 2;
y = (height - window.getHeight()) / 2;
Keyboard.enableRepeatEvents(true);
window.onOpened();
}
代码示例来源:origin: ForestryMC/ForestryMC
@Override
public void onGuiClosed() {
String recipientName = this.address.getText();
EnumAddressee recipientType = container.getCarrierType();
setRecipient(recipientName, recipientType);
setText();
Keyboard.enableRepeatEvents(false);
super.onGuiClosed();
}
代码示例来源:origin: Vazkii/Quark
@Override
public void onGuiClosed() {
Keyboard.enableRepeatEvents(false);
NetHandlerPlayClient nethandlerplayclient = this.mc.getConnection();
if(nethandlerplayclient != null)
nethandlerplayclient.sendPacket(new CPacketUpdateSign(sign.getPos(), sign.signText));
sign.setEditable(true);
}
内容来源于网络,如有侵权,请联系作者删除!