
I have a ListView with a Ribbon ContextMenu. When clicking on one of the buttons, I wish to add some text to a SyntaxEditor control and then give focus to this SyntaxEditor. After setting the text, I call se.Focus(). Unfortunately it seems like the focus remains on the ListView, perhaps because the context menu closes and then gives focus back to the ListView after I have tried giving the focus to the SyntaxEditor? If I replace the Ribbon ContextMenu with a regular WPF ContextMenu and run the exact same code, everything works as expected and my SyntaxEditor receives the focus.