mirror of
https://github.com/gui-cs/Terminal.Gui.git
synced 2025-12-31 02:08:03 +01:00
Workaround for changing CanFocus throwing Exceptions sometimes
This commit is contained in:
@@ -554,8 +554,11 @@ namespace Terminal.Gui {
|
||||
if(keyEvent.Key == ToggleResizable) {
|
||||
foreach(var l in splitterLines) {
|
||||
|
||||
var iniBefore = l.IsInitialized;
|
||||
l.IsInitialized = false;
|
||||
l.CanFocus = !l.CanFocus;
|
||||
|
||||
l.IsInitialized = iniBefore;
|
||||
|
||||
if (l.CanFocus && !focusMoved) {
|
||||
l.SetFocus ();
|
||||
focusMoved = true;
|
||||
|
||||
Reference in New Issue
Block a user