Posted on 2005-04-08
Last Modified: 2010-03-31
Hey all.

When someone types something (when focused on a component, with a KeyEvent listener), does *just* the keyTyped() method get called? Or does it *also* call keyPressed() and keyReleased()  ??

Because, a keyType is just a keyPress then a keyRelease, right? Well, is the keyType only called (and the other two are not) when the interval between keyPress and keyRelease are very low?

Question by:InteractiveMind
    LVL 86

    Accepted Solution

    The keyPressed and keyTyped get called, followed by keyReleased
    LVL 86

    Expert Comment

    LVL 25

    Author Comment

    Okay. Great... one less method call for me :)
    Cheers, CEHJ.
    LVL 86

    Expert Comment


    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Maximize Your Threat Intelligence Reporting

    Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

    Suggested Solutions

    For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
    Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
    Video by: Michael
    Viewers learn about how to reduce the potential repetitiveness of coding in main by developing methods to perform specific tasks for their program. Additionally, objects are introduced for the purpose of learning how to call methods in Java. Define …
    This tutorial explains how to use the VisualVM tool for the Java platform application. This video goes into detail on the Threads, Sampler, and Profiler tabs.

    758 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    12 Experts available now in Live!

    Get 1:1 Help Now