Video-Hub-App
Video-Hub-App copied to clipboard
{Home}/{End} {Page up}/{Page down} keys cause gallery to lose focus
Windows, Videohub 2.x and 3.x all seem affected by this issue.
Steps to reproduce: You have the gallery in focus. You hit page down (or other key) on your keyboard. The gallery moves down ~1 page. You hit page down (or other key) on your keyboard. Nothing happens. Click inside the gallery and it all starts working again.
Same for home/end page up/page down. I'll look into the code to see if there's an obvious reason, but something is bound to these keys that is causing the the gallery to lose focus.
Happens in all gallery views. Thanks!
This doesn't appear to happen when one of this navigation key presses does not cause the loading of new elements. AKA: if everything is already rendered but things near the top/bottom are partially obscured you press these navigation keys and focus is not lost.
You can use a gallery (let's use thumbnail view for now) and if you adjust the size of the thumbnails such that they cover multiple pages: this error happens.
You can then adjust the sizing such that thumbnails are all rendered, but partially obscured: no issues with focus lost.
I don't have an obvious candidate that explains this behavior in that I assume these navigation keys are not custom bound to custom actions and we're letting electronjs browerwindow thing handle these key presses. Some supplemental action/event/message passing thing between the electronjs components is probably having the side effect of altering what has focus.
Going to dig into places where a .blur() or .focus() is called and see if I can find an obvious candidate.
I can confirm that these navigation keys do not cause the windows "window" to lose focus. WinAPI Calls do show that it stays the active window.
Furthermore I can confirm that other Ctrl-F style hotkeys that change the focus continue to work.
You can quickly hit these navigation keys and you might get more than one respected before losing focus. Useful to know that the navigation key itself is not causing the blur atomically.
Page Up seems to lose focus less often with a double tap than page down does... all the stranger.
related? I think this is ngx-virtual-scroller oddities
https://github.com/rintoj/ngx-virtual-scroller/issues/213 https://github.com/rintoj/ngx-virtual-scroller/issues/144