[jawsscripts] Re: Disabling a keyboard command

  • From: Doug Lee <doug.lee@xxxxxxxxxxxxxxx>
  • To: "jawsscripts@xxxxxxxxxxxxx" <jawsscripts@xxxxxxxxxxxxx>
  • Date: Sun, 12 Jan 2020 22:58:56 +0000

In case this helps anyone, a detailed description of the script execution 
process:

User types a key.
JAWS checks which key layout or layouts apply; e.g., Desktop, Laptop, Common, 
Virtual, etc. The following can each apply in the order listed:
* Virtual if the virtual cursor is active.
* Desktop or Laptop but not both.
* Common.

JAWS searches all applicable jkm files in this order, stopping at the first key 
match:
* The current script set's jkm in the user folder, then the shared folder.
* The default.jkm in the user folder if present, then the default.jkm in the 
shared folder.

If no match is found, the key typed by the user goes to the focused 
application. Otherwise...

If the key maps to a script called MyScript:

JAWS looks in the following places for MyScript() in this order:
* The user folder application script, and any jsb files Used by it.
* The shared folder application script, and any jsb files Used by that.
* The user folder default.jsb and anything Used by it.
* The shared default.jsb and anything Used by it.
* JAWS itself, though scripts rarely if ever get buried inside jfw.exe.

You can intercept this circuitous but useful path in two basic places:
* Intercept the key assignment by adding your own to the proper first-priority 
layout in the application jkm file in the user folder, or
* Intercept the script by writing your own in the user-folder application 
script file.

You can, of course, also intercept default keystrokes or scripts by creating or 
modifying default.jkm or default.jss/jsb, respectively, in the user folder.

When intercepting a script, be sure to allow default behavior when the 
situation is not yours. This is done by "chaining" your code to the original 
code. Example:

script sayNextLine()
if doMyThing(True)
        ; That function encapsulates whatever custom arrow functionality you 
need.
        return
endIf
performScript sayNextLine()
endScript

script sayPriorLine()
if doMyThing(False)
        return
endIf
performScript sayPriorLine()
endScript

int function doMyThing(int goingForward)
; Do whatever needs doing here, and return True if done and False if default 
behavior is wanted.
if !isPCCursor() || inHJDialog() || userBufferIsActive()
|| getWindowClass(getFocus()) != "myStrangeWindowClass"
        return False
endIf
; We here pretend that we have a weird control where PageUp/Down do what arrows 
are supposed to do.
if goingForward
        typeKey("PageDown")
else
        typeKey("PageUp")
endIf
pause()
sayLine()
return True
endFunction

On Sat, Jan 11, 2020 at 09:09:49PM -0800, jeremy.richards7@xxxxxxxxx wrote:
CAUTION: This email originated from outside of the organization. Do not click 
links or open attachments unless you recognize the sender and know the content 
is safe.


Hi all,

I'm desperately trying to disable the following JAWS 2020 Google Chrome
Browser command: Control+WindowsKey+J. Within Chrome this will jump to a
specific table cell, but I want to use this command for my own personal use
with another application.

I can't find this JAWS script anywhere within the Chrome settings or even
the default keyboard settings. I did find this JumpToLine command within the
JAWS 2020 Internet Explorer keyboard manager within the following file in
JAWS 2020:
C:\ProgramData\Freedom Scientific\JAWS\2020\Scripts\enu\Internet
Explorer.jkm

I moved the InternetExplorer.jkm file outside of the Freedom Scientific
folder into my D drive to edit out the keyboard command. I placed a
semicolon at the beginning of the line to wipe out the Control+WinKey+J
command. I then moved the file back to its original location. I even went as
far as restarting my computer.

Even after my modification, if Chrome is open, and if I press this
control+WindowsKey+J command JAWS will tell me that I'm not in a table,
which means I've not fully disabled the keyboard command from within JAWS. I
looked in the keyboard manager within the Internet Explorer folder, and the
keyboard command is no longer showing. It appears the keyboard command is
gone, but the script still remains.

I should also mention that the "Not in table" message is still announced
within Internet Explorer.

Where else can I look within my JAWS 2020 scripts to wipe out this
Control+WinKey+J command?

Thanks for any help,

JR


__________???

View the list's information and change your settings at
//www.freelists.org/list/jawsscripts

-- 
Doug Lee, Lead Accessibility Architect
Level Access - over 1,000 organizations trust us to help them achieve and 
maintain digital accessibility compliance!
mailto:Doug.Lee@xxxxxxxxxxxxxxx  http://www.LevelAccess.com
"While they were saying among themselves it cannot be done, it was done." 
--Helen Keller
__________�

View the list's information and change your settings at 
//www.freelists.org/list/jawsscripts

Other related posts: