Re: Module-wise Keyboard preferences

Поиск
Список
Период
Сортировка
От Harshal Dhumal
Тема Re: Module-wise Keyboard preferences
Дата
Msg-id CAFiP3vxEoM=wKZWouiZSPO6NFi7ZtZc7x=Texd6MHztxVUsOgg@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Module-wise Keyboard preferences  (Dave Page <dpage@pgadmin.org>)
Ответы Re: Module-wise Keyboard preferences  (Dave Page <dpage@pgadmin.org>)
Список pgadmin-hackers
Hi Dave,

On Wed, Jan 17, 2018 at 4:58 PM, Dave Page <dpage@pgadmin.org> wrote:
Hi

To summarise an offline discussion we just had, the intention is to replace the switches with checkboxes for Shift, Control, and Alt/Option, then to try to come up with a set of default shortcuts that work on the major platforms/browsers. Investigation into Javascript's handling of keycodes vs. strings is ongoing to figure out the best way to capture and display the selected keys for non-ASCII locales (String.fromCharCode()).

I have replaced switches with checkboxes and also showing all controls for one preference in single line.

Inline image 2
Regarding String.fromCharCode() to reverse map keycode to char (actual char on keyboard) does not work for all keyboard keys.

For eg. on mac with standard keyboard and with my locale settings I got below behaviour.
For key tilde (~) I got keycode 192 (Unicode value of the pressed keyboard key as per docs) and
when I tried to map 192 (String.fromCharCode(192)) to get actual char, I got À

So instead of mapping keycode to char for display purposse I'm using char which is returned by event object 


[my locale settings]
Inline image 3


 

On Wed, Jan 17, 2018 at 6:34 AM, Harshal Dhumal <harshal.dhumal@enterprisedb.com> wrote:
Hi Team,

I'm attaching initial patch for feature module-wise keyboard preference.

Also apart from main patch I have also attached one sample debugger 
keyboard shortcut patch to illustrate how to add module-wise preferences

Inline image 1



-- 
Harshal Dhumal
Sr. Software Engineer

EnterpriseDB India: http://www.enterprisedb.com
The Enterprise PostgreSQL Companypg



--
Dave Page
Blog: http://pgsnake.blogspot.com
Twitter: @pgsnake

EnterpriseDB UK: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

Вложения

В списке pgadmin-hackers по дате отправления:

Предыдущее
От: git@pgadmin.org
Дата:
Сообщение: pgAdmin 4 commit: Branch refs/heads/runtime-revamp was created
Следующее
От: Joao De Almeida Pereira
Дата:
Сообщение: Re: [pgadmin4][Patch]: Display Functions node for GreenPlum database