From 2d8fcd375d92ad4b127aefe50307237cb04c529f Mon Sep 17 00:00:00 2001 From: nds Date: Fri, 25 Dec 2015 17:53:12 +0300 Subject: [PATCH] #1150 Tab buttons problems #1112 tab key doesn't work on the last field of left panels --- src/XGUI/XGUI_PropertyPanel.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/XGUI/XGUI_PropertyPanel.cpp b/src/XGUI/XGUI_PropertyPanel.cpp index d9335f4bc..aba8f914e 100755 --- a/src/XGUI/XGUI_PropertyPanel.cpp +++ b/src/XGUI/XGUI_PropertyPanel.cpp @@ -208,7 +208,11 @@ void XGUI_PropertyPanel::activateNextWidget(ModuleBase_ModelWidget* theWidget, isFoundWidget = isFoundWidget || (*anIt) == theWidget; } activateWidget(NULL); - //focusNextPrevChild(true); + // if there is no the next widget to be automatically activated, the Ok button in property + // panel should accept the focus(example is parallel constraint on sketch lines) + QToolButton* anOkBtn = findChild(PROP_PANEL_OK); + if (anOkBtn) + anOkBtn->setFocus(Qt::TabFocusReason); } //#define DEBUG_TAB_WIDGETS -- 2.39.2