bhuj2000
bhuj2000

Reputation: 237

Set a keyboard shortcut for an action in browser

this might not be the right place for this but I’m trying to create a keyboard shortcut to press the previous button on my udacity.com videos. I’m technically competent to find the element but not much else. Anyone know how I could learn to do this? Thanks

Upvotes: 1

Views: 367

Answers (2)

gherson
gherson

Reputation: 195

Re: "I'd like to be able to use udacity.com's previous button with a hotkey", Google scared up these keyboard shortcuts:

K and spacebar toggle play|pause.
->|L jumps forward 5|10sec.  (arrow keys (and spacebar) require focus to work.)
<-|J jumps backward 5|10sec.
Tab|Shift+Tab to move focus forward|backward between controls.
Home key or 0 to go to video start, # to jump to #0% of the video, e.g., 3 jumps to 30% thru.  End key to jump to end.
Shift+{N|P} for next|previous video in playlist.
<|> keys to {de|in}crease playback speed.  (remember Shift key.)
F toggles full|normal screen.  Esc also brings back normal view.
Arrow up|down to raise|lower volume.  M to mute.

Upvotes: 2

Avinash Babu
Avinash Babu

Reputation: 6252

You could use the most commonly used package pyhk. The next method is by using registerhotkey method.

In registerhotkey method there are two parameters hotkeyId, modifiers, keycode. hotkeyId is the id of the key and when the user pres the hot keyid the event triggers and the function executes.

Upvotes: 2

Related Questions