Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 849747
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T07:09:10+00:00 2026-05-15T07:09:10+00:00

I have another problem, and because the reply is to fast here i come

  • 0

I have another problem, and because the reply is to fast here i come back again !!

I would like to use “key navigation” and for that, i use the keypress event with down/up key )

When my mouse is over a div (div who’s contenaing a big table) and i pull the down key :

i scroll to next td + change css style + remove the current style

And again, for each event..

So, because my mouse is over the main div, each time i scroll (auto) to a element, the mouseover event is triggered ..

And so, the effect is missed..

This is the perfect script :

  • User use keyboard navigation : Mouseover is disabled (so style change only with up/down key)
  • User don’t use keyboard : mouseover change the style

Could you help me ?

The code :

$("#content tr").mouseover(function() {
    $("#content tr.use,#content tr.sel").removeClass("use sel");
    $(this).addClass("sel");
});

And the keyboard navigation code : http://pastebin.com/Hgn5Y1FV

(Sorry again for my english.. )

Thanks

  • 1 1 Answer
  • 1 View
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T07:09:11+00:00Added an answer on May 15, 2026 at 7:09 am

    Try this. Whenever your scrolling (from the arrow keys) starts, have it set a flag to true, and when the scrolling stop, set the flag to false.

    var keyboardScroll = false;  // Set to true when keyboard scroll begins
                                 //     and false when keyboard scroll ends
    

    Then have the mouseover code run only if keyboardScroll is false;

    $("#content tr").mouseover(function() {
    
        if( !keyboardScroll ) {  // Run code only if keyboard scroll is not true
            $("#content tr.use,#content tr.sel").removeClass("use sel");
            $(this).addClass("sel");
        }
    
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

After getting a helpful answer here , I have run into yet another problem:
Following on from a question I posted yesterday about GUIs, I have another problem
I've been struggling with Zend_Navigation all weekend, and now I have another problem, which
I have another weird problem which I have not been able to solve in
another problem. I have already placed my Jython.jar into what my computer recognizes as
Okay, so I have another question on a prolog homework problem I am struggling
And another TreeView problem , should've used qt ;) I have a TreeView in
another ordered delivery problem. We have an orchestration which is bound to a send
I have a strange problem with integrating a ViewController into another ViewController . i
I have a problem with .NET assembly redirection. 3rd party assembly A references another

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.