Rank: Advanced Member Groups: Member
Joined: 12/1/2014 Posts: 57
|
Since 2019 pressing the backspace key seems to trigger a navigation to the previous page. Is there a way to disable this? Thank you
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,218
|
We are not aware of this problem. Can you reproduce this with our TabbedBrowser sample application?
|
Rank: Advanced Member Groups: Member
Joined: 12/1/2014 Posts: 57
|
No the problem does not exist in TabbedBrowser - could it be because I use CommandBindings. In my application I have a number of buttons - each button can be configured to do a number of different things, including browse back.
I have the following class (just showing some of the code)
public class ChromeWebBrowser : ContentControl, IDisposable
public ChromeWebBrowser() { webControl = new EO.Wpf.WebControl(); Content = webControl;
CommandBindings.Add(new CommandBinding(NavigationCommands.BrowseBack, BrowseBackExecuted, CanBrowseBack)); }
private void BrowseBackExecuted(object sender, ExecutedRoutedEventArgs e) { if (webView != null) webView.GoBack(); }
private void CanBrowseBack(object sender, CanExecuteRoutedEventArgs e) { if (webView != null) e.CanExecute = webView.CanGoBack; }
Then if a button is configured to browse back
metroButton.CommandTarget = currentWebBrowser; metroButton.Command = NavigationCommands.BrowseBack;
|
Rank: Advanced Member Groups: Member
Joined: 12/1/2014 Posts: 57
|
Need to do more testing but I think I found a solution - adding
NavigationCommands.BrowseBack.InputGestures.Clear();
|