Skip to main content
Filter by
Sorted by
Tagged with
0 votes
1 answer
559 views

I am handling multiple key presses by subclassing QMainWindow and overriding the keyPressEvent and keyReleaseEvent functions, and then updating a dictionary if the key is down or not... def ...
SamG101's user avatar
  • 491
1 vote
0 answers
55 views

I wrote an app which starts record audio in response to holding volume up button on phone or headphone, I'm doing it inside dispatchKeyEvent method and it's fine Problem is, I want to do it when the ...
Ali Molaei's user avatar
0 votes
0 answers
425 views

i have problem with my app in some devices (HUAWEI P10 Lite, rockchip A95XR3). Maybe more in future. According to users, when opening the Video Player Activity, the app immediately crashes. I think, ...
Espada's user avatar
  • 221
4 votes
1 answer
2k views

I enjoy writing my very first Blazor app. I want to move 2D graphics on a canvas, I'm using the Blazor.Extensions.Canvas assembly. Unfortunately I'm not able to get key events from the canvas. @page "...
anhoppe's user avatar
  • 4,583
1 vote
2 answers
259 views

I have a textbox, a button, and a progressbar. I would like the keydown event of the textbox therefore the entry, is found using a button in the progressbar, in fact I would like the number entered in ...
Ludovic Baloo's user avatar
1 vote
1 answer
466 views

I am working on VSIX project where I need to detect Enter key OnKeyUp event. How can I implement this in a Text Adornment project? I Need to detect the event when someone press key for changing the ...
Tanmay Bairagi's user avatar
0 votes
1 answer
50 views

I have little problem with my windowsforms app - its a snake game Everywhing is ok, but after click "Play Again" button app doesn't see any kay Event (I try debug and put break point in KeyIsDown(...
ldidil's user avatar
  • 1
2 votes
1 answer
737 views

I'm trying to change the cursor shape on key event: When i press 'C', i want to display a LineCursor, when i press 'S', i want to display a CrossCursor, and when i press 'N', i want to display the ...
Lobe's user avatar
  • 23
0 votes
1 answer
109 views

I have a JPanel that I need to check for the control being pressed down so that the user can select multiple things on screen, i had the issues of using a key listener so after research i found that i ...
Thomasmca86's user avatar
0 votes
1 answer
110 views

I have searched for a solution on SO, and while this might seem to be a duplicate, most of the similar questions are asking how to detect hardware volume keys when the screen is Off. I have found ...
grolschie's user avatar
  • 2,173
0 votes
0 answers
65 views

I have built a snake game where a JPanel that implements a card layout manager is placed onto the JFrame. Three other JPanels are added to the card layout. public void init () { JOptionPane....
kinghabz 14's user avatar
-1 votes
1 answer
68 views

I decided to create application for me. I wanted to set keyboard listener in my text field. There are 5 windows in my simple application and in the everyone has handler. All handlers different. But I ...
Dima's user avatar
  • 1
1 vote
0 answers
84 views

I want to simulate the actual volume keypress in android. I have an app that runs in background and observers touch event. And on touch event, it should turn up the volume for the rest of the apps(ie ...
M.AQIB's user avatar
  • 393
0 votes
1 answer
173 views

I've a "driver" file and a source file for the project I'm working on right now. In my driver file I add an EventHandle to me stage. stage.addEventHandler(KeyEvent.KEY_TYPED, shape.getKeyHandler()); ...
Hudie's user avatar
  • 49
0 votes
1 answer
134 views

I'm currently trying to make a java based platformer as a trial-by-fire way of teaching myself Java Swing. I currently have a JPanel in a JFrame and it is controlled by w-a-s-d. I'm currently coding ...
Maninderjit Buttar's user avatar
8 votes
1 answer
1k views

As per documentation from API 29, KeyEvent.getCharacters() is deprecated, but there is no alternative that I could find for same. As per documentation it says "@deprecated no longer used by the input ...
Ali Ashraf's user avatar
  • 1,929
0 votes
1 answer
53 views

We areto create a plane and have its speed increase 5mph every time the user inputs the up arrow key and decrease 9mph when hitting the down key. It is supposed it report this back to the user in ...
DcJames's user avatar
3 votes
1 answer
769 views

I am implmenting a cusom component where the user can type into a TextField and a TableView is pops up then the user can look for items in that table. I have a problem with the standard KeyEvents of ...
Sunflame's user avatar
  • 3,196
2 votes
2 answers
95 views

So I am basically creating a platformer game in java. Here is a simple question. Can I respond to two different KeyEvents simultaneously? For example, I am pressing the right arrow key and my player ...
Nandan Goyal's user avatar
0 votes
0 answers
813 views

I created an Acessibility Service to store in FireBase every message that the user send, when the user is using an specific app (Hangouts in this case). I am trying to display an AlertDialog when ...
jorge's user avatar
  • 11
-1 votes
1 answer
137 views

After storing the string into nick I want to print the string, but when I print string it only prints the last character, not whole string. How do I print the whole string?
Rambabu 's user avatar
0 votes
1 answer
65 views

For Nvidia joystick trying to associate this event to go to search button on the grid view, it is working but it is getting frozen and nothing is happening after that. Suggest me something @Override ...
Hello Word's user avatar
-1 votes
1 answer
312 views

I am building an application using JavaFX. Application does some CRUD operations with the MySQL Database. So currently, I have 2 functions. User Registration. Email Validation (Check if email already ...
Tech Guy's user avatar
0 votes
1 answer
268 views

I'm trying to create a method that only allows me to type a single number into a text field however my current code does not work. It allows me to type letters in even though the KeyPressed method is ...
Edd's user avatar
  • 136
1 vote
1 answer
2k views

I want to get the space key event in an android keyboard. I tried some codes from google searches. but nothing is working. public boolean onKey(View v, int keyCode, KeyEvent event) { if (...
faizy's user avatar
  • 776
1 vote
1 answer
1k views

I am a student in a second level OOP/Java programming class. We had an assignment to create a simple JavaFX interface that allows the user to draw in a pane using the arrow keys. It reminds me of an ...
tsfarber's user avatar
0 votes
1 answer
552 views

I'm currently working on an app that uses a barcode scanner for scanning some bar codes. So, I'm capturing the data by overloading the dispatchKeyEvent method. Everything works fine, as long as I'm ...
BWappsAndmore's user avatar
-1 votes
1 answer
56 views

I'm trying to set KeyEvent KeyCode to KeyCode.BACK_SAPCE if entered value is not a digit. But I'm not able to achieve it public void textFieldKeyReleased(KeyEvent e) { if (!e.getCode()....
Swapnil's user avatar
  • 115
0 votes
1 answer
157 views

I have a Rectangle on a GridPane and after adding KeyEvent, it doesn't fire. this is my code: Rectangle rectangle = new Rectangle(); rectangle.setX(500.0f); rectangle.setY(200.0f); ...
KMarto's user avatar
  • 300
0 votes
1 answer
658 views

I have this code: public ClearableEditText(Context context, AttributeSet attrs) { super(context, attrs); setOnEditorActionListener((v, actionId, event) -> { if (event.getAction() =...
KarmelE98's user avatar
1 vote
1 answer
700 views

I'm trying to develop a Virtual Gamepad but I'm facing lots of problems sending input and event to Android, especially with MotionEvents. I have a device rooted and the app stored in /system/app, ...
Francesco D'Amico's user avatar
1 vote
1 answer
231 views

I am using the "geckoWebBrowser1" component. I have navigated to an URL that will show an login textbox with ID: login-email Now I do successfully put "[email protected]" into that textbox. ...
Andreas's user avatar
  • 1,295
1 vote
1 answer
391 views

Suppose we want set a mnemonic for a menu item, and we want it be 'c'. I notice in almost all codes they write it as: menuitem.setMnemonic(KeyEvent.VK_C); I know that we can write it like this: ...
feel free's user avatar
  • 173
1 vote
1 answer
219 views

My problem is that after adding catching keys, my code began to work not quite correctly. In more detail: The task of a program after pressing a key combination (in my case it is CTRL + q and CTRL + ...
Skiv Hisink's user avatar
0 votes
1 answer
42 views

Situation *************: I'm looking some intel about the onKey override method by fragment. I have single activity several fragment structure. Only one fragment visible at time. I show a new fragment ...
user avatar
0 votes
1 answer
247 views

Problem is on a service view back button is giving me a response but Home and Recent Apps button is not triggering @Override public boolean onKey(View v, int keyCode, KeyEvent event) { switch (...
Subhan Tariq's user avatar
2 votes
0 answers
248 views

I am trying to remote control a Qt application over UDP messages from my host computer. Currently, the remote controlled computer runs a Qt application that receives messages and creates Mouse ...
TRanquil's user avatar
0 votes
2 answers
2k views

I am using PyQt5 together with QML to create an application. I need to be able to simulate keyboard board events either from PyQT to my QML objects or alternatively from QML itself. I'm using a ...
MagicUK's user avatar
  • 44
0 votes
0 answers
996 views

when i am trying to insert key events in android import android.view.KeyEvent; is not working, got this Cannot resolve symbol 'KeyEvent' when import java lib. import android.view.KeyEvent; view....
UdaipurEscorts's user avatar
0 votes
0 answers
731 views

I want to know the keycode for some chars like Divide symbol in mobile, Euro etc.. Updating the question I am able to print all key events using below method. But nothing happens when I type few ...
Smitha's user avatar
  • 575
0 votes
1 answer
60 views

Im trying to develope Snake in Java and Im using KeyListeners to get KeyEvents for the buttons w, a, s and d. I created a Class that implements KeyEvent and I added an Object of that Class to the ...
someone's user avatar
1 vote
0 answers
148 views

I am working on a custom keyboard for an Android device and I am looking for a KeyEvent to navigate from one input field to another. I already tried some of them (KeyEvent.NAVIGATE_NEXT, ...), but ...
Gerrit Humberg's user avatar
0 votes
1 answer
272 views

I am trying to allow for a JTextArea to have focus but if the user enters keyboard input and control is not pressed then to forward that key event on to the command JTextField. I tried to simply ...
Zach Ehret's user avatar
0 votes
1 answer
45 views

I'am working on a game with the canvas element. The goal is that first time you press a key it start a stopwatch. It should end as soon as the gameoverscreen/winscreen appears. After the ...
user avatar
1 vote
0 answers
532 views

I have a bluetooth keyboard, and when the phone recieves a certain character from that keyboard (eg. 'A') I would like to change a picture on the app. I'm brand new to Android Studio and I don't ...
gsam's user avatar
  • 11
2 votes
1 answer
365 views

When a software keyboard is opened on my virtual device, the back button changes function to hide the keyboard when pressed - it does not stay 'KEYCODE_BACK' like it does whilst the keyboard is hidden....
dewie's user avatar
  • 99
0 votes
2 answers
380 views

I have a contenteditable p element. I'd like to limit the possible edit operations to inserting and deleting commas. I also want to copy the updated contents to another div. These two goals seem to be ...
Pida's user avatar
  • 1,008
2 votes
0 answers
255 views

I want to implement some keyboard actions into my custom view. The actual code is more complex, nut even in this simple setup I do not get that to work. The code below is Swift 4 in an Xcode 9.2 ...
MassMover's user avatar
  • 577
0 votes
1 answer
405 views

I'm trying to have a function be called every time a key is pressed. For some reason I can't bind the wxEVT_CHAR_HOOK event to a function. There is no probelm with creating a button and binding the ...
Ame's user avatar
  • 45
1 vote
0 answers
36 views

I want to make something happen on screen when i press som buttons. I know how events work but never worked with key Events in java. If someone can tell me why this code dont work, it would be great. :...
Daniel-S's user avatar

1
3 4
5
6 7
30