Results 1 to 5 of 5
  1. #1
    Toll's Avatar
    Toll is offline Senior Member
    Join Date
    May 2011
    Location
    Sweden
    Posts
    392
    Rep Power
    4

    Default Polling mouse status directly without MouseEvent?

    I'm currently trying to figure out if a mouse button is held down, but I'd rather not have to rely on setting booleans on the MouseEvents Pressed and Released, as that can cause problems if you alt-tab out of the program. Is there a way to poll the status of the mouse buttons directly as there is with the mouse position?

    Also, same question but with modifier keys (shift, ctrl, etc)?

  2. #2
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,193
    Rep Power
    19

    Default

    Moved from 'Advanced Java'

    db

  3. #3
    DarrylBurke's Avatar
    DarrylBurke is offline Member
    Join Date
    Sep 2008
    Location
    Madgaon, Goa, India
    Posts
    11,193
    Rep Power
    19

    Default

    To answer your two questions: No, and no.

    db

  4. #4
    Toll's Avatar
    Toll is offline Senior Member
    Join Date
    May 2011
    Location
    Sweden
    Posts
    392
    Rep Power
    4

    Default

    Was afraid of that :( Back to booleans, I suppose. Thanks!

  5. #5
    Toll's Avatar
    Toll is offline Senior Member
    Join Date
    May 2011
    Location
    Sweden
    Posts
    392
    Rep Power
    4

    Default

    Also... Where did the option to solve the thread go? Was it a planned vanishing act when migrating to the new forum software?

Similar Threads

  1. MouseEvent
    By PhQ in forum Java Applets
    Replies: 21
    Last Post: 03-26-2010, 08:48 PM
  2. Reading Directly from a URL [help]
    By Lil_Aziz1 in forum Networking
    Replies: 4
    Last Post: 01-03-2010, 05:27 PM
  3. Mouse Listener for mouse floating over object?
    By Krooger in forum AWT / Swing
    Replies: 1
    Last Post: 11-18-2009, 04:34 AM
  4. Tail without polling
    By taotree in forum Advanced Java
    Replies: 2
    Last Post: 11-12-2008, 08:57 AM
  5. FrameWork polling
    By nanaji in forum Advanced Java
    Replies: 0
    Last Post: 10-29-2008, 10:16 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •