Custom.Keystrokes not being recognized correctly under JDK 11

20 views
Skip to first unread message

WildWilly

unread,
Dec 30, 2018, 5:52:23 AM12/30/18
to Polarbar mailer
 First bug report under my brand spanking new Java.  The Custom.Keystrokes are recognized fine when I use LeftAlt+my defined key but not when I use RightAlt.  I have several keystrokes defined for jumping to folders, all of them defined as Alt+[a letter].  For example:

ALT+i gotoFolder(inbox)

This works only with the LeftAlt but not with RightAlt.  I'm pretty sure this was working with both Alt keys before I went to JDK 11.

Carl Miller

unread,
Jul 9, 2019, 11:46:48 PM7/9/19
to Polarbar mailer
I've been looking at this. There is definitely a distinction being made in Java between the left/right Alt keys.

Try Alt+Alt+KEYSTROKE to see if that works for the right side.

e.g., Alt+Alt+i gotoFolder(Inbox)

Carl

Bill Wild Willy Kredentser

unread,
Jul 10, 2019, 12:07:01 AM7/10/19
to PolarBar Mailer Google Group
> ** Reply to message from Carl Miller <carlp...@gmail.com> on Tue, 9 Jul 2019 20:46:48 -0700 (PDT)

> I've been looking at this. There is definitely a distinction being made in
> Java between the left/right Alt keys.

Glad to know I wasn't just hallucinating this.

> Try Alt+Alt+KEYSTROKE to see if that works for the right side.
>
> e.g., Alt+Alt+i gotoFolder(Inbox)

Did this work for you when you tried it? I assume you did try it, right? It makes no difference
for me. I already had Alt+i defined for going to the Inbox. When I added the line you suggested,
it made no difference. RightAlt+i did nothing. RightAlt+LeftAlt+i & LeftAlt+RightAlt+i similarly
did nothing. I got no error but also no jump to the folder. Is there perhaps some debugging I
could turn on so you could see something in DEBUG.OUT? Right now, I'm seeing this:

> 2019-07-10 00:00:15,186 NOTICE [jstreet] Starting The Polarbar Mailer (1.26 build 2324)
> 2019-07-10 00:00:15,186 NOTICE [jstreet] Running under Oracle Corporation Java 11 (11.0).
> 2019-07-10 00:00:17,696 NOTICE [ClientServer] This instance of Polarbar is established as the mailto handler.
> 2019-07-10 00:00:17,766 INFO [LogLabel] Loading the Bayesian message corpus.
> 2019-07-10 00:00:17,766 INFO [LogLabel] The current Bayesian message corpus has been loaded (0 tokens).
> 2019-07-10 00:00:17,806 INFO [NoteContainerCmds] Created a new keystroke command: gotoFolder(inbox) (ALT+I)
> 2019-07-10 00:00:17,806 INFO [NoteContainerCmds] Created a new keystroke command: gotoFolder(outbox) (ALT+O)
> 2019-07-10 00:00:17,806 INFO [NoteContainerCmds] Created a new keystroke command: gotoFolder(Catch All) (ALT+C)
> 2019-07-10 00:00:17,806 INFO [NoteContainerCmds] Created a new keystroke command: gotoFolder(sent) (ALT+S)
> 2019-07-10 00:00:17,806 INFO [NoteContainerCmds] Created a new keystroke command: gotoFolder(drafts) (ALT+D)
> 2019-07-10 00:00:17,806 INFO [NoteContainerCmds] Created a new keystroke command: gotoFolder(trash) (ALT+T)
> 2019-07-10 00:00:17,866 INFO [LogLabel] Loading folders...
> 2019-07-10 00:00:17,876 INFO [LogLabel] Adding folders to control...
> 2019-07-10 00:00:17,886 INFO [LogLabel] Folders loaded. Repainting...
> 2019-07-10 00:00:17,886 DEBUG [NewNoteListImpl] NewNoteListImpl.load called for folder INBOX
> 2019-07-10 00:00:17,886 DEBUG [NewNoteListImpl] Loading folder: INBOX!
> 2019-07-10 00:00:17,886 DEBUG [NewNoteListImpl] Sorting INBOX
> 2019-07-10 00:00:17,886 DEBUG [SortableColumnList] SortableColumnList rowCount = 6
> 2019-07-10 00:00:17,886 DEBUG [NewNoteListImpl] setcounter
> 2019-07-10 00:00:17,886 DEBUG [NewNoteListImpl] ok
> 2019-07-10 00:00:17,886 DEBUG [NewNoteListImpl] loaded
> 2019-07-10 00:00:17,886 DEBUG [NewNoteListImpl] completed
> 2019-07-10 00:00:17,896 INFO [LogLabel] Folder load completed.

And that includes attempting to use RightAlt with i. It appears the double-Alt line in
Custom.Keystrokes is simply being ignored. You're going to have to go a long, long way to convince
me you actually tried this yourself before recommending it to me.

WW
GO HABS GO!
Configuration: Windows 7 64-bit, Open JDK build 11.0.1+28 (2019/3/1), pbm1.26dev/2324

Carl Miller

unread,
Jul 10, 2019, 1:01:24 AM7/10/19
to Polarbar mailer
Well, I am looking at it from a different perspective than you and what I can try (or even see) isn't the same as what you can try. I've already dug enough into that code to see that something like Alt+Alt was being returned which is why I suggested to try it. I couldn't prove it would work for you because your code is different than what I'm running.

In any case, that wouldn't have worked as it really needs to be "Alt+Alt Graph" which isn't something you can enter into the custom keystroke file as it has a blank there. 

I've fixed it in the handler for all this such that it normalizes these differences plus things that are different on Mac OS X (very different). This will make the custom keystroke files standard across platforms (still need to ensure this is working on Linux). Also, no distinction will occur between left/right Alt keys.

The odd thing is it's only the Alt key that does this, not the Ctrl or for Windows, the Windows key, but on a Mac, that's the Command key which doesn't interrupt things, it acts as another modifier key. But on the Mac, I normalized that to Alt as well until someone complains. I'm preferring consistent custom keystroke files versus incompatible ones.

Carl

Reply all
Reply to author
Forward
0 new messages