CS2: Listbox and keyboard events

Hello all,
I have a listbox widget in a Palette, I need to catch keyboard events specifically I need to be notified when the user presses the RETURN key.
I checked the PanelTreeView sample which defines a custom event handler but functions like KeyDown or KeyCmd are never called despite "CanHaveKeyFocus" has been modified to return kTrue.
How can I be notified when user presses the RETURN key in the PanelTreeView listbox?
Thanks in advance ...
Jorge Martinez

If the StageWebView has focus, you should be able to capture only the hardware key events (like BACK, ..). All the others are handled internally by StageWebView.
Do you see otherwise? If yes, can you post your application ?
Thanks,
Raul

Similar Messages

  • In Flashplayer, I can crossover mouse and keyboard events. In IrfanView I cannot. Can this be fixed?

    My client uses IrfanView to play SWF files. Unfortunately, he does not use Flashplayer. In Flashplayer, I can crossover mouse and keyboard events with no problem. In IrfanView, the second I click a button, the keyboard events are disabled. Is there a fix?

    Hi Ned. I may have posted this issue a bit early, but this problem is also happening in Flashplayer 10. It's not exclusive to IrfanView.
    Here is something that I encountered during my testing, when I jump to scene 6 using the menu button, I have a play button to jump from one frame to the next frame that stops -- the keyboard events start working. But if all I am doing is jumping scene to scene with the mouse button, the keyboard events are disabled.
    I feel as if the keyboard events only work if I am playing frames in the scene. And if all I am doing is jumping scene to scene using the buttons, the keys will disable.
    I set up the mouse buttons inside a movieclip that all the scenes share. The mouse actionscript is in the movieclip. On the main timeline of each scene is an actionscript for the keyboard events, even though I had to change each function name.
    I feel the actionscript is setup pretty simple. I just wish clicking the buttons would not disable the keyboard events. This may sound redundant, but the keyboard events do the same thing if you use the mouse buttons. It's just preference for the client even though he will need to understand that using the mouse buttons override the keyboard events. He doesn't really lose functionality.
    Keyboard actionscripting below:
    import flash.events.KeyboardEvent;
    stage.addEventListener(KeyboardEvent.KEY_DOWN, onKeyEvent);
    function onKeyEvent(e:KeyboardEvent):void {
    var character:String=String.fromCharCode(e.charCode);
    if (e.keyCode==72) {
      gotoAndStop(1,"master");
    if (e.charCode==49) {
      gotoAndPlay(1,"Distributor");
    if (e.charCode==50) {
      gotoAndPlay(1,"Mirka");
    if (e.charCode==51) {
      gotoAndPlay(1,"Farm");
    if (e.charCode==52) {
      gotoAndPlay(1,"Check2");
    if (e.charCode==53) {
      gotoAndPlay(1,"Check3");
    if (e.charCode==54) {
      gotoAndPlay(1,"Scene2");
    if (e.charCode==55) {
      gotoAndPlay(1,"Scene1");

  • Capture All Mouse and Keyboard events even if java window NOT in FOCUS

    Hi All,
    Is this possible to capture all mouse and keyboard events even if java window is not in focus or is minimized. This java program should cature each and every event from the user once the program is started. Any help in this regard is appreciated!
    Thanks&Regards
    Sam

    I don't think you can. (without JNI)

  • Lock all mouse and keyboard event.

    i am looking ways to lock up all the mouse and keyboard events in windows...do u guy have ways to solve this?

    Do you mean that people should not be able to start other applications, or switch to other running applications, before they have typed the right password into you java program? I don't think that can be done in java - it requires more control over the computer than Java typically gives you. You may have some success with full-screen AWT, though.
    But why not use log-on-systems incorporated in whatever operating system you are using? Or some other netware thingie? Honestly, I think you are trying to reinvent the wheel, and even with tool that's not very appropriate.

  • How is possible to change reaction of multicollum listbox on keyboard events?

    >How is possible to change reaction of multicolumn
    >listbox on key events in Labview? For instance, I
    >would like to program such reaction of listbox, if
    >you select one of the row in listbox and then another
    >one pressing SHIFT >key, all rows between them should
    >be highlighted. Standard reaction of list box is that
    >only chosen rows highlighted but not rows between
    >them".
    >Thank you. Timur.
    Hallo all,
    Matt thank you for the answer.
    Unfortunately I must change behavior of listbox and may be there is way to change it programmatically?
    For example, catch KEYFOCUS event from listbox then get selected line , make array with lines you want to be highlighted and then write back
    in listbox.
    But it is not really nice solution and also there is problem that it is not possible to select lines for example 1, 3, 7, now all lines between 1 and 7 will be highlighted.
    May be somebody know better way how to do it.
    P.S.
    I attached example in case somebody has time and willingness to look at it and give idea.
    Thanks, Teimur
    Attachments:
    example.vi ‏22 KB

    Teimur,
    I would suggest posting this question to the LabVIEW Discussion Forum instead of DSC. You will be posting to the group that has more detailed knowledge on these aspects of LabVIEW.
    Regards,
    Mike
    NI

  • Weird mouse and keyboard events windows 7 @g550

    My windows 7, on laptop lenovo g550 behaves weirdly lately. After some casual run time i can't right click on desktop, start button doesn't respond, if i switch users and log in back to my user goes back to normal.
    Sometimes "c" or "v" keys do nut respond when i press them on firefox window but in adress bar i can write all fine...
    Some times same behaviour happens in different window. But when i switch users back again to my user via windows+L key its come back to normal. Please help )
    Scanned with updated anti virus nod, malware scanned with lavasoft adaware, cc cleaned. Drivers on gpu are latest, rest of drivers are updated and windows 7 is updated promptly.

    Yes, it also happens if I switch to a virtual console. In fact, I attempted to open a session on a virtual console (ctrl-alt-F1) the last time it happened, but I couldn't because my password wasn't logged correctly; the weird thing is, I could type the login name (for example, 'root' or my user name), but when I tried to enter the password it always returned an authentication error because the password was misspelled, or something. I also tried to reset the X server to see if it solved the issue, but I couldn't because the 'Alt' key was not working (when it happens, the only solution is to reboot from the GUI). Any ideas?
    Oh, and thanks for your comment about my desktop

  • Detect mouse clicks or keyboard events on desktop or everywhere

    Hi,
    What I have to do is to start the application minimized in the system tray. Then the application must be listening for crtl+shift+left mouse click in any part of the desktop or an opened application, when that happens, I have to show a window asking if the user want to take a screenshot starting in the x,y point he clicked and then take the screenshot.
    What I don't know how to do is to detect the mouse and keyboard events when the application is supposed to be running minimized in the system tray.
    How can I do that? Can anybody give me a hint?
    Thanks in advance.

    It's not possible with plain Java. You will need native code for this. Take a look at JNA.

  • Mouse/keyboard events lost during sound events

    I have a new MacbookPro (October 2011, MacBookPro8,2) with 4Gb RAM running latest 10.6.8, and I am extremely frustrated by periodic loss of mouse events (movement freezes, then jumps) and keyboard events (loss of keystrokes) whenever a sound alert is made. Am I the only person experiencing this?

    I should also add a related behavior, repeated keypresses. I do a lot of work on connected unix/linux machines using terminal. Sometimes I will be navigating directories and hit <tab> for command completion, and unexpectedly get the screen scrolling as if I had typed it 100 times!

  • Recording the input of mouse and keyboard outside of  a visible GUI

    I am trying to write something sorta like pc anywhere except I dont quite know how to approach the problem of recording the input from the mouse and keyboard. I have thought of using a glass pane the size of the screen but once I have captured the mouse or keyboard events how do I send them through to the underlying OS (as if nothing happened)?

    This is not possible in java. You should register to some native mouse and keyboard listener mechanism. and let them notify you of all the mouse and keyboard events. Maybe JNI can help you accomplish this.

  • Keyboard events going to InDesign and not on textbox

    Hi,
    I have ported a project from InDesign CS2 to InDesgn CS3 on Mac. I have dialogs in rsrc file (not converted to nib file) which I am also using on XCode.
    Now the problem which I am facing is that when typing in a textbox then keyboard events are going to InDesign and only those events which are not handled by InDesign is received by my textbox.
    Has anyone experienced the same problem before?
    Any help will be appreciated.
    Regards,
    Rahul Rastogi

    Start Firefox in [[Safe Mode]] to check if one of your add-ons is causing your problem (switch to the DEFAULT theme: Tools > Add-ons > Themes).<br />
    See [[Troubleshooting extensions and themes]] and [[Troubleshooting plugins]]<br />
    <br />
    If it does work in Safe-mode then disable all your extensions and then try to find which is causing it by enabling one at a time until the problem reappears.<br />
    You can use "Disable all add-ons" on the [[Safe mode]] start window to disable all extensions.<br />
    You have to close and restart Firefox after each change via "File > Exit" (Mac: "Firefox > Quit"; Linux: "File > Quit")

  • AutoSuggest Widget and Custom Keyboard Events

    Hi,
    I'm using the 1.6 and AutoSuggest widget for a search form.
    I've managed to customise it slightly that when a user selects one
    of the suggestions with the mouse a hidden form field is populated
    with an ID (so that we don't actually have to search for the
    selected terms, we can just reference the hidden field value, if
    it's defined).
    I've used a very simple onclick= on the suggstion div (the
    autosuggest itself is almost identical to the examples) that sets
    the value of the hidden field to the ID when it's clicked. And
    works fine. Although I can't seem to get it to work with keyboard
    events. I've tried onkeydown=/onkeypress=/etc but not joy. The
    Autosuggest widget keyboard navigation works, (up, down and enter
    to select the suggestion) but does it overide any other attempts
    for keyboard events? Or am I doing something wrong?
    All the code is the same as the example apart from the actual
    suggestion div. Here it is:
    <div class="list" style="font-size:10px;"
    onkeydown="setHiddenValue('{hiddenid}')"
    onclick="setHiddenValue('{hiddenid}')">{name}</div>
    And the setHiddenValue function (which works fine onclick):
    function setHiddenValue(hidID) {
    document.getElementById("intHiddenID").value = hidID;
    Thanks in advance for any help
    Al

    Just an update - and not the best solution. I've gone in and
    edited the spryAutoSuggest.js to fit our needs exactly. It was a
    just case of editing the key press events for the enter key (13 -
    it's commented //enter key), which now gets the hidden field by ID
    and set the value required to it.
    Surprised there was no other suggestions... maybe something
    to be resolved in 1.7?
    Al

  • How to make editing cell to show up caret and taking keyboard event

    Hello everyone:
    I have the following problem with table editing.
    1. using mouse clicking, the editing cell will have cursor and taking keyboard event.(no problem with it)
    2. just type in data, it will show up in the selected cell, but the editing cell do not have cursor visible and also do not fire the keyboard event.
    I have problem with this one. So how to make editing cell to have caret visible and taking keyboard event.
    Thank you very much!
    --tony                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

    Hi,
    you should subclass JTable and overwrite two methods.
    1. protected boolean processKeyBinding(javax.swing.KeyStroke ks,
    java.awt.event.KeyEvent e,
    int condition,
    boolean pressed)
    to store the current keyboard event,
    2.public boolean editCellAt(int row,int column,java.util.EventObject e)
    to fix the problem with isCellEditable and curret position and direct the event into proper place.

  • Design question ... Remote control and keyboard

    Hey i am building a system that should support remote control input and keyboard input
    the system is a addons based any user could build any addon he wishes
    i have now two main input events types
    KeyEventand
    RemoteControlEventi wish to use only one type of event
    i am thinking of 2 options.
    1) Map
    RemteControlEventto
    KeyEventif this why is the best what happens i a situation that i mapped J key to the RECORD button
    how a specific addon should know that a RECORD operation is pressed or it's just a J button
    2) Write a new events that contains
    KeyEventactions and
    RemteControlEventactions
    thanks allot

    thanks for your replay
    i am sharing my thoughts with you ,cause i relay want to do it the best way.
    when i mention remote control i meant using a TV/VCR/MCE Remote Control.
    (i am usingJLIRC ( LIRC ) )
    and i have decided .
    i will listen to all keyboard event using "dispatchKeyEvent"
    and will map Remote control keys to keyboard keys
    here is another question to make sure i understand fully .
    the application that i am writing is an add-on based
    every programmer that will like to create an add-on
    will extend the "Screen" object for is main panel (Screen exnteds JPanel)
    so i was thinking when dispatchKeyEvent called i should call dispatchKeyEvent in the current displayed screen
    (if the screen dispatchKeyEvent returns false.
    the main dispatchKeyEvent should continue.
    case true the main dispatchKeyEvent will return true)
    then in the screen implementation the user can ask if this key is an Spacial Key
    if yes he can get the spacial key attached to this keyboard key
    i just wrote an example of how it's suppose to be
    public MP3PLayer implemants Screen {
      public boolean dispatchKeyEvent(KeyEvent e){
        boolean isSpeacial = RemoteComtrolKey.getInstance().isSpeacialKey(e.getKeyCode);
        if(isSpeacial){
            int mappedKey = RemoteComtrolKey.getInstance().getSpeacialKey(e.getKeycode());
            if(mappedKey  == RemoteComtrolKey.REC){
              //do the record
               return true;
        return false;
    }georgemc thank you very much

  • Onclick and doubleclick event not working in CC

    hi..  onclick and doubleclick event not working in CC..  how to get these events to work?
    Please advise anyone. Thanks alot!

    Is your event target a ListBox?
    In that case there are serious issues to deal with:
    http://indiscripts.com/blog/public/ScriptUIEvents.pdf
    @+
    Marc

  • Photoshop CS2 freezing and "Not Responding"

    I've had Photoshop CS2 running on the same computer and OS (Vista) since around the time it came out, and it's always worked fine for me.
    A week or so ago Photoshop began to freeze continuously, and when it freezes I click on it and it goes into its "Not Responding" phase where the screen whites out. Sometimes it prompts me to close the program. I usually wait until it unfreezes (around 30 seconds) but if I open another window to pass the time, I can't click directly back into Photoshop, I have to minimize the other windows I was using to get to it, and it will not respond the first few seconds when I open the window or the program itself. Sometimes I can get a minute or so of work done, but that's usually it.
    I've tried uninstalling the program then reinstalling many times, deleting the preference files with Ctrl+Alt+Del, etc. I have plenty of memory left on my computer. It's only photoshop that does this, ImageReady works fine.
    Is there anything else I can try to fix it?

    Please allow me to suggest a way to help determine if you have hardware problems...
    Try this:
    1.  Click your Start button and type Event Viewer in the search box.  When Event Viewer comes up, click it.
    2.  Look in the Windows System log (or Administrative Events) for errors.  If you are seeing, for example, recoverable disk errors, they will be logged.
    3.  Are you seeing any actual crashes of Photoshop?  If so, look in the Application log for more information on these events, especially for the "Faulting Module" information.
    Also:
    A.  Have you changed / installed any 3rd party software / plug-ins since it worked well?
    B.  Has your maximum RAM allocation for Photoshop changed?  What value have you set in Edit - Preferences - Performance, and what is your total RAM in your system?
    -Noel

Maybe you are looking for