Search Results

Search found 1599 results on 64 pages for 'pressed'.

Page 1/64 | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Button Pressed Animation be longer

    - by user1263567
    i have this button xml, when it be will pressed, the pressed image(b) would be longer to display before it goes back to normal button. Here's my xml: <selector xmlns:android="http://schemas.android.com/apk/res/android"> <item android:state_focused="true" android:state_pressed="false" android:drawable="@drawable/a" /> <item android:state_focused="true" android:state_pressed="true" android:drawable="@drawable/b" /> <item android:state_focused="false" android:state_pressed="true" android:drawable="@drawable/b" /> <item android:drawable="@drawable/a" /> Anyone has idea on this?

    Read the article

  • Keypress Left is called twice in Update when key is pressed only once

    - by Simran kaur
    I have a piece of code that is changing the position of player when left key is pressed. It is inside of Update() function. I know, Update is called multiple times, but since I have an ifstatement to check if left arrow is pressed, it should update only once. I have tested using print statement that once pressed, it gets called twice. Problem: Position updated twice when key is pressed only once. Below given is the structure of my code: void Update() { if (Input.GetKeyDown (KeyCode.LeftArrow)) { print ("PRESSEEEEEEEEEEEEEEEEEEDDDDDDDDDDDDDD"); } } I looked up on web and what was suggested id this: if (Event.current.type == EventType.KeyDown && Event.current.keyCode == KeyCode.LeftArrow) { print("pressed"); } But, It gives me an error that says: Object reference not set to instance of an object How can I fix this?

    Read the article

  • how to remap Ctrl to Escape if pressed and released on its own

    - by psvm
    I want to remap Control, so that: A. If it is pressed and released with no other key, it acts as Escape. B. If it is pressed & held together with another key, it acts as Control (no change in behavior in this case). I'm aware of How do I remap certain keys?, so I suspect it may be done with xmodmap. But that answer does not explain how to map the modifier keys. I looked into the examples and grammar sections of the xmodmap manpage, but they do not explain that. The answer in Remapping Caps Lock to Control and Escape (not the usual way) mention that it is not possible to do that to CapsLock, since it is a Lock key, but I hope this may be possible to do it with Control which is a mod key. A solution with something different than xmodmap will also be accepted. (I'm running Xmonad in Ubuntu 12.04, so perhaps there is a way to set this up in xmonad.hs?)

    Read the article

  • Ubuntu 14.04 key arrow up is being pressed by itself

    - by Margo Nikolopoulou
    Keyboard's up arrow key is keep pressing itself every few seconds. I tried to install Ubuntu 14.04 via boot cd, even before installation the arrow key was being pressed by itself. I tried to use Ubuntu first without installing it and then tried to install it from there, the issue seemed to be fixed. I was using the PC for months until out of the blue the issue came back. IT IS NOT A HARDWARE ISSUE! Thank you in advance.

    Read the article

  • Acting as though the laptop Fn key is pressed

    - by Matt
    I have a Fujitsu laptop and all was working fine until I ended teamviewer. On the keyboard it has a numberpad on some of the letters which you press the Fn button to use. The system is acting like I have the Fn key pressed and I get numbers shown when it should be letters. If I press the Fn key the numbers go to letters. The Fn key is not stuck down. Is there a way to reset keyboard settings or a known fix. The operating system is Ubuntu 11.04 Natty.

    Read the article

  • Checking whether a specific key was pressed in enchantJS

    - by MxyL
    I am using enchantJS and would like to use the letters and numbers as well as numpad on a keyboard to do different things (eg: hotkeys). From this page http://users.csc.calpoly.edu/~foaad/enchant/guide/playerInput.html By default, enchant.js provides input listeners for six buttons: UP, DOWN, LEFT, RIGHT, A, and B. By default, the directions are bound to the arrow keys. Any of the six buttons may also be bound to any key with an ASCII value. We’ll address that later. So enchant provides the ability to bind keys to different input such as up, down, left, right...but how can I simply check whether the D or X key was pressed, and if so, perform certain actions based on that event?

    Read the article

  • 12.04 Wacom Volito tablet pressed without touching tablet surface

    - by Nox Deleo
    My tablet has worked okay in the past with older Ubuntu versions, and I think even with 12.04 a while back. Perhaps something has changed with the driver. Anyway my problem is the same as listed in this Ubuntu Forums thread, only the fixes in there don't seem to work for me. xsetwacom changes the value, but seems to have no effect on the tablet, and there is no entry in dconf-editor. Does anyone have any ideas? The tablet is basically unusable to me at the moment. It's an original Volito rather than the Volito 2 listed in the thread, but the problem is identical.

    Read the article

  • Keyboard freezes / stuck if a key pressed repeatedly

    - by Aziz Rahmad
    I use Acer 4530. This problem has happened long since Ubuntu 10.10 and now that I use 11.04 dual booted with Linux Mint 10. Everytime I press one key repeatedly, like when I read a long article in a website/ebook or when I play games which required me to press arrow keys repeatedly, it would randomly freeze. That is, whatever I press on keyboard has no effect, and that also happens with touchpad. However, the USB mouse works just fine. I later found out that it's not actually freeze but more like it's like the key stuck. For example when I play tetris which I usually press w (down) button repeatedly, after some times it would freeze. And if I put the cursor in, say, browser's address bar, it would type "wwww....." infinitely. The only way I could fix it is by suspend the laptop, either by using mouse or by closing the lid. And instead of suspended, in that case the laptop would automatically wake up and everything will be fine. (Usually my laptop would wake up after suspended by pressing any key) It has happened since the first time I use Ubuntu, 10.10, and it also happens in Linux Mint 10, and until now in Ubuntu 11.04. It never happened when I use Windows, though. Anyone has ever encounter similar problem? Anyone know how to fix it permanently?

    Read the article

  • Keyboard freezes / stuck if a key pressed repeatedly

    - by Aziz Rahmad
    I use Acer 4530. This problem has happened long since Ubuntu 10.10 and now that I use 11.04 dual booted with Linux Mint 10. Everytime I press one key repeatedly, like when I read a long article in a website/ebook or when I play games which required me to press arrow keys repeatedly, it would randomly freeze. That is, whatever I press on keyboard has no effect, and that also happens with touchpad. However, the USB mouse works just fine. I later found out that it's not actually freeze but more like it's like the key stuck. For example when I play tetris which I usually press w (down) button repeatedly, after some times it would freeze. And if I put the cursor in, say, browser's address bar, it would type "wwww....." infinitely. The only way I could fix it is by suspend the laptop, either by using mouse or by closing the lid. And instead of suspended, in that case the laptop would automatically wake up and everything will be fine. (Usually my laptop would wake up after suspended by pressing any key) It has happened since the first time I use Ubuntu, 10.10, and it also happens in Linux Mint 10, and until now in Ubuntu 11.04. It never happened when I use Windows, though. Anyone has ever encounter similar problem? Anyone know how to fix it permanently? UPDATE I just recently installed Windows 7 and Windows 8 Development Preview and both have similar symptoms. So I declare that this problem is not OS specific, probably hardware problem.

    Read the article

  • Hit one key to hold a second key down, until third is pressed

    - by Core Xii
    I'm trying to get the following behavior with AutoHotKey: When the A key is pressed, AHK holds down the S key until the D key is pressed. The following script isn't working as expected: a:: Send {s Down} return d:: if (GetKeyState("s", "P")) { Send {s Up} } return Neither is the following: a:: release_s = 0 Loop { SendInput, s if release_s break } return d:: release_s = 1 return

    Read the article

  • How to determine if the camera button is half pressed

    - by Matthew
    I am creating a small test camera application, and I would like to be able to implement a feature that allows focus text bars to be present on the screen while the hardware camera button is pressed half way down. I created a camera_ButtonHalfPress event to perform the focus action, but I am unsure of how to toggle the text bars I would like to show on the screen accordingly. Essentially, my goal would be to show the text bars while the camera button is pressed half way down, and then remove them if the button is pressed all the way or the button is released before being pressed all the way down. The button being released is the part I am having trouble with. What I have is as follows: MainPage.xaml.cs private void camera_ButtonHalfPress(object sender, EventArgs e) { //camera.Focus(); // Show the focus brackets. focusBrackets.Visibility = Visibility.Visible; } } private void camera_ButtonFullPress(object sender, EventArgs e) { // Hide the focus brackets. focusBrackets.Visibility = Visibility.Collapsed; camera.CaptureImage(); } } Currently, if the the user decides to release the camera button before it is pressed all the way, the focus brackets persist on the screen. How might I fix this issue?

    Read the article

  • Pressed Listener for a View

    - by michael
    Hi, In android, is there such a thing for listening if a View is pressed? In background drawable, i can set assert depends on the view is pressed or not. Is it possible for me to add a Listener for a View when I pressed it? Thank you.

    Read the article

  • Android. How do I keep a button displayed as PRESSED until the action created by that button is finished?

    - by user527405
    I have button_focused, button_pressed, and button_normal images. When I press the button, the button_pressed image is displayed and the action related to the button pressing begins. When I quit pressing the button, the action continues but the button returns to button_normal image being displayed. How can I set the button image being displayed to button_pressed during the entire action then reset to the button_normal image? Thank you for your time

    Read the article

  • RHEL5 + Awesome WM - How do i fix mod4 inversion (acts like mod4 is always pressed)

    - by sgr
    I built and installed Awesome WM on RHEL5. I have problem with mod4 acting like its always pressed. ie every time i hit "Enter" it acts like Mod4+Enter was hit. I have to hold down mod4 key (I remapped it to Caps_Lock) to actually send through just a Enter. How do i fix this? PS: If i change the WM this problem doesnt exist. yes. I do. It is mostly tab configs though. I didnt change key combos. Also, the version of awesomeWM i compiled is 3.1.1 (had trouble getting deps for the latest AwesomeWM on Rhel5)

    Read the article

  • How to fix: mac keyboard ignores "first" key pressed

    - by lexu
    UPDATE 2012.03.19: the MBP described in this post is now broken and recycled (logic board fried). The replacement doesn't manifest the same problems. I tend to believe the problem originated in the keyboard firmware of the old MBP. Every now and then, usually after I haven't pressed a key in some time, sometimes minutes, sometimes seconds, my MBP will "swallow" the the first key I press ... say I'm logging into "superuser.com" .. I start typing my username and the textbox will show "exu" instead of "lexu" This is driving me nuts! My guess is the keyboard or it's controller goes to sleep and fails to wake up propperly ... What can I do about this? PS: I've already installed "MacBook, MacBook Pro Keyboard Firmware Update 1.0"

    Read the article

  • Show context menu when link is long pressed in TextView

    - by Al
    I have a TextView with its MovementMethod set to LinkMovementMethod. Text added to the TextView is a combination of normal text and URLs. For URLs, I would like to offer a context menu when the URL is long pressed for doing things such as copying the address. I've had a look at the source for LinkMovementMethod but it doesn't seem to have any long pressed related code I could override. Any ideas on how to go around achieving this?

    Read the article

  • Keyboard glitches for some when Ctrl key is pressed

    - by user270716
    I'm having some problems with my keyboard, if I press the Ctrl key it glitches for some time. For example, if I press Ctrl and press Tab while it's still glitched the computer shuts down as if i pressed the Power On/Off button. If I press a it "presses" Alt, A and a symbol I can't remember, if I recall correctly it's a currency symbol. If I press Ctrl again it "presses" the ' key. I'm using Windows 8 Single Language 64 bits with a ABNT2 keyboard. The processor is a Intel Celeron G530 with 2 GB of RAM.

    Read the article

  • Some of my keys are automatically being pressed along with other keys

    - by Santosh
    History The last time when my computer shutdown was a power failure. Now some keys are automatically being pressed when I type something. The last thing I did to keyboard setting was adding a keyboard layout (on Ubuntu). What is happening Whenever I press c, xc is writeen s gives me sd d gives me sd e gives me we 2 gives me 23, So when I want @ it gives me @# 3 gives me 23 Pressing CAPS Lock gives me F3 and vice-versa. All other key are either working fine or I don't use them. I have two operating system Ubuntu and Windows, I use Windows very less and found this problem on Ubuntu, but as soon as I logged in to Windows (for checking) then I found that Windows has the same problem. Effects on my life This starts form the time of login, even I have problem in typing my password. Whenever I try to save any webpage, it is bookmarked automatically. Whenever I copy, it is cut automatically. I have to spend more than half of time correcting what I have typed. Note: Typing thisd quwesdtion wasd rweally a big pain to mwe.

    Read the article

  • Clear UITextField when standard number pad is pressed

    - by Manu
    Hi all, I'm sorry if I didn't explain my problem well enough in the title. In my application, I'm using a small subview to create a very basic calculator on the top side of the screen (I just have an UITextField to show the operations and two buttons). Instead of using a custom keyboard for it, I want to use the standard iPhone number pad. My problem is that after doing an operation (e.g. adding two numbers) and showing the result, I cannot figure out how to clear the screen when the user enters a new number. So, for example: User enters "6" - Number 6 is shown in UITextField User selects "+" - UITextField is cleared to make room for the next number User enters "10" - Number 10 is shown in UITextField User selects "+" - 16 is shown as the result of the previous operation, and should stay there until another number is pressed (he wants to continue adding more numbers) User enters "5" At this point, if I was using a custom keyboard, I could clear the UITextField as soon as the button "5" is pressed by the user, but I cannot figure out how to do so when using the standard number pad. So, the result I get at the moment is "165". Is there a way to detect when a key is pressed in the standard number pad so that I can clear the UITextField before the new number appears? I thought there may be a NSNotification for that, but I couldn't find it. I'm aware that I could solve my problem if I created a custom keyboard or if I used two separated UITextFields (one for the operations and another one for the total), but I would like to use the standard number pad if it's possible. Thanks very much!

    Read the article

  • How to figure out which key was pressed on a BlackBerry

    - by Skrud
    What I want: To know when the user has pressed the button that has the number '2' on it, for example. I don't care whether "Alt" or "Shift" has been pressed. The user has pressed a button, and I want to evaluate whether this button has '2' printed on it. Naturally, if I switch devices this key will change. On a Bold 9700/9500 this is the 'E' key. On a Pearl, this is the 'T'/'Y' key. I've managed to get this working in what appears to be a roundabout way, by looking up the keycode of the '2' character with the ALT button enabled and using Keypad.key() to get the actual button: // figure out which key the '2' is on: final int BUTTON_2_KEY = Keypad.key(KeypadUtil.getKeyCode('2', KeypadListener.STATUS_ALT, KeypadUtil.MODE_EN_LOCALE)); protected boolean keyDown(int keycode, int time) { int key = Keypad.key(keycode); if ( key == BUTTON_2_KEY ) { // do something return true; } return super.keyDown(keycode,time); } I can't help but wonder if there is a better way to do this. I've looked at the constants defined in KeypadListener and Keypad but I can't find any constants mapped to the actual buttons on the device. Would any more experienced BlackBerry devs care to lend a helping hand? Thanks!

    Read the article

  • VB.NET: Dialog exits when enter pressed?

    - by Camilo Martin
    Hi all; My problem seems to be quite simple, but it's not working the intuitive way. I'm designing a Windows Forms Application, and there is a dialog that should NOT exit when the enter key is pressed, instead it has to validate data first, in case enter was pressed after changing the text of a ComboBox. I've tried by telling it what to do on KeyPress event of the ComboBox if e is the Enter key: Private Sub ComboBoxSizeChoose_KeyPress(ByVal sender As System.Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles ComboBoxSizeChoose.KeyPress If e.KeyChar = Convert.ToChar(Keys.Enter) Then Try TamanhoDaNovaFonte = Single.Parse(ComboBoxSizeChoose.Text) Catch ex As Exception Dim Dialogo2 As New Dialog2 Dialog2.ShowDialog() ComboBoxSizeChoose.Text = TamanhoDaNovaFonte End Try End If End Sub But no success so far. When the Enter key is pressed, even with the ComboBox on focus, the whole dialog is closed, returning to the previous form. The validation is NOT done at all, and it has to be done before exiting. In fact, I don't even want to exit on the form's enter KeyPress, the only purpose of the enter key on the whole dialog is to validate the ComboBox (but only when in focus, for the sake of an intuitive UI). I've also tried appending the validation to the KeyPress event of the whole dialog's form, if the key is Enter. NO SUCCESS! It's like my code wasn't there at all. What should I do? (Visual Studio 2008, VB.NET)

    Read the article

  • Can I get the amount of time for which a key is pressed on a keyboard

    - by Adi
    Dear all, I am working on a project in which I have to develop bio-passwords based on user's keystroke style. Suppose a user types a password for 20 times, his keystrokes are recorded, like holdtime : time for which a particular key is pressed. digraph time : time it takes to press a different key. suppose a user types a password " COMPUTER". I need to know the time for which every key is pressed. something like : holdtime for the above password is C-- 200ms O-- 130ms M-- 150ms P-- 175ms U-- 320ms T-- 230ms E-- 120ms R-- 300ms The rational behind this is , every user will have a different holdtime. Say a old person is typing the password, he will take more time then a student. And it will be unique to a particular person. To do this project, I need to record the time for each key pressed. I would greatly appreciate if anyone can guide me in how to get these times. Editing from here.. Language is not important, but I would prefer it in C. I am more interested in getting the dataset.

    Read the article

  • How do I store keys pressed

    - by Glycerine
    I would like to store keys pressed when I listen out for the keyDown on the stage. I can add the listener fine, but I'm not getting the character I want out of the event to store it into a string. This is what I have so far: private var _addToString:String = ""; public function Hotwire() { this.addEventListener(KeyboardEvent.KEY_DOWN, keydownEventHandler); } private function keydownEventHandler(ev:KeyboardEvent):void { trace("Key pressed: " + ev.charCode ); addToString(ev.charCode); } private function addToString(value:uint):String { trace(_addToString); return _addToString += String.fromCharCode(value); } Every key I press its returns '0'. How do I convert the chatCode to a real alphanumeric character I can read later? Thanks in advance

    Read the article

  • Whats the best way to stop this app crash when buttons rapidly pressed iphone obj-c

    - by dubbeat
    Hi, I'm not entirely sure why this crash is happening and I'd like to get advice on the best way to deal with it. My app has 3 buttons. Each button requests a different XML file from a server which is used to populate a table view. If I rapidly press the buttons in sequence , button 1 button 2 button3 button 1 button 2 button3 button 1 button 2 button3 the application quits. What could be causing this. Would id be in the NSURLRequest side of things or the table view population side? How would you suggest I stop this behaviour? I was going to just set a boolean "isRequesting" to true when a button is pressed and set it to false when the table view is finished populating. If any button is pressed while isRequesting is True they do nothing. Does that sound wise or is there a better way? Thanks, dub

    Read the article

1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >