Eto forms lose focus


is there a way to force an Eto form to lose focus in c#? There is the Focus() method, but not the opposite. It could come in handy when we click inside of a view and would like this to remove focus from a particular control.

Clicking on the white area of the dialog in one of the official samples leaves a black border around the last selected row. Clicking outside of the dialog forces the focus to be lost and removes the outline.

Can this be done in code?

Hey @mrhe,

In order for a control to lose focus, you need to set focus to something else. Perhaps one of the buttons?

Hope this helps.


Hey @curtisw,

thanks for the suggestion. Setting focus to the main window solves the issue: