Welcome Guest Search | Active Topics | Sign In | Register

Windows hotkey shortcuts are conflicting with EO.WebBrowser Shortcuts Options
asbolton
Posted: Tuesday, April 25, 2017 12:24:20 PM
Rank: Member
Groups: Member

Joined: 10/25/2016
Posts: 10
I have a number of shortcut hotkeys defined in Windows 7. When using a full screen WPF application with EO.WebBrowser, my hotkey keystrokes are ignored. To get around this issue I redefined the shortcuts inside the WPF application as well using the WebView.Shortcuts feature. However, the Windows hotkey keystrokes prevent the WPF keystrokes from being fired (although the Windows hotkeys still don't work). When I delete the Windows hotkeys, the EO.WebBrowser shortcut hotkeys work fine.

Is there any way to have both coexist side by side (or, better yet, allow the Windows shortcut hotkeys to be executed while the application is running)?
eo_support
Posted: Tuesday, April 25, 2017 2:10:47 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,066
Hi,

We tested this and we do not see any problems. Can you provide the exact details on what shortkey you use in EO.WebBrowser and exactly how you set up Windows hotkeys?

Thanks!
asbolton
Posted: Tuesday, April 25, 2017 3:12:36 PM
Rank: Member
Groups: Member

Joined: 10/25/2016
Posts: 10
Thanks a lot for your time and looking at that. I have quite a few shortcuts defined for Eo.WebBrower:
Code: C#
private int GiveMeInfo = CommandIds.RegisterUserCommand("GiveMeInfo");
...

eoWebBrowser.WebView.Shortcuts = new Shortcut[]
            {
                new Shortcut(GiveMeInfo, KeyCode.OemQuestion, true, true, false),
                new Shortcut(INetD, KeyCode.D, true, true, false),
                new Shortcut(INetE, KeyCode.E, true, true, false),
                new Shortcut(LoadSetup, KeyCode.L, true, true, true),
                new Shortcut(PrinterInstall, KeyCode.P, true, true, true),
                new Shortcut(SetDHCP, KeyCode.D, true, true, true),
                new Shortcut(SetResolution1024, KeyCode.F8, true, false, false),
                new Shortcut(SetResolution1280, KeyCode.F6, true, false, false),
                new Shortcut(SetResolution1600, KeyCode.F7, true, false, false),
                new Shortcut(SyncPutMeIn, KeyCode.I, true, true, false),
                new Shortcut(SyncTakeMeOut, KeyCode.O, true, true, false),
                new Shortcut(SyncWithServer, KeyCode.F11, false, false, false),
                new Shortcut(UsbReadOnly, KeyCode.A, true, true, false),
                new Shortcut(UsbReadWrite, KeyCode.S, true, true, false),
                new Shortcut(UsbZoneSync, KeyCode.R, true, true, false)
            };

            eoWebBrowser.WebView.Command += WebView_Command;


For the Windows shortcut hotkeys, I have been creating a shortcut, going to the properties page of that shortcut, and entering the hotkey. When my WPF application is full screen it seems that the Windows hotkey (for example Ctrl + Alt + D) doesn't work (and it seems likely that this is an issue with the app being full screen) but the WebView_Command is also never hit. When I remove the Windows hotkey shortcut then the Ctrl + Alt + D Eo.WebBrowser shortcut works as expected.

If you have been unable to recreate this then there may be something else going on with my code. It is also very possible this is just a WPF fullscreen issue but I was a little confused why both shortcut hotkeys couldn't coexist.
eo_support
Posted: Wednesday, April 26, 2017 12:40:02 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,066
Hi,

The Windows's shortcut issue is unrelated to EO.WebBrowser. Windows disables shortcuts by design for full screen DirectX apps (which WPF utilizes). However this should not affect EO.WebBrowser's shortcuts. In another word, EO.WebBrowser shortcuts should always hit as long as the page has focus (this is again different than Windows shortcut since Windows shortcuts does not require focus). If you still have problem with this, you can try to isolate the problem into a small test app and send the test app to us, once we have that we will be happy to investigate further. See here for more details on sending test app to us:

https://www.essentialobjects.com/forum/test_project.aspx

Thanks!
eo_support
Posted: Wednesday, April 26, 2017 2:45:08 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,066
Hi,

We have received and looked into the test project you sent to us. The behavior you observed is normal and by design (of Microsoft).

As long as you setup a Windows shortcut, Windows will "eat" that shortcut and it will not be passed to an application. So if you have a Windows shortcut setup for the same keyboard combination, it will disable the same combination in your application (we didn't know you were using the same combination), this is true regardless whether your application is full screen or not.

Whether Windows will trigger the action associated to the shortcut depends on whether you have a DirectX full screen app or not. If you have a full screen app, Windows will not trigger the action, even though it will still eat the shortcut.

Hope this clears up. Please feel free to let us know if you have any more questions.

Thanks!
asbolton
Posted: Wednesday, April 26, 2017 3:35:40 PM
Rank: Member
Groups: Member

Joined: 10/25/2016
Posts: 10
That really clears things up, thanks for taking the time to look at that.


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.